π Lecture 112 β Do not Focus on Acceptable Delays
π Overview: This lecture addresses how to identify and properly interpret delays in network trace files. It teaches students which delays are normal and can be safely ignored (acceptable delays), versus those that signal actual problems. Understanding acceptable delays prevents false alarms and focuses analysis on genuine network or application failures.
ποΈ Topics Covered
This lecture covers the concept of acceptable delays in TCP trace files, explaining why some delays (like those before TCP RST packets) are normal and should not raise alarms. It examines specific categories of acceptable delays: delays before DNS queries caused by user interaction, delays before TCP FIN or Reset packets caused by application processing time, delays before a client sends a request to a server due to user input, and delays before Keep-Alive or Zero-Window Probes.
π Lecture Summary
Introduction: The Worth of Normal Delays
This topic discusses the worth of normal delays. You can safely ignore some delays in your trace files. For example, a delay before a TCP RST packet would likely not be felt by the end user. Such acceptable delays should not raise an alarm. The lecture emphasizes not focusing on delays that are part of normal operation, as they do not indicate a problem.
π‘ Why this matters: Focusing on acceptable delays wastes analysis time and can lead to incorrect diagnoses of network issues.
Delays before DNS Queries
A DNS query will be triggered when we enter a URL in a browser and then press Enter, or when we see an interesting link on a web page and we click on it. Open tr-delays.pcapng. You will find that the delay before Packet 29 is caused by an eventual time out of a connection. Packet 32 is a DNS query, and the delay before it is because the user did not straightaway click on www.wireshark.org.
π Definition β Acceptable Delay before DNS Query: A delay introduced by the user taking time to decide which link to click or manually typing a URL, rather than a network problem.
Delays before TCP FIN or Reset Packets
Delay introduced by an application, which sends TCP FIN/RST packets to close the connection after waiting for a specified time or some task is completed. The application must process data or complete a job before it can terminate the TCP connection. This delay is normal and should be expected.
π Definition β Acceptable Delay before TCP FIN/RST: The time an application takes to finish its tasks before initiating a graceful (FIN) or abrupt (RST) connection termination.
Delays before a Client Sends a Request to a Server
This occurs when filling out a form and pressing the Submit button, or clicking the next link on a web page. In all such cases, an application requires user interaction. The delay is introduced by the human, not the network.
π Definition β Acceptable Delay before Client Request: The time between a page loading and the user performing an action (clicking, typing) that triggers a new HTTP request.
Delays before Keep-Alive or Zero Window Probes
[Note: This section heading appears in the outline but the lecture text provides no specific content for it. The summary is based on the section title and general knowledge of TCP behavior. This is likely an oversight or truncated section in the provided text.]
π Definition β Keep-Alive Probe: A TCP packet sent to check if a connection is still active when no data has been exchanged for a long period. Zero Window Probe: A TCP packet sent by a sender to check if a receiver's window has opened after the receiver announced a zero window size. Delays before these probes are normal as they wait for timers.
β Key Takeaways
The most critical thing a student MUST remember from this lecture is that not all delays in a trace file indicate a problem. Delays before DNS queries are often caused by user hesitation, not network failure. Delays before TCP FIN/RST packets are due to application processing time and are normal. Delays before a client sends a request are typically caused by user interaction with a form or link. These acceptable delays should be ignored during analysis to avoid false alarms. The core skill is distinguishing between application-level or user-caused delays and genuine network delays like retransmission timeouts.
π§ Quick Revision Questions
- What is an "acceptable delay" in the context of TCP trace file analysis?
- What is the most common cause of a delay before a DNS query in a web browsing session?
- Why might a delay occur before TCP FIN or RST packets are sent?
- How can you differentiate between a delay caused by a network problem and a delay caused by user interaction?
- According to the lecture, what should you do when you encounter a delay before a Keep-Alive or Zero Window Probe?
π Lecture 113 β Watch for the Delays that DO Matter
π Overview: This lecture focuses on identifying significant network delays that indicate real performance issues, distinguishing them from normal delays like Zero Window probes or keep-alives. Understanding these meaningful delays helps network analysts pinpoint problems in server response times, round trip times, and data stream interruptions.
ποΈ Topics Covered
The lecture categorizes delays that matter into four key types: delays before a server responds with SYN/ACK (indicating high round trip time), delays before a client completes the 3-way TCP handshake (also measuring RTT), delays before a server sends a response (indicating server-side processing issues), and delays before the next packet in a data stream (caused by sender busyness or blocking). Each delay type is explained with its significance for network troubleshooting.
π Lecture Summary
Delays before a Server Responds with a SYN/ACK
A client can use the time between the SYN and SYN/ACK in the TCP handshake to determine the round trip time (RTT) between the hosts. A large delay before the SYN/ACK is an indication of a high round trip time between the hosts. π‘ Why this matters: This measurement helps determine if network path latency is the root cause of slow connections.
π Definition β Round Trip Time (RTT): The time it takes for a packet to travel from source to destination and back.
Delays before a Client Completes the 3-Way TCP Handshake
The time between SYN/ACK and the client's ACK to finish the TCP handshake can be used by the server to determine the round trip time. This gives the server a measurement of path latency without additional probes.
Delays before a Server Sends a Response
In a trace file, if you observe that a server quickly sent an ACK to a client's request, but there is a long delay before the server's response, then this is not a path latency issue. We need to consider why a server might be slow. For example, in tr-http-pcaprnet101.pcapng, the client's GET request (GET /home) in packet 18 followed by the server ACK takes 17 ms. We can see a delay of almost 1.8 seconds before the requested data begins. The trace was taken at the client. The round trip time between the hosts is acceptable, but the server response time is not.
π Example: In trace file tr-http-pcaprnet101.pcapng, packet 18 shows client GET /home request. Server ACK arrives after 17 ms (acceptable RTT). However, a 1.8 second delay follows before data transmission begins, indicating a server processing problem, not a network latency issue.
Delays before the Next Packet in a Data Stream
There can be several reasons for delays that occur during a file download or file upload process: the sender became busy with other processing, or there can be a blocking event such as Virtual Memory Paging, SQL Database Commit, DNS Lookup, or CPU Overload. π‘ Why this matters: These delays point to application-level or system-level performance problems rather than network congestion.
π Definition β Blocking Events: Operations that pause the sender's data transmission, including virtual memory paging, SQL database commits, DNS lookups, or CPU overload.
β Key Takeaways
A student must remember that meaningful delays in TCP communications fall into four distinct categories. Delays before SYN/ACK and before the final ACK in the handshake both indicate high round trip time (path latency). A quick ACK followed by a long delay before the server's response data indicates a server-side performance problem, not network latency. Delays during data streams can be caused by sender busyness or blocking events like paging, database commits, DNS lookups, or CPU overload. Crucially, these are different from the "delays that don't matter" like Zero Window probes or keep-alives. The example from tr-http-pcaprnet101.pcapng shows RTT of 17ms but a server response delay of 1.8 secondsβa classic case of server bottleneck, not network bottleneck.
π§ Quick Revision Questions
- What does a large delay between SYN and SYN/ACK in the TCP handshake indicate?
- How can a server determine the round trip time between hosts using the TCP handshake?
- If a server sends a quick ACK to a client request but delays sending the actual response data, what is the likely cause?
- In the tr-http-pcaprnet101.pcapng example, what was the measured RTT and what was the server response delay?
- Name three types of blocking events that can cause delays between packets in a data stream.
π Lecture 114 β Wireshark Lab 22
π Overview: This lecture explores how to detect and analyze delays in UDP conversations using Wireshark. It focuses on the connectionless nature of UDP and how conversation statistics provide insights into network performance for UDP-based applications like VoIP.
ποΈ Topics Covered
The lecture covers sources of delay in TCP-based conversations (device buffering, lack of receive buffer space, delayed ACKs, window updates), then shifts focus to UDP as a connectionless transport protocol. The main practical section provides a step-by-step guide to using Wireshark's Conversations Window to view UDP conversation statistics, including packet rates and bps rates. A specific example uses the tr-voip-extensions.pcapng file to demonstrate sorting conversations by traffic flow.
π Lecture Summary
Delays before an ACK from a TCP peer
This situation arises when ACKs from a receiver get delayed because of the path latency or delayed ACK function. Delayed ACK timers are often set at 200 ms.
π Definition β Delayed ACK function: A TCP mechanism where the receiver delays sending an ACK to allow piggybacking with data, often using a 200 ms timer.
Delays before a Window Update
A host must wait for a Window Update before sending a packet, if it finds that the advertised Window Size is too small to fit a full-sized data segment.
π Definition β Window Update: A TCP segment sent to inform the sender that the receiver has more buffer space available for data.
π Example: If the receiver's advertised Window Size is 100 bytes but the sender wants to send a 1460-byte segment, the sender must wait for a Window Update before transmitting.
Topic 114: Wireshark Lab 22
In this topic, we discuss how to detect delays in UDP Conversations in Wireshark. The User Datagram Protocol (UDP) is a connectionless transport layer protocol with an 8-byte header. Unlike TCP, UDP has no sequencing or acknowledgement capability. Delays between requests and responses are a measure for UDP-based applications. UDP conversation statistics such as packet rate, bps rate etc. can be obtained with Conversations Window.
π Definition β UDP Conversation: A unidirectional or bidirectional flow of UDP packets between two endpoints identified by IP addresses and port numbers.
π Formula: Packet rate = Number of packets / Time interval β Measures how many UDP packets are transmitted per second. π Formula: bps rate = Bits transmitted / Time interval β Measures the bit rate of UDP traffic.
π‘ Why this matters: Since UDP lacks retransmission and flow control, delays directly impact real-time applications like VoIP, video streaming, and online gaming.
Step 1: Open tr-voip-extensions.pcapng
Open the provided capture file containing UDP traffic from a VoIP extension scenario.
Step 2: Select Statistics | Conversation
Navigate to the Statistics menu and select Conversation to access the Conversations Window.
Step 3: Click the UDP tab
Uncheck the Name Resolution option, if you are interested in seeing port numbers rather than port names. This displays raw port numbers (e.g., 25426) instead of service names (e.g., "sip").
Step 4: Sort by bps A β B
Click twice on the bps A β> B column heading. This will sort UDP conversations based on traffic flowing from Address A/Port A to Address B/Port B. In the list, Wireshark will view the conversation between 192.168.5.11/port 25426 and 192.158.5.10/port 8000 first.
π Definition β bps A β B: The bit rate of traffic flowing from the first endpoint (Address A/Port A) to the second endpoint (Address B/Port B).
β Key Takeaways
UDP delays are detected by analyzing conversation statistics rather than sequence numbers or ACKs. The Conversations Window provides packet rate and bps rate for each UDP flow. Sorting by bps AβB helps identify the most bandwidth-intensive conversations. Path latency and window updates affect TCP but not UDP, making UDP conversation analysis simpler. The 8-byte UDP header means minimal overhead, but no error recovery.
π§ Quick Revision Questions
- What is the size of the UDP header?
- How do you access the Conversations Window in Wireshark?
- What does the "bps A β B" column represent?
- Why might you uncheck Name Resolution when viewing UDP conversations?
- What is the typical delayed ACK timer value in TCP?
π Lecture 115 β Wireshark Lab 23
π Overview: This lecture explains how to add and sort a Delta Time column in Wireshark to identify network delays. It demonstrates the process using a trace file from Malaysian Airlines, enabling analysts to locate the largest delays in a capture by sorting delta time values.
ποΈ Topics Covered
The lecture covers the default Time column setting in Wireshark (Seconds Since Beginning of Capture) and how to replace it with delta times for better delay analysis. It provides step-by-step instructions for creating a frame.time_delta column, repositioning it next to the existing Time column, renaming it to "Delta", and sorting it to identify the largest delays.
π Lecture Summary
Topic 115: Wireshark Lab 23
This topic describes how to Add/Sort a Delta Time Column in Wireshark. In Wireshark, the default Time column setting is Seconds Since Beginning of Capture. It becomes easier to locate delays when a time column displays delta times. We can locate the largest delays in a trace file by sorting the delta time column.
π‘ Why this matters: Delta time columns allow you to see the time difference between consecutive packets, making it simple to spot unusual pauses or bottlenecks in network traffic.
Step 1: Open tr-malaysianairlines.pcapng
Step 2: Expand the Frame section of any packet.
Step 3: Right-click on the βTime delta from previous captured frameβ line and select Apply as Column. This will create a frame.time_delta column.
Step 4: The new column appears to the left of the Info column. Click and drag it to the right of the existing Time column.
Step 5: Rename the column by right-clicking on the column heading and selecting Edit Column Details. Letβs change the Title to Delta. Click OK.
π Definition β Delta Time: The time difference between the current packet and the previous captured frame, useful for measuring inter-packet delays.
π Formula: Delta Time = Timestamp(current packet) β Timestamp(previous packet) β This gives the exact time gap between two consecutive packets.
π Example: In tr-malaysianairlines.pcapng, after creating a Delta column and sorting it in descending order, the largest delta value appears at the top, indicating the longest delay between two consecutive packets in the capture.
β Key Takeaways
The key takeaway is that the default Time column shows absolute time since capture start, which is not useful for delay analysis. By creating a frame.time_delta column and sorting it, you can instantly locate the biggest delays in a trace file. This method involves right-clicking the "Time delta from previous captured frame" field, applying it as a column, repositioning it next to the Time column, and renaming it to "Delta". This technique is critical for performance troubleshooting and identifying network latency issues in Wireshark.
π§ Quick Revision Questions
- What is the default Time column setting in Wireshark?
- Which field should you right-click to create a delta time column?
- Where does the new delta column initially appear after you add it?
- How do you rename the delta time column to "Delta"?
- How can you use the delta time column to locate the largest delays in a capture file?
π Lecture 118 β Wireshark Lab 26
π Overview: This lecture demonstrates how to obtain TCP conversation statistics in Wireshark. It covers using the Conversations window to identify the most active TCP session in a trace file and applying filters based on conversation endpoints. This skill is essential for network analysts troubleshooting TCP-based applications or analyzing large packet captures.
ποΈ Topics Covered
This lecture explains the connection-oriented nature of Transmission Control Protocol (TCP) and stream-based communication. It covers the TCP Stream Index (tcp.stream) numbering system and walks through steps to find the most active TCP conversation by sorting conversations by byte count. The lecture also demonstrates how to create a filter from a selected conversation using source/destination addresses and ports.
π Lecture Summary
How to obtain TCP conversation statistics in Wireshark
Transmission Control Protocol (TCP) is a connection-oriented protocol. TCP is a stream based communication. Each separate TCP conversation is numbered by Wireshark with a TCP Stream Index (tcp.stream) value starting with 0.
To find the most active TCP conversation in a trace file:
Step 1: Open tr-chappellu.pcapng.
Step 2: Select Statistics | Conversations and click the TCP tab.
Step 3: Click twice on the Bytes column to sort from high to low. This identifies the conversation that transmitted the most data.
Step 4: Right-click on the top entry and select Apply as Filter | Selected | A <β> B. Wireshark creates a filter based on the source/destination address and source/destination port fields.
π Note: If you have a large trace file, you can apply a filter directly from within the Conversations window to narrow down your analysis.
β Key Takeaways
The most active TCP conversation in a trace file can be identified by sorting the TCP Conversations tab by the Bytes column in descending order. Wireshark numbers each TCP conversation with a unique TCP Stream Index (tcp.stream) starting at 0. After identifying a conversation, right-clicking and selecting "Apply as Filter | Selected | A <β> B" creates an automatic filter based on both IP addresses and port numbers. This filtering technique is critical for isolating specific TCP streams in large captures with hundreds of simultaneous connections. The Conversations window provides a centralized view of all TCP sessions with their byte counts and packet counts.
π§ Quick Revision Questions
- What is the TCP Stream Index (tcp.stream), and what value does it start with?
- Which column in the TCP Conversations tab should you sort to find the most active conversation?
- What two types of information are included in the filter created by "Apply as Filter | Selected | A <β> B"?
- Why is TCP described as a "connection-oriented" and "stream based" protocol?
- How can you access the TCP Conversations window and sort conversations by byte count?
π Lecture 119 β Wireshark Lab 27
π Overview: This lecture teaches how to filter TCP conversations using the stream index field in Wireshark. Understanding TCP streams allows network analysts to isolate and examine specific communication sessions between two endpoints. The stream index provides a powerful method for focusing on individual conversations within a large packet capture.
ποΈ Topics Covered
This lecture explains what a TCP stream is in Wireshark, how the stream index field is assigned to unique connections, and provides step-by-step instructions for creating a filter based on the tcp.stream field. The practical demonstration uses the tr-chappellu.pcapng trace file and shows how to apply a filter from Packet 59's TCP header.
π Lecture Summary
Filtering TCP Conversations with the Stream Index Field
In this topic, we describe how to filter TCP conversation with the stream index field in Wireshark.
What is a Stream? Wireshark assigns each unique TCP connection attempt a separate TCP stream based on the source/destination addresses and source/destination port numbers. Letβs create a filter based on the tcp.stream field.
Step 1: Open tr-chappellu.pcapng.
Step 2: Expand the TCP header in Packet 59.
Step 3: Right-click on the [Stream index: 7] field in the TCP header. Select Apply as Filter | Selected.
π‘ Why this matters: The stream index allows you to instantly isolate all packets belonging to a specific TCP conversation, making it much easier to analyze individual connections within a busy trace file.
π Definition β Stream index: A unique number Wireshark assigns to each TCP connection based on the combination of source IP, destination IP, source port, and destination port. This index allows you to filter and view packets belonging to a specific conversation.
β Key Takeaways
The stream index field is a powerful filtering mechanism in Wireshark that uniquely identifies each TCP conversation based on source/destination addresses and ports. You can quickly apply a filter by right-clicking the [Stream index: N] field in any packet's TCP header and selecting "Apply as Filter | Selected". This method is especially useful when a trace file contains many TCP conversations, as it allows you to isolate the most active or relevant conversation. The stream index value (e.g., 7) can be used with the filter expression "tcp.stream==7" to display only packets from that specific conversation. Remember to use the Clear button to remove your filter when finished analyzing a particular stream.
π§ Quick Revision Questions
- What criteria does Wireshark use to assign a unique TCP stream to each connection attempt?
- Where in the packet details pane can you find the [Stream index: N] field?
- What menu option should you use after right-clicking the stream index field to create a filter?
- Why is the stream index filter particularly useful when a trace file contains many TCP conversations?
- What should you do when you are finished analyzing a specific TCP stream?
π Lecture 120 β Wireshark Lab 28
π Overview: This lecture demonstrates how to add a TCP stream index column in Wireshark to differentiate multiple TCP conversations within a trace file. It explains the concept of TCP stream indexing and provides step-by-step instructions for adding and utilizing this column for filtering and analysis.
ποΈ Topics Covered
This lecture covers the concept of TCP stream indexing in Wireshark, including how each unique connection attempt is assigned a tcp.stream value starting at 0. It provides a step-by-step procedure for adding a Stream Index column to the packet list, sorting by conversations, and identifying the total number of TCP streams in a trace file (23 in the example).
π Lecture Summary
Topic 120: Wireshark Lab 28
This topic shows how to add a TCP stream index column in Wireshark. There can be numerous TCP conversations in a trace file, and Wireshark calls each unique connection attempt a TCP stream. To differentiate the TCP conversations, Wireshark assigns each unique connection attempt a separate TCP stream index based on the source/destination addresses and source/destination port numbers. Wireshark numbers each separate TCP conversation with a TCP Stream Index (tcp.stream) value starting with 0.
The lecture demonstrates this using a packet that is part of the first TCP conversation in a trace file, shown in Figure 120.1.
π Definition β TCP Stream Index (tcp.stream): A unique numeric identifier assigned by Wireshark to each distinct TCP connection attempt, based on source/destination addresses and port numbers, starting at 0.
Step 1: Open the Trace File
Open tr-chappellu.pcapng to begin the lab exercise.
Step 2: Add the Stream Index Column
Expand the TCP header in Packet 1. Right-click on the [Stream index: 0] line and select Apply as Column. This action adds a new column to the packet list pane that displays the stream index for every packet.
Step 3: Sort and Count TCP Conversations
Click on the Stream index column once to sort the trace file by conversations. Jump to the end of the trace file and you will find that there are 23 TCP conversations. Remember that counting TCP streams starts at 0, so the streams are numbered 0 through 22.
π Example: In the trace file tr-chappellu.pcapng, after adding the Stream Index column and sorting by it, you can observe that the first conversation has stream index 0, the second has stream index 1, and so on, up to stream index 22 (total 23 conversations).
β Key Takeaways
The TCP Stream Index (tcp.stream) is a fundamental Wireshark feature for isolating and analyzing individual TCP conversations within large trace files. Each unique connection attempt receives a unique stream index starting at 0, based on source/destination IP addresses and port numbers. Adding the Stream Index as a column allows quick sorting and counting of all TCP conversations in a trace file. In the example trace file, there were 23 TCP conversations (stream indices 0 through 22). The Stream Index column is essential for filtering specific conversations and exporting them to separate trace files for focused analysis.
π§ Quick Revision Questions
- What does the TCP Stream Index (tcp.stream) represent in Wireshark?
- What information does Wireshark use to assign a unique TCP stream index to each conversation?
- How do you add a Stream Index column to the packet list pane in Wireshark?
- In the example trace file tr-chappellu.pcapng, how many TCP conversations were present and what were their stream index ranges?
- Why must you remember that counting TCP streams starts at 0 when interpreting the total number of conversations?
π Lecture 121 β Wireshark Lab 29
π Overview: This lecture introduces how to add and sort a TCP Delta Time column in Wireshark. Understanding tcp.time_delta is crucial for analyzing TCP performance, as it measures the time between consecutive packets in the same TCP stream, helping to pinpoint network delays.
ποΈ Topics Covered
This lecture covers the definition and purpose of the TCP Delta Time column, the steps to add it by enabling the TCP Calculate conversation timestamp preference, and how to sort it for analysis. The practical example uses the tr-chappellu.pcapng trace file to demonstrate the process.
π Lecture Summary
Adding/Sorting a TCP Delta Time Column
The tcp.time_delta field shows the time from the end of one packet in a TCP stream to the end of the next packet in that same TCP stream. To add the tcp.time_delta column, you must first enable the TCP Calculate conversation timestamp preference. This is done by clicking the Preferences button, expanding Protocols, and choosing TCP.
π Definition β tcp.time_delta: The time measured from the end of one packet to the end of the next packet in the same TCP stream.
π Formula: tcp.time_delta = time_end_of_packet_N+1 β time_end_of_packet_N β This gives the interpacket delay for packets in the same TCP conversation.
π Example: In the tr-chappellu.pcapng trace file, adding the tcp.time_delta column allows you to see the exact time gaps between successive TCP packets in the same stream. Sorting by this column highlights the slowest or fastest packet pairs, aiding in troubleshooting delays.
π‘ Why this matters: Enabling this setting allows Wireshark to compute the delta for each packet; without it, the column will show no data. The preference is found under Preferences β Protocols β TCP.
β Key Takeaways
You must enable the TCP Calculate conversation timestamp preference in Wireshark before the tcp.time_delta column can display any values. The tcp.time_delta measures only the time between consecutive packets within the same TCP stream, not between arbitrary packets. This column is invaluable for locating performance bottlenecks such as retransmissions or application delays. Adding and sorting by tcp.time_delta helps quickly identify the slowest points in a TCP conversation. The example file used in the lecture is tr-chappellu.pcapng.
π§ Quick Revision Questions
- What is the exact field name in Wireshark for the TCP delta time?
- What preference must be enabled for the tcp.time_delta column to work?
- Between what two points is tcp.time_delta measured?
- How do you access the TCP Calculate conversation timestamp preference?
- In the lecture, which trace file is used as the example?
π Lecture 122 β Wireshark Lab 30
π Overview: This lecture demonstrates how to create a custom TCP Delay button in Wireshark to efficiently locate network communication delays. It covers the step-by-step process of adding a filter expression as a button and refining it to exclude irrelevant packets such as FIN, RST, and HTTP GET requests.
ποΈ Topics Covered
The lecture covers creating a TCP Delta column to measure delays between packets in a TCP stream, then building a TCP Delay button using the tcp.time_delta filter expression. It then refines the filter to exclude TCP FIN and RST packets, and finally HTTP GET requests, to focus on meaningful delay indicators like SYN retransmissions.
π Lecture Summary
Topic 122: Wireshark Lab 30
This topic describes how to add a TCP Delay Button in Wireshark. Using a "TCP Delay" button (filter expression) will allow us to efficiently locate delays. By pressing the button, TCP packets that are preceded by a noticeable delay will be displayed.
Step 1: Open tr-chappellu.pcapng.
Step 2: In the display filter area, enter the following filter: tcp.time_delta > 1
Step 3: Click the Save button on the display filter toolbar. Enter TCP Delay as the label when prompted. Click OK to save your new button.
Step 4: Click your new TCP Delay button. You will find that 37 packets match the filter. There are numerous TCP FIN packets in the list β we do not care about it.
π Definition β TCP FIN packet: A packet with the FIN flag set, used to gracefully terminate a TCP connection.
π Formula: Filter expression β tcp.time_delta > 1 (displays packets preceded by a delay greater than 1 second)
Step 5: Select Edit | Preferences | Filter Expressions, update TCP Delay filter expression to: tcp.time_delta > 1 && tcp.flags.fin==0 && tcp.flags.reset==0 and then Click OK.
π Definition β TCP RST packet: A packet with the RST flag set, used to abruptly reset or abort a TCP connection. π Example: After updating the filter, clicking the TCP Delay button again displays 23 packets because TCP FIN and RST packets have been removed.
Step 6: Click your TCP Delay button again. 23 packets are displayed because TCP FIN and RST packets have been removed. Letβs further remove HTTP GET requests from the TCP Delay button. Add the following string to the end of your filter: && !http.request.method=="GET". The highest TCP Delta delay is under 6 seconds and is a SYN retransmission packet. There are 12 SYN retransmissions between the client and 184.73.250.227. There is one SYN/ACK as the RTT is 1.28957 seconds.
π Definition β SYN retransmission: A retransmission of a SYN packet when the initial connection attempt does not receive a SYN/ACK response, indicating network delay or packet loss. π Definition β RTT (Round-Trip Time): The time it takes for a packet to travel from source to destination and back, measured here as 1.28957 seconds for a SYN/ACK.
π‘ Why this matters: Refining the filter to exclude FIN, RST, and HTTP GET requests allows network analysts to focus on genuine delay-causing events such as SYN retransmissions, which indicate connectivity issues.
β Key Takeaways
The lecture teaches how to create and refine a TCP Delay button in Wireshark using the tcp.time_delta > 1 filter to identify packets with delays over one second. The initial filter returns 37 packets, but by excluding TCP FIN and RST packets, this reduces to 23. Further removing HTTP GET requests reveals 12 SYN retransmissions between the client and 184.73.250.227, with the highest TCP Delta delay under 6 seconds. The RTT for one SYN/ACK is 1.28957 seconds, demonstrating how the refined filter isolates meaningful delay events for network troubleshooting.
π§ Quick Revision Questions
- What is the initial filter expression used to create the TCP Delay button?
- After applying the filter
tcp.time_delta > 1, how many packets were initially matched? - What two TCP flags were excluded in Step 5 to refine the filter from 37 to 23 packets?
- What is the RTT value (in seconds) for the SYN/ACK packet identified in Step 6?
- How many SYN retransmissions were found between the client and
184.73.250.227?
π Lecture 123 β Wireshark Lab 31
π Overview: This lecture explains how to estimate the Round Trip Time (RTT) using TCP handshake packets captured in Wireshark. It is critical for diagnosing network performance issues because high RTT causes file transfers to be very slow. By analyzing the
tcp.time_deltavalue between a clientβs SYN and the serverβs SYN/ACK, you can quantify the network delay.
ποΈ Topics Covered
The lecture covers the purpose of estimating RTT via TCP handshake, the use of tcp.time_delta in Wireshark, filtering for TCP SYN packets, sorting by TCP Delta column, and identifying the delay preceding SYN/ACK packets. A step-by-step lab using the tr-cnn.pcapng file is provided.
π Lecture Summary
Obtaining RTT Using TCP Handshake in Wireshark
A file transfer process will be very slow if the Round Trip Time (RTT) is extremely high, even when everything else functions properly. Wireshark allows us to estimate the RTT by looking at the tcp.time_delta value. We capture packets at the client side and examine the tcp.time_delta between the client's TCP SYN packet and the server's TCP SYN/ACK response.
π Definition β Round Trip Time (RTT): The time it takes for a packet to travel from source to destination and back again. In this lab, it is estimated by the delay between a TCP SYN and its corresponding SYN/ACK.
Step-by-Step Lab Procedure
Step 1: Open tr-cnn.pcapng.
Step 2: Enter tcp.flags.syn==1 in the display filter area and click Apply. This filter shows only packets with the SYN flag set, which includes both SYN and SYN/ACK packets.
Step 3: Click your TCP Delta column heading twice to sort from high to low. We are interested in the delays preceding SYN/ACK packets.
π Example: In a sorted view, the largest tcp.time_delta values will appear first. Look for a row where the Info column says [SYN, ACK]. The tcp.time_delta for that row represents the time elapsed since the previous packet (the initial SYN). This value is your approximate RTT.
π‘ Why this matters: By sorting high-to-low, you immediately spot the most severe RTT delays. If the delta before a SYN/ACK is very large (e.g., seconds), it indicates a problematic network path that will slow down all TCP-based file transfers.
β Key Takeaways
Students must remember that the RTT estimate from the TCP threeβway handshake is found by filtering for tcp.flags.syn==1 and then examining the tcp.time_delta value immediately preceding a SYN/ACK packet. The delay measured is the time from the clientβs SYN to the serverβs SYN/ACK, which approximates one half of the full RTT (since the server must first receive the SYN). Sorting the TCP Delta column from high to low quickly reveals the worst RTT values. This method requires capturing at the client side for accuracy. High RTT directly causes slow file transfers, making this a key diagnostic skill.
π§ Quick Revision Questions
- What display filter would you use to show only TCP SYN and SYN/ACK packets in Wireshark?
- Which column value gives the approximate RTT between a clientβs SYN and the serverβs SYN/ACK?
- Why must the capture be taken from the client side rather than the server side?
- After applying the filter, what is the purpose of sorting the TCP Delta column from high to low?
- If
tcp.time_deltafor a SYN/ACK is 0.5 seconds, what is the approximate RTT for that handshake?
π Lecture 124 β RTT: Packets 2 and 3 of TCP Handshake
π Overview: This lecture explains how to measure the Round Trip Time (RTT) between a client and server using the second and third packets of the TCP three-way handshake in Wireshark. Mastering this technique is essential for network performance analysis and troubleshooting latency issues.
ποΈ Topics Covered
The lecture covers the method for obtaining RTT using Packets 2 and 3 of the TCP handshake in Wireshark, including how to use the tcp.time_delta value between the server's SYN/ACK and the client's ACK response. It provides specific display filters for detecting the SYN/ACK packet and outlines the characteristics and filter criteria for identifying the tricky third handshake packet (ACK).
π Lecture Summary
Using Packets 2 & 3 of TCP Handshake for RTT in Wireshark
Packets 2 and 3 of the TCP three-way handshake can be used to measure the path latency or Round Trip Time (RTT). To do this, run a packet capturing tool such as Wireshark on the server host. Look at the tcp.time_delta value between the server's TCP SYN/ACK packet (Packet 2) and the client's TCP ACK response (Packet 3).
π Definition β tcp.time_delta: The time difference between two consecutive packets in a TCP conversation, used here to calculate RTT.
Detecting Packet 2 (SYN/ACK)
The second packet of the TCP handshake, the SYN/ACK packet, is easy to locate. Apply the following display filter in Wireshark: tcp.flags.syn==1 && tcp.flags.ack==1. This filter identifies packets where both the SYN flag (bit) and the ACK flag (bit) are set to 1.
Detecting Packet 3 (ACK)
Detection of the third packet of the handshake is more difficult. Use the following characteristics:
- a) tcp.seq==1 (Required) β The TCP Sequence Number is 1 (as a Relative Sequence Number)
- b) tcp.ack==1 (Required) β The TCP Acknowledgment Number is 1 (as a Relative Acknowledgment Number)
- c) tcp.len > 0 (Optional) β There is data present in the third packet of the handshake
- d) tcp.push==1 (Optional) β The PUSH bit is set
The complete display filter to capture both Packet 2 and Packet 3 is: (tcp.flags.syn==1 && tcp.flags.ack==1) || (tcp.seq==1 && tcp.ack==1)
π‘ Why this matters: The TCP handshake occurs at the start of every TCP connection. Measuring RTT from these two packets gives you the pure network latency without application-layer processing delays.
π Definition β Relative Sequence/Acknowledgment Number: In Wireshark, sequence and acknowledgment numbers are displayed relative to the initial values (starting from 0 or 1) for easier human readability, rather than the absolute 32-bit numbers used in the TCP header.
π Example: If you capture a TCP handshake and Packet 2 (SYN/ACK) has a timestamp of T=0.000 seconds and Packet 3 (ACK) has a timestamp of T=0.045 seconds, the tcp.time_delta for Packet 3 would be 0.045 seconds, representing the RTT of 45 milliseconds between the server and client.
β Key Takeaways
The Round Trip Time (RTT) in a TCP connection is measured using the time delta between Packet 2 (SYN/ACK) and Packet 3 (ACK) of the TCP three-way handshake. To detect Packet 2, use the filter tcp.flags.syn==1 && tcp.flags.ack==1. Detecting Packet 3 is more challenging and requires applying the filter (tcp.seq==1 && tcp.ack==1), with optional conditions tcp.len > 0 and tcp.push==1. The complete dual-packet filter is (tcp.flags.syn==1 && tcp.flags.ack==1) || (tcp.seq==1 && tcp.ack==1). The RTT is read directly from the tcp.time_delta value of Packet 3 when captured on the server host.
π§ Quick Revision Questions
- What is the complete display filter to capture both Packet 2 (SYN/ACK) and Packet 3 (ACK) of the TCP handshake?
- Which two required TCP header fields (by relative value) identify the third packet of the handshake?
- Where in Wireshark can the RTT value be found for these two packets?
- On which host should Wireshark be running to measure RTT using this method?
- What are the two optional conditions that may also apply to the third handshake packet?
π Lecture 125 β Wireshark Lab 32
π Overview: This lecture demonstrates how to calculate the Round Trip Time (RTT) using display filters in Wireshark. It is essential because RTT is a key metric for network performance analysis, and using display filters allows precise measurement of TCP handshake timing.
ποΈ Topics Covered
The lecture covers opening the trace file tr-chappellu.pcapng, applying the filter tcp.flags.syn==1 to isolate SYN packets, measuring RTT from the SYN and SYN/ACK pair, and then refining filters to capture second and third handshake packets. It also explores advanced filter conditions to exclude irrelevant packets like FIN flags.
π Lecture Summary
Step 1: Open the Trace File
Open the file tr-chappellu.pcapng in Wireshark. This trace was captured at the client side and will be used to locate TCP connection packets.
Step 2: Initial Filter for SYN Packets
Enter the filter tcp.flags.syn==1 in the display filter area and click Apply. This finds 58 packets matching the filter. The first two packets are from client port 35,621. Packet 3 and Packet 4 are the first two packets of a new TCP connection. The TCP Delta column shows the time from the TCP SYN (port 35,622) to the SYN/ACK for that same port. The RTT is approximately 17 ms.
π Definition β RTT (Round Trip Time): The time it takes for a packet to travel from source to destination and back, measured here between SYN and SYN/ACK.
π Example: In the trace, Packet 3 (SYN from port 35,622) and Packet 4 (SYN/ACK to port 35,622) have a TCP Delta of 17 ms β RTT = 17 ms.
Step 3: Filter for SYN/ACK and Sequence/Acknowledge Packets
Enter the filter: (tcp.flags.syn==1 && tcp.flags.ack==1) || (tcp.seq==1 && tcp.ack==1). Click Apply. This finds 69 packets matching. However, several packets in this set are not of interest because they include unrelated handshake packets.
Step 4: Enhance the Filter
Enhance the filter with additional conditions: (tcp.flags.syn==1 && tcp.flags.ack==1) || (tcp.seq==1 && tcp.ack==1) && tcp.len==0 && tcp.flags.fin==0. Click Apply. This excludes packets with FIN flags and ensures only zero-length TCP segments are considered, improving accuracy.
π‘ Why this matters: Adding these conditions removes extraneous packets (like connection teardown or data packets), isolating only the second and third handshake packets for precise RTT calculation.
β Key Takeaways
- RTT is measured by timing the SYN and SYN/ACK packets in a TCP handshake, using display filters in Wireshark.
- The filter
tcp.flags.syn==1isolates SYN packets; the TCP Delta column shows the time difference between matched packets. - For server-side captures, use
(tcp.flags.syn==1 && tcp.flags.ack==1) || (tcp.seq==1 && tcp.ack==1)to find second and third handshake packets. - Refine filters with
tcp.len==0andtcp.flags.fin==0to exclude data packets and FIN flags, ensuring accurate RTT measurement. - The trace
tr-chappellu.pcapngis used to demonstrate these techniques, with an example RTT of 17 ms.
π§ Quick Revision Questions
- What display filter isolates TCP SYN packets in Wireshark?
- How is RTT calculated using the TCP Delta column in Wireshark?
- What is the purpose of adding
tcp.len==0andtcp.flags.fin==0to the filter? - How many packets match the filter
tcp.flags.syn==1in the tracetr-chappellu.pcapng? - Why might the filter
(tcp.flags.syn==1 && tcp.flags.ack==1) || (tcp.seq==1 && tcp.ack==1)return more packets than needed?
π Lecture 126 β Wireshark Lab 33
π Overview: This lecture demonstrates how to use Wireshark's advanced I/O Graph to plot TCP delays and locate problematic conversations in a trace file. It teaches students how to filter out normal delays (like FIN packets) to isolate meaningful high-latency events for network troubleshooting.
ποΈ Topics Covered
Plotting maximum tcp.time_delta values using Wireshark's I/O Graph with the Advanced MAX(*) calculation; interpreting graph spikes to locate high-latency packets; applying filter expressions to exclude normal delays such as TCP FIN packets, reset packets, and HTTP GET requests.
π Lecture Summary
Plotting TCP Delays with Wireshark I/O Graph
This section explains how to use Wireshark's advanced I/O Graph to visualize maximum TCP delays. The goal is to plot the maximum tcp.time_delta value for each time interval to identify the worst delays in the trace file. The steps begin by opening the file tr-chappellu.pcapng, then navigating to Statistics | IO Graph. In the Y Axis Unit area, select Advanced..., then choose the MAX(*) Graph 1 Calc option and enter tcp.time_delta in the Calc area. Click the Graph 1 button to generate the graph.
π Formula: MAX(tcp.time_delta) β plots the highest time delta between successive TCP packets in each interval, showing the worst-case delay.
π Example: In the trace file, the graph reveals a delay spike around 25 seconds. Clicking on this high point jumps to Packet 155, where the TCP Delta column value is 15.757807 seconds. This packet is a TCP FIN, which is a normal delay and not of interest for performance analysis.
Filtering Out Normal Delays
To focus only on meaningful delays, the lecture introduces a filter expression that removes normal TCP termination packets and HTTP GET requests. After applying the filter, clicking on the largest remaining delay point jumps to Packet 86 β the actual packet of interest.
π Definition β Filter Expression: tcp.time_delta > 1 && tcp.flags.fin==0 && tcp.flags.reset==0 && !http.request.method=="GET" β this filter selects only TCP packets with a time delta greater than 1 second, excluding FIN packets (normal connection termination), reset packets (RST), and HTTP GET requests (which often have normal delays due to user behavior).
π‘ Why this matters: Without filtering, the largest delay might be a harmless FIN packet that simply waited for the connection timeout. By excluding these, you isolate the packets that represent true network or server performance problems.
β Key Takeaways
The most critical skill from this lecture is using Wireshark's I/O Graph with the MAX(tcp.time_delta) calculation to visually identify high-latency packets. Always apply a filter to exclude FIN, RST, and HTTP GET packets, as these often produce normal delays that are not indicative of network problems. The value 15.757807 seconds for packet 155 illustrates how FIN packets can dominate delay charts if unfiltered. After filtering, the largest delay points to packet 86 β the true problematic conversation. This technique allows network engineers to quickly isolate and investigate the worst-performing TCP connections in a capture file. The filter expressions can be saved as buttons for repeated use in identifying high path latency.
π§ Quick Revision Questions
- What Wireshark menu path is used to access the I/O Graph for plotting TCP delays?
- Which calculation option in the Advanced Y Axis settings is used to find the worst delay in each time interval?
- What is the TCP Delta value of Packet 155, and what type of packet is it?
- What four conditions are combined in the filter expression to exclude normal delays from the graph?
- After applying the filter, which packet number corresponds to the largest remaining delay in the example trace?