Date: Sat, 20 Sep 2003 09:09:39 -0700 (PDT) From: jimmie james <h2g2_jimmiejaz@yahoo.com> To: freebsd-questions@FreeBSD.org Subject: Re: ppp and downloaded MBs Message-ID: <20030920160939.15862.qmail@web13409.mail.yahoo.com>
next in thread | raw e-mail | index | archive | help
>$ ppp -auto tdsl >$ ppp -v /var/run/internet dial # i used "set server >/var/run/internet" in /etc/ppp/ppp.conf >logged the bytes sent and received so i could calc the >downloaded MB per month (cause i use MB limited dsl) >any ideas how to calc the downloaded MB per month ? or >is there a >better way to establish the internet connection using >tdsl ? What I do, is use a perl sysinfo script, (http://www.geocities.com/h2g2_jimmiejaz/sys0pl.txt) just rename it to sys.pl and chmod 755 (runs in console, or irc as /exec -o ... The only problem with it is, if you reboot, it wipes the buffers of the info... The relevent lines are. (I'm using straight ppp, so you'd have to change tun0 to your device, and count the correct portion of netstat -i -n -b for this part.. head -n1 | awk '{print \$10}') It might not be excatly what you need, but it can give you an idea of what your transfer rate is, in and out) This is how it looks: root@fortytwo.daemon.sh FreeBSD 4.9-PRERELEASE | Sound: AudioPCI ES1373-B at /dev/pcm0 | Memory: 167 of 257 mb (65%)| Disk Usage(ad0): 2.0 of 6.8 gb (29%) | GFX: 1280x960 @ 24, bpp | Net: I/O: tun0 In: 27.50M Out: 4.09M | Uptime: 13:03, 6 users, load averages: 2.71, 2.73, 2.78 __________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030920160939.15862.qmail>