Show packet content in detail
Very verbose output with the ASCII content of PostgreSQL packets
tcpdump -i eth0 -vvv -A -s 0 port 5432
- tool
- tcpdump18 commands
More tcpdump commands
-
tcpdump -i eth0 -c 100 -w capture.pcapStop after 100 packets and save them to capture.pcap
-
tcpdump -nn 'tcp[tcpflags] & (tcp-syn|tcp-ack) == tcp-syn'Catch only SYNs that open a connection (no SYN-ACK) to spot scans or SYN floods
-
tcpdump -nn 'tcp[tcpflags] & (tcp-syn|tcp-fin) != 0'Show only packets that open or close connections to track short-lived sessions
-
tcpdump -nn -i any host <ip> and not port 22Watch traffic to and from a host but hide your own SSH session
-
tcpdump -nn -s 0 -X -i any port <port>Show full packet bodies in hex and ASCII, -s 0 makes sure nothing is cut off