-
-
Notifications
You must be signed in to change notification settings - Fork 1
Linux nice Guide
Mattscreative edited this page Dec 5, 2025
·
2 revisions
Complete beginner-friendly guide to nice on Linux, covering Arch Linux, CachyOS, and other distributions including process priority, CPU scheduling, and performance tuning.
nice sets process priority.
Uses:
- Set priority: Change process priority
- CPU scheduling: Control CPU access
- Performance tuning: Tune process performance
- Resource management: Manage resources
Why it matters:
- Performance: Control process priority
- Resource management: Manage CPU usage
- System stability: Maintain system stability
Basic usage:
# Run with nice priority
nice command
# Default nice value: 10Specify value:
# Set nice value
nice -n 15 command
# -n = nice value (higher = lower priority)Value range:
# Nice range: -20 to 19
# -20 = highest priority
# 19 = lowest priority
# High priority
nice -n -10 command
# Low priority
nice -n 15 commandModify priority:
# Change existing process (use renice)
renice 10 -p 1234
# Changes process 1234 to nice 10Increase priority:
# High priority (requires root)
sudo nice -n -10 command
# Negative values need rootDecrease priority:
# Low priority
nice -n 19 command
# Lowest priorityUse sudo:
# Negative nice values need root
sudo nice -n -10 command
# Or use renice
sudo renice -10 -p PIDThis guide covered nice usage, process priority, and CPU scheduling for Arch Linux, CachyOS, and other distributions.
- renice Guide - Change priority
- Process Management - Process management
- Performance Tuning - Performance optimization
-
nice Documentation:
man nice
This guide covers Arch Linux, CachyOS, and other Linux distributions. For distribution-specific details, refer to your distribution's documentation.