Show Menu
Cheatography

Managing Processes and Jobs in Linux Cheat Sheet by

Commands for managing processes and jobs in Linux

Process Verifi­cation

Command
Purpose
ps
Display running processes
ps aux
List all running proccesses
ps -ef
Full process listing
top
Real-time process monitor
htop
Intera­ctive process monitor (if installed)
pgrep
Find processes by name
pidof
Display PID of a process
pstree
Display processes in a tree

Process ID (PID)

Command
Purpose
echo $$
Current shell PID
echo $PPID
Parent process ID
ps
View PID
pgrep
Find PID by process name
pidof
Find PID of running program
 

Priority

Command
Purpose
nice
Start process with priority
renice
Change priority
ps -l
View nice value

Process Limits

Command
Purpose
ulimit
View/set shell resource limits
prlimit
View/c­hange process limits
limits.conf
Configure permanent limits

Process States

States
R (Running)
S (Sleeping)
D (Unint­err­uptible sleep)
T (Stopped)
Z (Zombie)
 

Jobs & Process Management

Command
Purpose
jobs
List background jobs
bg
Resume in background
fg
Bring to foreground
kill
Send signal
killall
Kill by process name
pkill
Kill by pattern
nohup
Continue after logout
&
Run in background
Ctrl+C
Interrupt process
Ctrl+Z
Suspend process

Scheduling

Command
Purpose
crontab
Manage recurring jobs
cron
Background scheduler
at
Schedule one-time jobs
atq
List pending at jobs
atrm
Remove at jobs
systemctl
Manage cron/at services
       
 

Comments

No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets

          Linux Command Line Cheat Sheet
          mod_rewrite Cheat Sheet
          cron Cheat Sheet

          More Cheat Sheets by hlhlhl

          Linux File and Directory Commands Cheat Sheet
          Configuring and Managing Software in Linux Cheat Sheet