netuse icon indicating copy to clipboard operation
netuse copied to clipboard

dumper returning errors

Open parkour86 opened this issue 8 years ago • 2 comments

When running dumper from the commandline I get the following error: date: invalid date ‘%d %b %G’ ./dumper: line 16: /sys/class/net/ppp0/statistics/rx_bytes: No such file or directory ./dumper: line 16: /home/parkour86/.net///down/: Is a directory ./dumper: line 17: /sys/class/net/ppp0/statistics/tx_bytes: No such file or directory ./dumper: line 17: /home/parkour86/.net///up/: Is a directory

I was able to fix the invalid date error by adding a plus sign after date: read -r date month year <<< "$(date +'%d %b %G')"

This is what it shows now: ./dumper: line 16: /sys/class/net/ppp0/statistics/rx_bytes: No such file or directory ./dumper: line 17: /sys/class/net/ppp0/statistics/tx_bytes: No such file or directory

I checked and I don't have a ppp0 directory. Not sure what needs to be done.

parkour86 avatar Jun 27 '16 04:06 parkour86

Thanks for bringing this to attention!

Yes, this is because there is no ppp0 interface on your machine. netuse tracks usage of a particular interface only, and I had hardcoded this to be ppp0. You can list all your interfaces using ifconfig( on linux)

I'll have to make the interface selection configurable!

dufferzafar avatar Jun 27 '16 11:06 dufferzafar

That makes sense. I updated the ppp0 to my interface and it's working perfectly. Thanks.

parkour86 avatar Jun 27 '16 15:06 parkour86