curl-users
Re: -k not working?
Date: Tue, 10 Jul 2012 20:05:10 -0500
On Tue, Jul 10, 2012 at 07:29:52PM +0300, Kees Nijssen wrote:
> Op 10 jul. 2012 om 03:48 heeft Mike Brown <brown_at_mrvideo.vidiot.com> het volgende geschreven:
> > curl -C -k -T filename_to_send -u user:password ftps://domain.name/
> The -C option actually takes an offset as argument, so using -C -k would have curl interpret -k as the offset, and not recognize it as --insecure.
Thanks for the reply. I discovered it right before I read your response.
I went back and reread the on-line man page. Don't know how I missed the
"-C -" note in the description for the option.
The -k option now works on the Linux box. Just checked it on the Solaris box
and it works there as well.
While I was testing the -k option, I discovered that the "-C -" option isn't
working. The file transfer appears to have started from scratch.
The server I am transferring to does allow continuation. After wasting lots of
hours, until I figured out what was going on, I restarted the xfers using ncftp
(which doesn't support SSL) and it picked up where it left off when I cancelled
the upload.
I had a wild thought and decided to do a little test. I started a fresh
transfer and then killed it:
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
63 22.1M 0 0 63 14.1M 0 16709 0:23:09 0:14:45 0:08:24 30842^C
I then restarted the transfer and let it go to completion:
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 8184k 0 0 100 8184k 0 15306 0:09:07 0:09:07 --:--:-- 2053
100 8184k 0 0 100 8184k 0 15290 0:09:08 0:09:08 --:--:-- 15290
My wild thought was proven. What was my wild thought? Curl didn't report
what I expected. What curl should really do, when resuming, is to fill in
the numbers as to what was already transferred. All of the numbers, except
"Time Total" and "Time Spent" should have been equal to what they were when
I did the Ctrl-C. Of course, "Average Speed Upload" and "Current Speed"
would be a little different.
By starting the numbers over, it is very misleading. The total file size is
22.1M, not 8184k.
MB
-- e-mail: vidiot_at_vidiot.com | vidiot_at_vidiot.net /~\ The ASCII 6082066843_at_email.uscc.net (140 char limit) \ / Ribbon Campaign Visit - URL: http://vidiot.com/ X Against http://vidiot.net/ / \ HTML Email ------------------------------------------------------------------- List admin: http://cool.haxx.se/list/listinfo/curl-users FAQ: http://curl.haxx.se/docs/faq.html Etiquette: http://curl.haxx.se/mail/etiquette.htmlReceived on 2012-07-11