Process refers to a program under a execution.
Process can be executed on foregroud and background.
Priority of a process executed in foreground is 20.
Priority of a process executed in background is 24.
The priority of process can be changed with the nice command.
The range of priority of a proces is +20 to -19.
Smaller the value favored high.
# vmstat 2 5 : Command executed with the priority value of 20.
# nice -n 5 vmstat 2 5 : Command executed with the priority value of 25+5 = 25 (less favored).
# nice -n -5 vmstat 2 5 : Command executed with the priority value of 20-5 = 15 (high favored).
The process could have priority which can be a fixed or non-fixed (dynamic).
Fixed priority could be assigned to a process using the varible,
retcode=setpri(Process ID, priority value).
# ps -lu <user> : Command shows the priority of all the process owned by the user.
Process can be executed on foregroud and background.
Priority of a process executed in foreground is 20.
Priority of a process executed in background is 24.
The priority of process can be changed with the nice command.
The range of priority of a proces is +20 to -19.
Smaller the value favored high.
# vmstat 2 5 : Command executed with the priority value of 20.
# nice -n 5 vmstat 2 5 : Command executed with the priority value of 25+5 = 25 (less favored).
# nice -n -5 vmstat 2 5 : Command executed with the priority value of 20-5 = 15 (high favored).
The process could have priority which can be a fixed or non-fixed (dynamic).
Fixed priority could be assigned to a process using the varible,
retcode=setpri(Process ID, priority value).
# ps -lu <user> : Command shows the priority of all the process owned by the user.