
The SSH (Secure Shell) protocol lets a user connect remotely to a computer from another. The communication goes through an encrypted connection. It uses public key cryptography to ensure a safe connection to the SSH Server from an SSH Client. Here are some basic SSH commands that you need to know.
| Command | What the command action does |
|---|---|
| exit | This exits the connection |
| reboot | This will reboot the device |
| sudo | Allows you to run commands as a “Super User” |
| ls | Show directory contents |
| cd | Change Directory |
| mkdir | Create a new folder |
| touch | Create a new file |
| pwd | Shows current directory (full path to where you are right now) |
| cat | Show contents of a file |
| rm | Remove a file/folder |
| cp | Copy a file/folder |
| mv | Move a file/folder |
| grep | Search for a specific phrase in file/lines |
| find | This searches files and directories |
| vi/nano | Text Editors |
| history | Shows the last 50 used commands |
| clear | This clears the screen |
| tar | Create and Unpack Compressed Archives |
| wget | Download Files from the internet |
| du | Get File Size |
| head | Lets you read the first 10 lines of content inside a file. |
| tail | Lets you read the last 10 lines of contents inside a file |
| zip | A compression and file packaging utility |
| unzip | This is to decompress a file package |
| chmod | Stands for “Change Mode” – Changes file/folder permissions |
| wall | This broadcasts a message to all logged-in users |
| w | This displays all logged-in users |
| who | This provides a more detailed look at the logged-in users |