Command | Description |
ssh (username@ipadres) | Connect to server |
ip a | Get the current IP address |
sudo apt upgrade | Get the latest upgrades |
sudo apt update | Update the upgrades |
sudo apt install (name) | Installs software |
sudo apt-get update && apt-get upgrade -y && apt autoremove -y | Gets updates, installs updates and auto removes old stuff |
apt-get install curl | Installs curl |
curl -sSL https://get.docker.com | sh | Gets docker installed through curl |
apt install docker-compose -y | Installs docker compose |
clear | Clears the screen/ history |
whatis (app) | Explains what the program does |
man (app) | Detailed explanation of the program |
ls | See the files/ directories |
ls -l | See the files/ directories (in a list) |
ls -al | See the files/ directories (incl. Hiding items) |
pwd | Print Working Directory (current location) |
cd | Change directory |
cd.. | One directory back |
mkdir (name) | Make a directory |
Rmdir (directory) | Removes a directory |
Touch (filename) | Creates a file |
nano | File editor |
cat (filename) | Shows you what is in a file |
cp (filename) (directory) | Copies a file to a directory |
mv (filename) (directory) | Moves a file to a directory |
rm (filename) | Removes a file |
curl (locatoin > file/directory | Downloads from the internet |
sudo find / -name “file” | Searches for a file |
chmod +x (file) | Makes the files executable |
ip address | Provides details of your network |
resolvectl status | Provides you the DNS server |
ping (website) | Is your website running |
traceroute (website) | Provides trace to the destination |
netstat | Provides the open poorts |
sudo ufw allow (poort) | Opens a poort for usage |
sudo ufw status | Provides the status |
sudo ufw enable | Enables the service |
uname -a | Provides details of your OS |
sudo apt install neofetch | Installs a “nicer” tool to view OS info |
neofetch | Provides “nicer” details of your OS |
free | Shows details of the memory |
df -H | Details of file system |
ps -aux | Details on processes running |
htop | Provides details of current processes (nicer) |
kill -9 (process id) | Kills a process |
pkill -f (process name) | Kills the process by named |
sudo systemctl stop (service) | Stops a service |
sudo systemctl start (service) | Starts a service |
sudo systemctl restart (service) | Restarts a service |
sudo systemctl status (service) | Provides status of the service |
sudo reboot | Reboots the system |
sudo shutdown | Shutdown the system |