I want to create a dragon script which checks the connection bandwidth. I'm thinking of downloading / uploading a known size file using urllib2 and takes time to do this task. I would like to measure the delay on a given IP address, as if the IP is pinged, is it possible urllib2?
You can use it for this. Returns information about: CURLINFO_TOTAL_TIME, CURLINFO_NAMELOOKUP_TIME, CURLINFO_CONNECT_TIME, CURLINFO_PRETRANSFER_TIME etc.
Comments
Post a Comment