SUMMARY
TCPDUMP and Other Networking Tools
ISSUE
Purpose
This article provides examples for the uses of the tcpdump command to diagnose and troubleshoot various networking issues.
Applies To
All Unitrends backup appliance software versions
TCPDUMP
tcpdump - dump traffic on a network
Examples
Show incoming packets on port 1194 from source 24.39.64.20
tcpdump -lnni eth0 port 1194 and src host 24.39.64.20
Show outgoing packets on port 1194 to destination 24.39.64.20
tcpdump -lnni eth0 port 1194 and dst host 24.39.64.20
Show contents of packets
tcpdump -lnni eth0 -s0 -x port 1194 and src host 24.39.64.20
IPTABLES
iptables - administration tool for IPv4 packet filtering and NAT
Display Firewall Rules
iptables -L
ROUTE
route -- manually manipulate the routing tables
Examples
List routing table
route
Set default gateway
route add default gw 192.168.0.1 eth0
Static routes
/etc/sysconfig/network-scripts/route-eth0
10.10.10.0/24 via 192.168.0.1 dev eth0172.16.1.0/24 via 192.168.0.1 dev eth0
WGET
Determine external ip address
wget -q -O - checkip.dyndns.org|sed -e 's/.*Current IP Address: //' -e 's/<.*$//'
Third Party Links
http://www.cyberciti.biz/tips/configuring-static-routes-in-debian-or-red-hat-linux-systems.html
http://www.cyberciti.biz/faq/linux-setup-default-gateway-with-route-command/
NOTES
Brandon Nelson - 6/18/2018 - Removed broken link.
20180809jmaynard- updated link
20191114jmaynard - updated link