Glam Prestige Journal

Bright entertainment trends with youth appeal.

I want to download files from a remote server to my local drive, and do it from the command line. I also want to be able to do this over SSH. How can I do this?

Note: the remote server is Ubuntu, the local is Mac OS X

0

4 Answers

Use scp-command, it runs on top of SSH. Example:

scp :/path/to/file localfile

It also works another way round

scp localfile username@host:/path/remotefile

Username, path, and filename can be omitted (but not the : !).

As Iain said, SFTP works also, but I tend to favor scp for its cp-like usage.

6

You can also use rsync for it. It can work over SSH.

2

I use SFTP for this. It's command line and uses the same security as SSH.

If you can't use scp or SFTP you can use tar over SSH:

tar cf - . | ssh otherhost "cd /mydir; tar xvf -"

This one is also good if you have sparse files which otherwise will "explode".

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy