I have linux system which is connected to the internet via an lte modem and I am communicating with it via modemManager. So I am having a little bit of difficulty in understanding the number of data bytes consumed.
root@raspberrypi-cm3:~# mmcli -b 0 ------------------------- Status | connected : 'yes' | suspended : 'no' | interfaces: 'wwan0' | IP timeout: '20' ------------------------- Properties | apn: 'myapn' | roaming: 'allowed' | IP type: 'none' | user: 'none' | password: 'none' | number: 'none' ------------------------- Stats | Duration: '105060' | Bytes received: '6300' | Bytes transmitted: '6209' root@raspberrypi-cm3:~# ping -c 1 -s 0 www.opendns.com 8 bytes from ****.****.****.*** seq =0 ttl=50 1 packet transmitted, 1 packet received, 0% packet loss root@raspberrypi-cm3:~# mmcli -b 0 ------------------------- Status | connected : 'yes' | suspended : 'no' | interfaces: 'wwan0' | IP timeout: '20' ------------------------- Properties | apn: 'myapn' | roaming: 'allowed' | IP type: 'none' | user: 'none' | password: 'none' | number: 'none' ------------------------- Stats | Duration: '105090' | Bytes received: '6512' | Bytes transmitted: '6359'
So according to modem manager. I am consuming 150 bytes of data to send a ping to opendns and I am receiving 212 bytes of data?
But how is this possible. I am transmitting 8 bytes and receiving 8 bytes with ICMP header the total will be 16 bytes of data received.
Can someone explain me where are these addition data bytes coming from? Are they simply an over-head when I am communicating with my nameserver? If thats an over-head is there some sort of formula that I can use to calculate the approximate data consumed?
My end goal is just to cross-verify the total data bytes consumed
Advertisement
Answer
I found my answer by using tcpdump
to create a pcap file. Thanks for down voting my question and not providing any answer. For other beginners like me. If you are facing a similar problem. Please use tcpdump
this will give you an detailed explanation on packets sent and received by your device.