Another way to generate traces from within our Elastix server's command line is to use the tcpdump
program. This program sets a specified network device in order to catch all the IP traffic that goes through it.
The next example shows the command we need to execute in order to capture packets in the network device
eth0
.tcpdump -pi eth0 -s0 host XXX.XXX.XXX.XXX and udp port 5060 -vv -w file.cap
The option
-s0
captures packets of any size fromhost XXX.XXX.XXX.XXX
traveling through the udp port5060
and writes the output to thefile.cap
file. The specified host could be the IP address from an IP phone or from a VoIP provider. After making one or two calls, we exit this command by pressing Crtl + C. Then, we can transfer this file to our laptop or work station and open it, using Wireshark.In case we would like to use the TCPDUMP command over IAX, the way this command can be issued is as follows:
tcpdump -pi eth0 -s0 host XXX.XXX.XXX.XXX and udp port...