Why Linux Skills Are Non-Negotiable in DevOps
Every major cloud provider runs Linux underneath. Every container starts from a Linux base image. Every automation script eventually runs on a Linux box. You don't need to memorize everything — but you need to be comfortable enough to find your way around any system under pressure.
Here are the commands I reach for every single day.
File System Navigation
# Where am I?
pwd
# List files with details, including hidden files
ls -la
# Navigate
cd /var/log
cd ~ # go home
cd - # go back to previous directory
# Find files
find /etc -name "*.conf" -type f
find / -name "nginx.conf" 2>/dev/null
# Search file contents
grep -r "ERROR" /var/log/app/
grep -n "ConnectionRefused" app.log # show line numbers
Process Management
# See what's running
ps aux | grep nginx
top # live process view
htop # better live view (install separately)
# Kill a process
kill -9 1234
pkill nginx
# Background jobs
./long-running-script.sh &
jobs # list background jobs
fg %1 # bring job 1 to foreground
# Check what's listening on a port
ss -tlnp | grep :80
lsof -i :8080
Disk and Memory
# Disk usage
df -h # disk space by filesystem
du -sh /var/log/* # size of each item in /var/log
du -sh * | sort -rh # sorted by size, largest first
# Memory
free -h
cat /proc/meminfo | head -5
Networking
# Test connectivity
ping -c 4 google.com
curl -I https://devopspack.com # check HTTP headers
wget -q -O /dev/null https://example.com # download test
# DNS lookup
dig devopspack.com
nslookup devopspack.com
# Network interfaces
ip addr show
ip route show
# Firewall (Ubuntu/Debian)
ufw status
ufw allow 443/tcp
Log Analysis
# Follow a log in real time
tail -f /var/log/nginx/access.log
# Last 100 lines
tail -n 100 /var/log/syslog
# Search and count errors in the last hour
journalctl --since "1 hour ago" | grep -c ERROR
# Count occurrences
cat access.log | awk '{print $1}' | sort | uniq -c | sort -rn | head -10
System Administration
# Services (systemd)
systemctl status nginx
systemctl restart nginx
systemctl enable nginx # start on boot
journalctl -u nginx -f # follow nginx logs
# User management
useradd -m -s /bin/bash deployuser
passwd deployuser
usermod -aG sudo deployuser
# Permissions
chmod 755 script.sh
chmod 600 ~/.ssh/id_rsa # private key must be 600
chown -R www-data:www-data /var/www/html
Useful One-Liners
# Check SSL certificate expiry
echo | openssl s_client -connect devopspack.com:443 2>/dev/null | openssl x509 -noout -dates
# Monitor file changes in real time
watch -n 2 "df -h"
# Find largest files
find / -type f -printf '%s %p\n' 2>/dev/null | sort -rn | head -10
# Extract a tar archive
tar -xzf archive.tar.gz -C /destination/
# Create a tar archive
tar -czf backup-$(date +%Y%m%d).tar.gz /path/to/backup/
These commands are your daily toolkit. The more you use them, the more they become second nature — and the faster you'll be able to diagnose and fix issues when things go wrong at 2am.

Member discussion