Copy and continue copying large files over file sharing

Thu, 2008 Mar 20, 11:05am

In my experience, there is often a flaky slow server at work that contains vital files on it. This is fine when you need to retrieve files that are small, but what happens when you need to copy a large file? Most of the time these servers don’t support ftp protocol and if you are on a Mac, you have to connect via smb (Samba) to the share and start copying and hope you don’t have to stop, because if you stop the copy, the file disappears from your machine and you can’t resume it.

However, I stumbled on this gem the other day:

curl -C - -O file:///Volumes/samba_share/file/path/here.txt

Basically, curl allows you to copy a file with url syntax in the terminal. The capital “O” tells curl to copy the file to your desktop with the same name as the file on your server, and the capital “C” tells it to continue where it may have left off. You can monitor the download in the terminal window. If you need to leave work and finish the copy the next day, simply enter the command again in the terminal and it will pick up the copy where it left off.

Entry Filed under: geek, technology, terminal

Leave a Comment

Required

Required, hidden

Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Trackback this post  |  Subscribe to the comments via RSS Feed


Site Decryption

info = { PlaIns: "the section of the PlasticStare site, the digital external brain-repository of Ryan Todd, whose brain otherwise occupies space in San Francisco, CA", ryota: "mungified version of ryan's name", haikuBio: "robotic from birth. hears sounds - listens to music. makes pixels act." }

Calendar

March 2008
S M T W T F S
« Feb   Apr »
 1
2345678
9101112131415
16171819202122
23242526272829
3031  

Most Recent Posts