π Categories and Commands#
π File Management#
-
Navigation and Basics:
ls- List directory contents.cd- Change directory.pwd- Display the current directory.
-
File Operations:
cp- Copy files or directories.mv- Move or rename files.rm- Delete files or directories.find- Search for files or directories.
-
Disk Usage:
df- Show disk space usage.du- Display directory or file sizes.
-
Archiving:
tar- Archive and compress files.zip/unzip- Compress and extract files in ZIP format.
π Networking#
-
Basic Commands:
ifconfig/ip- Display or manage network interfaces.ping- Check connectivity to a host.traceroute- Trace the path packets take to a host.
-
Data Transfers:
curl- Transfer data from/to a URL.wget- Download files from the web.
-
DNS Tools:
dig- Query DNS servers.nslookup- Query DNS records.
-
Connections:
netstat/ss- Show active network connections.lsof- List open files and their network connections.
π§ Process Management#
-
Monitoring:
ps- Display process information.top/htop- Real-time process monitoring.
-
Control:
kill- Terminate a process by PID.killall- Terminate processes by name.pkill- Kill processes by pattern.
-
Prioritization:
nice- Start a process with a specific priority.renice- Change priority of a running process.
-
Background Jobs:
jobs- List background jobs.fg- Bring a background job to the foreground.
π Performance Monitoring#
-
System Metrics:
vmstat- Display system performance statistics.uptime- Show system uptime.free- Display memory usage.
-
I/O Monitoring:
iotop- Monitor disk I/O.iostat- Show CPU and I/O statistics.
-
Advanced Tools:
sar- Collect and display system activity.dstat- Show detailed system resource usage.
π Log Management#
-
Viewing Logs:
cat/less/tail- View log files.journalctl- View systemd logs.
-
Searching and Filtering:
grep- Search text in files.awk- Advanced text processing.sed- Stream editing of text.
-
Log Rotation:
logrotate- Manage log rotation and compression.
π Disk and Filesystem#
-
Disk Information:
lsblk- List information about block devices.blkid- Display block device attributes.df- Show filesystem disk space usage.
-
Mounting:
mount- Mount a filesystem.umount- Unmount a filesystem.
-
Filesystem Checks:
fsck- Check and repair a filesystem.
-
Partitioning:
fdisk- Manage disk partitions.
π₯ User Management#
-
User Information:
whoami- Display the current user.id- Show user ID and group ID.groups- Display groups a user belongs to.
-
Account Management:
adduser- Add a new user.passwd- Change a userβs password.
-
Monitoring Users:
who- Show logged-in users.w- Display active users and their processes.
-
Privileges:
sudo- Run commands as another user.
π Security and Permissions#
-
File Permissions:
chmod- Change file permissions.chown- Change file owner or group.
-
Access Control:
umask- Set default permissions for new files.
π§° Miscellaneous#
-
Text Utilities:
echo- Print text to the console.wc- Count lines, words, and characters in a file.
-
System Information:
uname- Display system information.uptime- Show system uptime.
-
Scheduling:
cron- Schedule tasks.at- Schedule tasks to run once.
β€οΈ Contributors#
- Curated by Ankush Patil.