Sunday, August 06, 2006

OpenSSH Installation, SCP, SFTP

Installation of OpenSSH was a breeze. Just one command from Breezy Badger (Ubuntu 5.10) server installed it on my server: apt-get install openssh-server. Now I can administer my box from anywhere! Yay! (provided, of course, no power outages, etc...)

To SSH into a server: ssh <username>@<ip address>

To upload a directory recursively (with encryption... blowfish is an encryption algorithm and scp stands for secure copy protocol, a utility available on almost all UNIX-derived machines): scp [-c blowfish] -r <source path> <username>@<target ip address>:<target path> To download over scp, switch the source and target.

For example, to upload from your music collection:
scp -r /home/<username>/Desktop/Musical/Music/Depeche\ Mode/ <username>@<server address>:/home/<username>/Musical/Music/

And to do the opposite (download a directory from the server, in this example to the current directory): scp -r <username>@<server address>:/home/<username>/Musical/ .

Another option is sftp which can perform ftp-like operations (including interactive sessions) over an ssh connection.

Links:
Manpages:

No comments: