ssh cheatsheet

Ever so often I find myself needing various ssh commands that help me accomplish tedious task. So with no further ado, this is my ssh cheat sheet that will be further enriched when I come across commands that I need.

Copying files using ssh and scp

Use the following snippet as a base to copy files over ssh using scp. This way you can copy files between different systems that support scp and ssh, like Windows and Linux.

Copy files from remote to local

scp -r /home/user/Desktop/

Copy files from local to remote

scp -r /home/user/Desktop/

The -r means recursively, and enables the command to copy an entire directory. Leave it out to just copy the file.

Leave a Reply

Your email address will not be published. Required fields are marked *