About
Community
Bad Ideas
Drugs
Ego
Erotica
Fringe
Society
Technology
register | bbs | search | rss | faq | about
meet up | add to del.icio.us | digg it
Go Back   Community > Technology > Everything *NIX
Register FAQ Members List Calendar Today's Posts

Everything *NIX This is a general forum about all forms of *nix. Post your ideas and thoughts on this wonderful OS family. Talk about your personal favorite flavor of *nix and why you think it's so much better than the others. Anything pertaining to *nix and *nix administration should be posted here.

Reply
 
Thread Tools Display Modes
  #1   Add rabbitweed to your ignore list  
Old 2008-04-29, 06:36
rabbitweed rabbitweed is offline
Regular
 
New Zealand Send a message via MSN to rabbitweed
Default Looking for an app for bandwith

...preferably something that can run in a gnome or xfce panel.

I share an internet connection and want something to be able to tell me how much bandwidth I use in the time space of a month.
Reply With Quote
  #2   Add ArgonPlasma2000 to your ignore list  
Old 2008-04-29, 09:27
ArgonPlasma2000 ArgonPlasma2000 is offline
Moderator
 
҉
Default Re: Looking for an app for bandwith

You can use a script to read off the received and transmit information from /sbin/ifconfig and add it to a total every time you shut down.

For example:
Code:
[AP2k@localhost ~]$ /sbin/ifconfig

eth0      Link encap:Ethernet  HWaddr **:**:**:**:**:**

          inet addr: ***.***.***.***  Bcast:255.255.255.255  Mask:255.255.255.0

          inet6 addr: ****::****:****:****:****/** Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:1131643 errors:0 dropped:0 overruns:0 frame:0

          TX packets:591919 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:823116761 (784.9 MiB)  TX bytes:203103689 (193.6 MiB)

          Interrupt:18 Base address:0x6800



lo        Link encap:Local Loopback

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:6333 errors:0 dropped:0 overruns:0 frame:0

          TX packets:6333 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:2801259 (2.6 MiB)  TX bytes:2801259 (2.6 MiB)
__________________
How do you kill five billion people? And who will be the ones to die?
Reply With Quote
  #3   Add rabbitweed to your ignore list  
Old 2008-04-29, 11:50
rabbitweed rabbitweed is offline
Regular
 
New Zealand Send a message via MSN to rabbitweed
Default Re: Looking for an app for bandwith

I'm a script noob to be honest; all I could do is output the entire results of ipconfig into a text file.

I have no idea how to make me shutting down trigger it, or how to make it add the numbers.

I'd be keen to learn though, what is "adding numbers" and "triggering shit by shutting down" called (ie what would I punch into a search engine)?

anybody point me in the right direction?
Reply With Quote
  #4   Add ArgonPlasma2000 to your ignore list  
Old 2008-04-29, 21:10
ArgonPlasma2000 ArgonPlasma2000 is offline
Moderator
 
҉
Default Re: Looking for an app for bandwith

In /etc/rc5.d/ are the scripts that are executed on shutdown and startup. Those starting with K are the scripts that execute on shutdown, and the ones with S get executed on startup. rc5 is the folder you should use if your default runlevel is 5. Its been a while since I had to figure out the default runlevel, but its 5 for Fedora distros, and probably alot of other ones as well.

I'm a script noob as well. I just know that's how I would do it if I could script well.
__________________
How do you kill five billion people? And who will be the ones to die?
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

 
To the best of our knowledge, the text on this page may be freely reproduced and distributed.
 

totse.com certificate signatures
 
 
About | Community | Bad Ideas | Drugs | Ego | Erotica | Fringe | Society | Technology
Hot Topics