Skip site navigation (1)Skip section navigation (2)

  
 
  

home | help
schedutils(8)		     System Manager's Manual		   schedutils(8)

NAME
     sched,resched,getsched - change a process' scheduler/priority

SYNOPSIS
     sched [-h] [-v] -r|-o|-f priority program [args, ..]

     resched [-h] [-v] -r|-o|-f pid [priority]

     getsched [-h] pid [pid, ...]

DESCRIPTION
     schedutils  are some utilities used to manipulate the scheduling and prior-
     ity of processes on *nix  systems. This  is  realized  with  the  functions
     found  in	sched.h, see the manpage for sched_setscheduler(2) for more info
     about what's going on.

     sched runs a new  program	under  the  specified  scheduler  and  priority,
     resched  is used to change the scheduler and/or priority of already running
     processes identified with their pid.  getsched is	a  little  utility  that
     prints  the  scheduler  and  priority  of running processes identified with
     their pid, it does not alter anything. Usually only the superuser(root) are
     allowed to change scheduling parameters.

OPTIONS
     -h print help

     -v be verbose, prints out the  scheduler/priority	before	and  after  it's
     changed.

     -r Round Robin scheduler

     -f FIFO scheduler

     -o  Other	scheduler, this is the 'default' scheduler that normal processes
     start under.

SCHEDULING
     The scheduler is the part of the kernel that  decides  which  process  that
     will  get	the  CPU next. Posix defines three diffrent policies that can be
     used to decide this.  See sched_setscheduler for  an  in-depth  explanation
     for the platform you use.

     Other  the  default  timesharing  scheduler  used	by normal processes. The
     'Other' scheduler uses the lowest priority  0  ,  and   it  cannot  be  set
     higher.

     FIFO  First  In First Out must have a priority in the range 1-99 and uses a
     simple fifo queue to hold the processes A process	that  is  executed  will
     continue  to  execute  until it's either preempted by a process with higher
     priority, gives up the CPU (e.g. by calling sched_yield) or performs a call
     that blocks. Then then next process in the queue can run.

     Round Robin must have a priority in the range 1-99 and are very similar  to
     FIFO, except it uses timesharing between the processes in the queue, a run-
     ning  process  will  therefore  give up the CPU to another process with the
     same priority when it has used its time quantum.

NOTES
     When a process is run under another scheduler than the default  (Other)  it
     can never be preempted by a process with a lower priority. So, if a process
     run  under another scheduler uses the CPU heavily, or worse have e.g. a bug
     that causes it to go in an infinite loop, no other process might  ever  run
     and the machine might look completely locked, unless there is an open shell
     running somewhere with a even higher priority, one can execute commands and
     possibly kill the process.

BUGS
     None     known,	 report     any     you     find    to	  http://source-
     forge.net/tracker/?atid=399898&group_id=30636&func=browse

AUTHOR
     Nils O. Selasdal <NOS@Utel.no>

SEE ALSO
     nice(1),renice(8),sched_setscheduler(2),sched_getscheduler(2)

				  July 30, 2001 		   schedutils(8)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=resched&sektion=8&manpath=FreeBSD+Ports+15.1.quarterly>

home | help