Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: $ftp->put() transfer stats

by Fletch (Bishop)
on Jul 30, 2010 at 18:26 UTC ( [id://852141]=note: print w/replies, xml ) Need Help??


in reply to $ftp->put() transfer stats

  • Store off the time before you start your put (possibly using Time::HiRes if you want more precision)
  • Call put
  • Subtract the current time from the start time
  • Divide the size of what you sent by the duration
  • Profit!

The cake is a lie.
The cake is a lie.
The cake is a lie.

Replies are listed 'Best First'.
Re^2: $ftp->put() transfer stats
by chananf (Initiate) on Aug 01, 2010 at 18:32 UTC
    Thank you - that is good to know!
    Also,I would like to get # bytes transferred
    We have a client that thinks we are sending zero byte files
    Now, we do along the following to verify # bytes sent :

    ftp->put($file, $remote_name);
    ftp->size($remote_name);


    I would prefer if we could get a diagnostic from the ftp object with num bytes sent
    Thanks!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://852141]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2024-03-19 14:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found