Managing Running Processes
- Run a vi session with nice value 10
# vim test&
[1] 14771
# renice +10 14771
14771 (进程 ID) 旧优先级为 0,新优先级为 10
- Open another session and list all the process given by your user by top command and sort them by nice value, find your vi process and process ID
Open a new session first
#top -o NI
14771 root 30 10 149176 4700 2472 T 0.0 0.2 0:00.03 vim
- List all the processes with ps command, display your desired output fields and sort them by nice value, find your vi process and process ID
#ps aux --sort -ni
#ps aux --sort -ni|grep vim