Advanced Commands Print

  • 0

Ubuntu Tools – Advanced Commands

This article contains advanced Ubuntu commands for system administrators to monitor, troubleshoot, and manage servers more effectively.


1) List Open Ports

# Show all listening ports with process details
ss -tulnp

# Alternative (if installed)
netstat -tulnp

2) Monitor Network Usage

# Install iftop
sudo apt install iftop -y

# Run to monitor real-time network traffic
sudo iftop -i eth0

3) Check Active Connections

ss -s
ss -tuna

4) System Logs

# Show system log
journalctl -xe

# Show SSH login attempts
journalctl -u ssh

5) Track Process Resource Usage

# Show most CPU-intensive processes
ps -eo pid,ppid,cmd,%mem,%cpu --sort=-%cpu | head

# Interactive process monitor
htop

6) Disk I/O and Performance

# Install iotop
sudo apt install iotop -y

# Show real-time disk I/O
sudo iotop

7) Network Troubleshooting

# Ping a host
ping -c 4 google.com

# Traceroute (install if missing)
sudo apt install traceroute -y
traceroute 8.8.8.8

# MTR (continuous traceroute with packet loss info)
sudo apt install mtr -y
mtr -n 8.8.8.8

8) System Uptime and Load

uptime
w

9) Kernel and OS Information

uname -r   # Kernel version
lsb_release -a   # Ubuntu release info

⚠️ Note: Advanced commands should be used with caution on production servers. Some tools may require installation and elevated privileges (sudo).


Was this answer helpful?

« Back