1

My system(CentOS6) crashed, and I got a vmcore.

Now I want to know how to get /proc/net/dev in vmcore, or how can I get net statistics counter data(e.g, netstat -s)?

I trigger a crash on CentOS7, and I can find some counters after run net and struct commands:

crash> net
   NET_DEVICE     NAME   IP ADDRESS(ES)
ffff881053f97000  lo     127.0.0.1
ffff88084ece0000  eth0   xxx.xxx.xxx.xxx
ffff88084e480000  eth1   xxx.xxx.xxx.xxx
crash> struct net_device ffff88084ece0000
......
stats = {
    rx_packets = 122192214759, 
    tx_packets = 122785688757, 
    rx_bytes = 140670240738618, 
    tx_bytes = 136965095362827, 
    rx_errors = 0, 
    tx_errors = 0, 
    rx_dropped = 0, 
......

But it doesn't make sense in CentOS6, I just get 0 for all counters:

crash> net
   NET_DEVICE     NAME   IP ADDRESS(ES)
ffff881028a10020  lo     127.0.0.1
ffff8820253a4020  eth0   xxx.xxx.xxx.xxx
ffff8820253a8020  eth1   xxx.xxx.xxx.xxx
......
stats = {
    rx_packets = 0, 
    tx_packets = 0, 
    rx_bytes = 0, 
    tx_bytes = 0, 
    rx_errors = 0, 
    tx_errors = 0, 
    rx_dropped = 0, 
......

Does it mean that on CentOS6 net counters are NOT stored in memory?

Thanks!

wuyihao
  • 168
  • 11
Barathrum
  • 79
  • 9

0 Answers0