Linux Common Commands
Navigation
Command | Description |
---|
cd | Change Directory, moves the current working directory to the specified directory. |
pwd | Print Working Directory, displays the current working directory. |
ls | List Files and Directories, lists files and directories in the specified directory. |
mkdir | Make Directory, creates a new directory with the specified name. |
rm | Remove Files or Directories, deletes files or directories. |
mv | Move or Rename Files/Directories, moves or renames files or directories. |
cp | Copy Files or Directories, copies files or directories. |
ln | Link Files or Directories, creates a symbolic link to the specified file or directory. |
File Editing
Command | Description |
---|
vi | Visual Editor, opens a file for editing using the vi editor. |
emacs | Emacs Editor, opens a file for editing using the emacs editor. |
nano | Nano Editor, opens a file for editing using the nano editor. |
gedit | Gnome Text Editor, opens a file for editing using the gedit editor. |
cat | Concatenate Files, displays the contents of one or more files. |
System Management
Command | Description |
---|
whoami | Who Am I?, displays the current user’s name. |
uptime | Uptime, displays how long the system has been running. |
reboot | Reboot, reboots the system. |
shutdown | Shutdown, shuts down the system. |
halt | Halt, halts the system. |
poweroff | Power Off, powers off the system. |
Networking
Command | Description |
---|
ping | Packet Internet Groper, sends ICMP echo requests to the specified host and displays the response. |
ssh | Secure Shell, establishes a secure connection to the specified host. |
scp | Secure Copy, securely copies files or directories between hosts. |
sftp | Secure File Transfer Protocol, securely transfers files or directories between hosts. |
telnet | Telnet, establishes a remote terminal connection to the specified host. |
Package Management
Command | Description |
---|
apt-get | Advanced Package Tool, installs, removes, or updates packages using the apt package manager. |
yum | Yellowdog Updater, Modified, installs, removes, or updates packages using the yum package manager. |
pip | Python Package Installer, installs or upgrades Python packages. |
gem | Gem Package Manager, installs or upgrades Ruby packages. |
Shell
Command | Description |
---|
echo | Echo, displays the specified string. |
exit | Exit, exits the shell and terminates the current session. |
cd | Change Directory, moves the current working directory to the specified directory. |
pwd | Print Working Directory, displays the current working directory. |
ls | List Files and Directories, lists files and directories in the specified directory. |
Note: This is not an exhaustive list of Linux commands.