Linux Commands Cheatsheet - Complete Command Reference Guide 2025

Master Linux with our comprehensive command reference. Search, learn, and use over 500+ Linux commands with examples and syntax guides.

File Operations

ls

List directory contents

ls [options] [directory]
cd

Change directory

cd [directory]
cp

Copy files and directories

cp [options] source destination
mv

Move/rename files and directories

mv [options] source destination
rm

Remove files or directories

rm [options] file(s)
mkdir

Make directories

mkdir [options] directory
chmod

Change file permissions

chmod [options] mode file(s)
chown

Change file owner and group

chown [options] owner[:group] file(s)
ln

Create links between files

ln [options] target link_name
find

Search for files in directory hierarchy

find [path] [expression]
touch

Create empty files or update timestamps

touch [options] file(s)
stat

Display file status information

stat [options] file(s)
mount

Mount filesystems

mount [options] [device] [directory]

Text Processing

cat

Concatenate and display files

cat [options] file(s)
grep

Search text using patterns

grep [options] pattern [file(s)]
sed

Stream editor for filtering and transforming text

sed [options] 'command' [file(s)]
awk

Pattern scanning and text processing

awk [options] 'program' [file(s)]
sort

Sort lines of text files

sort [options] [file(s)]
cut

Remove sections from lines of files

cut [options] [file]
tr

Translate or delete characters

tr [options] set1 set2
wc

Count lines, words, and bytes

wc [options] [file(s)]

Process Management

ps

Report process status

ps [options]
top

Display system processes

top [options]
kill

Terminate processes

kill [options] pid(s)
nice

Run program with modified scheduling priority

nice [option] command
nohup

Run command immune to hangups

nohup command [args]

Network Operations

ping

Send ICMP ECHO_REQUEST to network hosts

ping [options] destination
ssh

OpenSSH SSH client

ssh [options] [user@]hostname [command]
scp

Secure copy (remote file copy program)

scp [options] source destination
netstat

Network statistics

netstat [options]
curl

Transfer data from or to a server

curl [options] url
wget

Non-interactive network downloader

wget [options] url
dig

DNS lookup utility

dig [@server] [name] [type]
traceroute

Print network path to host

traceroute [options] host

System Administration

systemctl

Control the systemd system and service manager

systemctl [options] command [name]
journalctl

Query the systemd journal

journalctl [options]
useradd

Create a new user

useradd [options] username
crontab

Schedule periodic jobs

crontab [options] [file]
passwd

Change user password

passwd [options] [username]

Package Management

apt

Advanced Package Tool (Debian/Ubuntu)

apt [options] command
yum

Yellowdog Updater Modified (RHEL/CentOS)

yum [options] command
dpkg

Debian Package Management System

dpkg [options] action

Disk Operations

df

Report file system disk space usage

df [options]
du

Estimate file space usage

du [options] [file(s)]
fdisk

Manipulate disk partition table

fdisk [options] device
lsblk

List block devices

lsblk [options]
mkfs

Create filesystem

mkfs [options] device

Security & Permissions

sudo

Execute command as another user

sudo [options] command
openssl

OpenSSL command line tool

openssl command [options]
fail2ban

Ban hosts that cause multiple authentication errors

fail2ban-client [options] command
ufw

Uncomplicated Firewall

ufw [options] command
getenforce

SELinux enforcement status

getenforce

Container Operations

docker

Docker container operations

docker [options] command
podman

Pod Manager tool

podman [options] command

System Monitoring

htop

Interactive process viewer

htop [options]
iotop

Simple top-like I/O monitor

iotop [options]
vmstat

Report virtual memory statistics

vmstat [options] [delay [count]]
lsof

List open files

lsof [options]
free

Display memory usage

free [options]

Backup & Recovery

rsync

Fast, versatile file copying tool

rsync [options] source destination
tar

Tape archiving utility

tar [options] [archive] [file(s)]
dd

Convert and copy a file

dd [operands]

System Boot

grub2-mkconfig

Generate GRUB configuration

grub2-mkconfig [options]
systemd-analyze

Analyze system boot-up performance

systemd-analyze [options] command

Media Processing

ffmpeg

Multimedia framework for handling video/audio

ffmpeg [options] input output
imagemagick

Image manipulation tools

convert [options] input output

Version Control

git

Distributed version control system

git [options] command
svn

Subversion version control

svn [options] command

Performance Analysis

strace

Trace system calls and signals

strace [options] command
perf

Performance analysis tools

perf [options] command

Database Management

mysql

MySQL database client

mysql [options] [database]
postgresql

PostgreSQL database management

psql [options] [dbname]

Virtualization

virsh

Manage virtual machines

virsh [options] command domain
virt-install

Provision new virtual machines

virt-install [options]

Log Analysis

logrotate

Rotate and compress log files

logrotate [options] config
goaccess

Real-time web log analyzer

goaccess [options] log_file

Service Discovery

consul

Service networking platform

consul [command]
eureka

Service registry

eureka [options]

Networking Advanced

tcpdump

Network packet analyzer

tcpdump [options] [expression]
iptables

Administration tool for IPv4 packet filtering

iptables [options] command chain rule
ip

Network configuration tool

ip [options] object command
nftables

Modern packet filtering

nft [options]

Load Balancing

haproxy

High availability load balancer

haproxy [options]
nginx

HTTP and reverse proxy server

nginx [options]

Archive & Compression

zip

Package and compress files

zip [options] archive files
gzip

Compress or expand files

gzip [options] file(s)
7z

7-Zip file archiver

7z [options] command archive files

Hardware Information

lscpu

Display CPU information

lscpu [options]
lsusb

List USB devices

lsusb [options]
dmidecode

DMI table decoder

dmidecode [options]

Scheduling & Jobs

cron

Schedule periodic tasks

crontab [options]
at

Execute commands at specified time

at [options] time

Performance Tuning

sysctl

Configure kernel parameters

sysctl [options] [variable[=value]]
nice

Run with modified scheduling priority

nice [options] command

User Environment

env

Display environment variables

env [options] [name=value] [command]
locale

Get locale-specific information

locale [options]

Authentication & Access

pam

Pluggable Authentication Modules

pam [module] [type] [control] [arguments]
auth

Authentication key management

auth [options] command

SSL/TLS Management

certbot

Automated SSL/TLS certificate management

certbot [options] command
keytool

Key and certificate management tool

keytool [options]

File System Management

mkfs

Build a Linux filesystem

mkfs [options] device
tune2fs

Adjust tunable filesystem parameters

tune2fs [options] device
lvm

Logical Volume Management

lvm [command]

SELinux Management

semanage

SELinux policy management tool

semanage [options] command
sestatus

SELinux status tool

sestatus [options]

Network Diagnostics

mtr

Network diagnostic tool

mtr [options] host
dig

DNS lookup utility

dig [options] name type

Container Orchestration

kubectl

Kubernetes command-line tool

kubectl [command] [type] [name] [flags]
helm

Kubernetes package manager

helm [command] [chart]

System Audit

auditd

Linux Audit daemon

auditd [options]
acct

Process accounting

acct [options]

Cloud Tools

aws

AWS Command Line Interface

aws [options] command
gcloud

Google Cloud Platform CLI

gcloud [group] [command]
az

Azure Command Line Interface

az [group] [command]

Debugging Tools

gdb

GNU Debugger

gdb [options] [program]
valgrind

Memory debugging tool

valgrind [options] program

Service Management

supervisord

Process control system

supervisord [options]
pm2

Process Manager for Node.js

pm2 [options] command

Storage Management

ceph

Distributed storage system

ceph [options] command
gluster

Scale-out filesystem

gluster [command]

Certificate Management

openssl

OpenSSL certificate toolkit

openssl command [options]

DNS Management

nslookup

Query DNS servers

nslookup [options] name [server]
host

DNS lookup utility

host [options] name [server]

Mail & Messaging

postfix

Mail server configuration

postfix [options] command
mutt

Text-based mail client

mutt [options]

Time Management

timedatectl

Control system time and date

timedatectl [options] command
chronyd

NTP client/server

chronyd [options]

Code Analysis

splint

C program verifier

splint [options] files
clang-tidy

C/C++ linter

clang-tidy [options] files

Build Tools

make

Build automation tool

make [options] [target]
cmake

Cross-platform build system

cmake [options] source-dir

Security Scanning

nmap

Network security scanner

nmap [options] target
nikto

Web server scanner

nikto [options] -h target

Remote Management

ansible

IT automation system

ansible [options] pattern
salt

Configuration management

salt [options] target command

Memory Management

vmstat

Virtual memory statistics

vmstat [options] [delay [count]]
swapon

Swap space management

swapon [options] [device]

Kernel Management

modprobe

Add/remove kernel modules

modprobe [options] module
sysctl

Kernel parameter management

sysctl [options] [parameter]

High Availability

pacemaker

Cluster resource manager

pcs [options] command
corosync

Cluster engine

corosync [options]

Monitoring & Metrics

prometheus

Monitoring system

prometheus [flags]
collectd

System statistics collection

collectd [options]

Network Tunneling

wireguard

VPN tunnel configuration

wg [options] command
openvpn

VPN tunnel daemon

openvpn [options] [config]

Identity Management

freeipa

Identity management system

ipa [command]
sssd

System Security Services Daemon

sssd [options]

Load Testing

ab

Apache HTTP server benchmarking

ab [options] URL
siege

HTTP load testing

siege [options] [url]

Configuration Management

puppet

Infrastructure automation

puppet [options] action
chef

Configuration management

chef [options] command

Container Runtime

containerd

Container runtime

ctr [options] command
cri-o

Kubernetes container runtime

crictl [options] command

Database Optimization

mysqltuner

MySQL performance advisor

mysqltuner [options]
pgbench

PostgreSQL benchmark tool

pgbench [options] [dbname]

Message Queues

rabbitmqctl

RabbitMQ management tool

rabbitmqctl [options] command
kafka

Apache Kafka management

kafka-topics [options]

Search & Indexing

elasticsearch

Elasticsearch operations

curl [options] endpoint
solr

Apache Solr management

solr [command]

Machine Learning Tools

conda

Package management for ML

conda [options] command
jupyter

Interactive computing

jupyter [options] command

Network QoS

tc

Traffic control

tc [options] command
wondershaper

Traffic shaping tool

wondershaper [options] interface

Storage Replication

drbd

Distributed storage replication

drbdadm [options] command
rsnapshot

Filesystem snapshot utility

rsnapshot [options] command

API Management

kong

API Gateway management

kong [options] command
swagger

API documentation tool

swagger [command]

Backup Verification

bacula

Backup verification system

bconsole [options]
restic

Backup program verification

restic [options] command

System Recovery

systemrescue

System rescue toolkit

sysresccd [options]
fsck

Filesystem check

fsck [options] device

Compliance Tools

openscap

Security compliance checker

oscap [module] command
lynis

Security auditing tool

lynis [options] command

Network Automation

ansible

Network automation platform

ansible-network [options]
nornir

Network automation framework

nornir [options]

Storage Encryption

cryptsetup

Disk encryption tool

cryptsetup [options] command
veracrypt

Disk encryption utility

veracrypt [options]

Service Mesh

istio

Service mesh platform

istioctl [command]
linkerd

Ultralight service mesh

linkerd [command]

Log Management

logstash

Log processing pipeline

logstash [options]
fluentd

Data collector

fluentd [options]

Infrastructure Testing

terraform

Infrastructure testing

terraform [command]
inspec

Infrastructure spec testing

inspec [command]

Cloud Native Tools

helm

Kubernetes package manager

helm [command]
argocd

GitOps continuous delivery

argocd [command]

Access Control

keycloak

Identity and access management

kcadm.sh [command]
authelia

Authentication server

authelia [command]

Performance Profiling

perf

Performance analysis tool

perf [command]
flame

Flamegraph generator

flamegraph.pl [options]

Distributed Systems

zookeeper

Distributed coordination

zkCli.sh [options]
etcd

Key-value store

etcdctl [command]

Monitoring Tools

grafana

Metrics visualization

grafana-cli [command]
prometheus

Metrics collection

promtool [command]

GitOps Tools

flux

GitOps toolkit

flux [command]
jenkinsx

Cloud native CI/CD

jx [command]

Serverless Tools

serverless

Serverless framework

serverless [options]
openfaas

Functions as a service

faas-cli [command]

Network Security

snort

Network intrusion detection

snort [options]
suricata

Network security monitor

suricata [options]

Application Performance

arthas

Java diagnostics tool

arthas [command]
jmeter

Load testing tool

jmeter [options]

Container Security

trivy

Container vulnerability scanner

trivy [options] target
falco

Runtime security

falco [options]

Infrastructure Automation

terraform

Infrastructure as code

terraform [command]
pulumi

Modern infrastructure as code

pulumi [command]

Site Reliability

chaos-mesh

Chaos engineering platform

chaos-mesh [command]
litmus

Chaos engineering toolkit

litmusctl [command]

Data Pipeline Tools

airflow

Workflow orchestration

airflow [command]
nifi

Data flow automation

nifi [command]

Edge Computing

k3s

Lightweight Kubernetes

k3s [command]
edgex

Edge computing framework

edgex [command]

Observability Tools

jaeger

Distributed tracing

jaeger [command]
datadog

Monitoring and analytics

datadog-agent [command]

Pipeline Security

snyk

Security scanning

snyk [command]
anchore

Container security

anchore-cli [command]

Low-Level System Tools

strace

System call tracer

strace [options] command
ltrace

Library call tracer

ltrace [options] command
sysdig

System exploration and troubleshooting

sysdig [options]

High Availability Tools

heartbeat

Node availability monitoring

heartbeat [options]
keepalived

Load balancing and high-availability

keepalived [options]

Caching Systems

redis-cli

Redis command line interface

redis-cli [options] [command]
memcached

Memory caching system

memcached [options]

Event Streaming

kafka

Distributed streaming platform

kafka-topics.sh [options]
rabbitmq

Message broker

rabbitmqctl [command]

AI/ML Operations

kubeflow

Machine learning toolkit for Kubernetes

kfctl [command]
mlflow

Machine learning lifecycle platform

mlflow [command]

Database Replication

pgpool

PostgreSQL connection pooling/replication

pgpool [options]
galera

MySQL/MariaDB synchronous replication

galera_new_cluster

Network Optimization

netdata

Real-time performance monitoring

netdata [options]
bmon

Bandwidth monitor

bmon [options]

Cluster Management

rancher

Container management platform

rancher [command]
openshift

Enterprise Kubernetes platform

oc [command]

Security Hardening

apparmor

Application security system

apparmor_parser [options]
auditd

System audit daemon

auditctl [options]

Visualization Tools

kibana

Data visualization platform

kibana [options]
grafana

Metrics visualization

grafana-server [options]

Complete Linux Command Reference

A comprehensive guide to Linux commands with detailed explanations, syntax, and practical examples.

500+ Linux Commands

Complete collection of Linux commands from basic to advanced system administration, networking, and security operations.

Practical Examples

Real-world command examples for Ubuntu, CentOS, Fedora, and other major distributions. Learn through practical use cases.

Smart Search

Find commands by name, description, or functionality. Our intelligent search helps you find exactly what you need.

Verified Syntax

Each command comes with verified syntax, flags, and options. Tested across multiple Linux distributions.

Offline Access

Download the complete Linux command reference as PDF. Access commands anytime, even without internet.

CLI Essentials

Master essential command-line operations for system administration, file management, and process control.

Organized Categories

Commands grouped by functionality: System, Network, Security, File Operations, and more.

Beginner Friendly

Perfect for beginners learning Linux commands or experienced users needing quick reference.

Latest Commands

Updated for 2024 with modern Linux commands, systemd operations, and container management.

Quick Reference

Fast, reliable command reference for developers, system administrators, and Linux enthusiasts.

How to Use the Linux Command Cheatsheet

Step 1

Search through 500+ Linux commands instantly with our smart search feature

Step 2

Find detailed syntax, usage patterns, and real-world examples for each command

Step 3

Copy commands directly to your terminal with one click

Step 4

Download the complete reference guide as PDF for offline access

Frequently Asked Questions