I'm creating a command line script in php that will use a lot of bandwidth so I want to monitor available bandwidth to balance the size of sending data. (Automatic TCP balancing it's not enough cause it can send a lot of data)
I'll be working under linux, I already use '/proc/meminfo' to monitor ram but I haven't found a general command(no external package) to monitor bandwidth.
I was thinking to monitor latency of a ping to google.com, but I'm not sure how to do it, any ideas?