What does the TCP three-way handshake look like in a capture?
BeginnerScenarioPerformance, MTU, Latency & Tools
Answer
Situation read → Reading SYN, SYN-ACK, ACK in tcpdump helps spot where a connection fails.
What I'd do →
- Client sends SYN, server returns SYN-ACK, client sends ACK
- In tcpdump look for flags
[S],[S.],[.] - Only
[S]repeated means packets are dropped or the server is unreachable [R.]after[S]means the port is closed- Capture with
tcpdump -ni eth0 'host 10.0.1.5 and tcp port 22'
Why → The pattern of flags tells you whether the problem is a drop, a reject or an application issue.
Interview tip → Say repeated SYN means firewall drop; RST means closed port.
More on Performance, MTU, Latency & Tools
Latency, bandwidth and throughput: what is the difference and why does it matter?BeginnerWhen do you use ping, traceroute and mtr?BeginnerWhat is MTU and what is the usual value?BeginnerHow do you check what is listening on a port and who is connected?BeginnerHow do you measure where time goes in a slow HTTP request?BeginnerWhat does tcpdump do and what are the first filters you use?Beginner