SOME COMMANDS WITH THEIR EXAMPLES

📂 File and directory management

CommandDescription
cpCopies files or folders.
mvMoves or renames files or folders.
rmDeletes files or folders ⚠️ Use with caution (rm -rf).
mkdirCreates a new directory.
rmdirDeletes an empty directory.
touchCreates an empty file or updates its timestamp.
catDisplays the full content of a file.
less / moreDisplays file content page by page.
head / tailShows the first or last lines of a file.

⚙️ System management

CommandDescription
sudoExecutes commands with superuser privileges.
apt / dnf / yum / pacmanPackage managers depending on the distribution.
top / htopShows active processes and resource usage.
psDisplays running processes.
killTerminates a process.
dfShows free disk space.
duShows size of files or directories.
freeDisplays RAM usage.
uname -aShows OS and kernel information.
uptimeShows how long the system has been running.

🌐 Network and connectivity

CommandDescription
pingChecks connectivity with another machine.
ifconfig / ip aDisplays network configuration.
netstat / ssShows active connections and ports.
curlDownloads or sends data from/to a URL.
wgetDownloads files from the web.
scpCopies files between machines via SSH.
sshConnects to another machine via SSH.

🔐 Users and permissions

CommandDescription
whoamiShows the current user.
idShows user and group IDs.
chmodChanges file permissions.
chownChanges the owner of a file or folder.
adduser / useraddCreates a new user.
passwdChanges the user’s password.

🧰 Miscellaneous utilities

CommandDescription
manShows the manual for a command.
historyShows the command history.
grepSearches for text inside files.
echoPrints text or variables to the screen.
dateShows or sets date and time.
tarCompresses or extracts .tar or .tar.gz files.
zip / unzipCompresses or extracts ZIP files.
0

Subtotal