[plug] Network/Modem related questions

William Kenworthy billk at iinet.net.au
Sun Jul 3 20:10:44 WST 2005


'man pppstats', 'man pppdump'

BillK

On Sun, 2005-07-03 at 19:15 +0800, Timothy White wrote:
> Hi. I'm doing a little bit of programming atm and need to find out how
> to get some realtime information about a ppp connection.
> Mainly I need current transfer rates (up and down) and it'd be nice to
> also have connection time and total transferred.
> It all needs to be easy to use as it's all being used in scripts. 
> I know that /proc/net/dev has total transmitted and received packets
> and bytes so if I sampled it and new the time between sampling I can
> get an average. Is that how other people do it? Would that be a little
> CPU intensive?
> 
> As it's all for a web application the speed readings wouldn't be
> needed all the time, just when the app requests it.
> 
> Also, whats the best way to tell that a modem is connecting but not
> yet connected? I was think maybe see if pppd or chat is running but
> ppp0 isn't up? Any other ideas?
> 
> Thanks
> 
> Tim
> _______________________________________________
> PLUG discussion list: plug at plug.org.au
> http://www.plug.org.au/mailman/listinfo/plug
> Committee e-mail: committee at plug.linux.org.au
> 
-- 
William Kenworthy <billk at iinet.net.au>
Home!




More information about the plug mailing list