Reputation: 13
I have a SMPP server and client are running on different ports in the same machine, and i would like to capture the pcap to see the smpp messages. Because of the same machine, it was not captured in tshark command.
Is there any option to capture the messages if both client and server on the same machine?
Upvotes: 0
Views: 1111
Reputation: 450
Note you can capture on multiple interfaces at the same time with tshark, by using the -i
option multiple times. So one way to go about this is to take all the interfaces from the output of tshark -D
and put all of these interfaces in your tshark command-line like this:
tshark -i <iface0> -i <iface1> -i <iface2> ... <other options>
If you listed all interfaces and didn't find the traffic you wanted then tshark is likely not able to capture it.
Upvotes: 0
Reputation:
Some versions of UN*X support capturing on the "loopback" interface, which is the interface on which the traffic between the server and the client will appear. (Alpesh Gediya is mistaken here; the traffic may not be queued up for an actual network interface controller, but it is queued up for the loopback interface.) Others don't.
Try running tshark -D
the same way you ran tshark when you tried capturing traffic; if it reports an interface with a name such as lo
(Linux) or lo0
(*BSD, OS X, some other UN*Xes), try capturing on that interface. If it doesn't report such an interface, you're running on a UN*X that doesn't support capturing on the loopback interface, such as Solaris 10 or earlier.
Upvotes: 2
Reputation: 3794
While you have server and Clinet on same machine , Data packets are not put in NIC queue by Operating System due to this reason you can not capture packets on same machine.
You can use TCPMON utility to capture packates by routing it.
Upvotes: 0