# Top 25 Linux Commands I Use Weekly

#### A practical list of Linux commands I personally use most often during system monitoring, server administration, scripting, and troubleshooting.  
Use this list as a quick reference or jump-off point for deeper Linux command mastery.

---

## 🔧 System Monitoring &amp; Info

Shows real-time process activity, CPU usage, memory, and system load.

```bash
top
```

Interactive version of `top` with easier navigation and color-coded output.

```bash
htop
```

Displays RAM usage with human-readable units.

```bash
free -h
```

Shows disk usage by mounted partitions in human-readable format.

```bash
df -h
```

Shows size of each item in the current directory.

```bash
du -sh *
```

Displays how long the system has been up and the current load.

```bash
uptime
```

Prints kernel version and system info.

```bash
uname -a
```

Displays the current user name.

```bash
whoami
```

---

## 🔍 Networking &amp; Firewall

Displays network interfaces and IPs.

```bash
ip a
```

Shows the routing table.

```bash
ip r
```

Shows UFW rules with index numbers for deletion.

```bash
sudo ufw status numbered
```

Allows incoming SSH connections via UFW.

```bash
sudo ufw allow 22/tcp
```

Lists all listening ports (older tool).

```bash
sudo netstat -tuln
```

Modern alternative to netstat for listing open ports.

```bash
ss -tuln
```

Tests network connectivity with ICMP packets.

```bash
ping 1.1.1.1
```

---

## 📁 File &amp; Directory Management

Lists files including hidden files and sizes.

```bash
ls -lah
```

Changes the current directory.

```bash
cd /path/to/directory
```

Copies a file or folder.

```bash
cp source destination
```

Renames or moves a file or folder.

```bash
mv oldname newname
```

Removes a directory and all its contents (⚠️ dangerous).

```bash
rm -rf /path/to/folder
```

Edits files using a simple terminal-based editor.

```bash
nano filename.txt
```

Displays contents of a file.

```bash
cat filename.txt
```

Follows a log file in real time.

```bash
sudo tail -f /var/log/syslog
```

---

## ⚙️ Package Management (Debian/Ubuntu)

Updates package list and installs available upgrades.

```bash
sudo apt update && sudo apt upgrade -y
```

Installs a new package by name.

```bash
sudo apt install packagename
```

Searches installed packages for a string.

```bash
dpkg -l | grep keyword
```