LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   ifconfig (https://www.linuxquestions.org/questions/slackware-14/ifconfig-40672/)

Astro 01-07-2003 10:57 PM

ifconfig
 
Anyone know anything about ifconfig and why it resets the downloaded data and uploaded data after about 3 gigs or so? I'd like to keep a running total but I don't know if ifconfig can do that. I'd e-mail the developer but I don't know an e-mail for them... Let me know what you think.

DavidPhillips 01-08-2003 01:30 AM

I do believe there is a problem where the counter rolls over at some point.

Astro 01-08-2003 01:44 AM

Fixable?
 
Is this something that is somehow patchable or is there a fix out for it? Not that it would help, but would contacting the developers help in this issue? I'm just looking to get an accurate count of how much I've downloaded/uploaded just using ifconfig.

DavidPhillips 01-08-2003 03:44 AM

I'm not sure if there was a fix for it or not. I can't seem to find what the actual problem is, although I believe it is due to them using the wrong type of variable or something like that. I have seen it mentioned in a couple of documents, but I have forgotten where.


There is some talk about it not being very accurate as well. I have not tested this.

Excalibur 01-08-2003 06:42 AM

I think the numbers you are talking about are really a kernel issue. The ifconfig program stats are simply reporting the contents of /proc/net/dev from the kernel. Try the following command:

cat /proc/net/dev

The text reported is the same values that ifconfig reports but in a raw data form. Fairly difficult to read.

The kernel is probably using a double for the data type at present, in order to even show a 3 GByte number. But whatever data type is chosen, it would rollover at some point anyway. All data types have a min and max value.

As for error margin, I would think the byte count is accurate. However, the packet count is difficult to use because a packet can vary in size. I think the max packet size is something like 1500 bytes and the min is 64 bytes or close to that range.

Astro 01-08-2003 03:46 PM

I see the output is rather nasty... so is it worth it to persue a fix for this to keep a running total? or should I just forget about it all together. RIght now I'm not even sure what ifconfig is packaged with, though I havn't looked much.

DavidPhillips 01-08-2003 04:30 PM

it could be that the latest kernels have been fixed, I have not seen anything saying it has though. I guess it's not top priority.


All times are GMT -5. The time now is 01:50 AM.