πŸ’»Linux Terminal Cheat Sheet

Master the Linux terminal with essential commands. Your quick cheat sheet for efficient navigation and task execution.

CommandDescription

apt-get update

Update package lists

apt-get upgrade

Upgrade all installed packages

apt-get install <package>

Install a package

apt-get remove <package>

Remove a package

apt-cache search <keyword>

Search for packages

dpkg -i <package.deb>

Install a .deb package

dpkg -r <package>

Remove a package

service <service> start

Start a service

service <service> stop

Stop a service

service <service> restart

Restart a service

service <service> status

Check service status

ifconfig

Display network interfaces

ping <host>

Ping a host to check connectivity

netstat -tuln

Show listening ports

nmap <host>

Perform a network scan

ps aux

Display running processes

kill <pid>

Kill a process by ID

chmod <permissions> <file>

Change file permissions

chown <user>:<group> <file>

Change file ownership

grep <pattern> <file>

Search for a pattern in a file

ls -l

List files and directories with details

cd <directory>

Change to a specific directory

pwd

Display current working directory

mv <old> <new>

Move or rename a file or directory

cp <source> <destination>

Copy files or directories

rm <file>

Remove a file

mkdir <directory>

Create a new directory

echo "text"

Print text to the terminal

Note: Replace placeholders like <package>, <service>, <host>, etc., with actual values.

For more commands and in-depth information, refer to the Kali Linux documentation.

Last updated