Skip to content

Network packets debug with tcpdump


tcpdump -c ${package_number} -i eth0 -nn dst port ${PORT} -w FILE.packets


  • -i interface
  • -w write for file
  • -c count
  • -A prints out every packet’s contents
  • -n By default tcpdump will translate IP addresses to host names. -n forces it to just print the IP
  • -e Includes the MAC address that the packet came from
  • -p Filters to only packets to/from your computer’s IP address

TCP Control Flag




  1. License under CC BY-NC 4.0
  2. Copyright issue feedback, replace # with @
  3. Not all the commands and scripts are tested in production environment, use at your own risk
  4. No privacy information is collected here
Try iOS App