HP-UX Reference (11i v2 04/09) - 2 System Calls (vol 5)
r
rtprio(2) rtprio(2)
indicated by pid .
[EPERM] The group access list of the calling process does not contain a group having
PRIV_RTPRIO capability and prio is not RTPRIO_NOCHG,
or
RTPRIO_RTOFF with a pid of zero.
[ESRCH] No process can be found corresponding to that specified by pid .
EXAMPLES
The following call to
rtprio() sets the calling process to a real-time priority of 90:
rtprio(0, 90);
WARNINGS
Normally, compute-bound programs should not be run at real-time priorities, because all timesharing
work on the CPU would come to a complete halt.
DEPENDENCIES
Series 800
Because processes executing at real-time priorities get scheduling preference over a system process exe-
cuting at a lower priority, unexpected system behavior can occur after a power failure on systems that
support power-fail recovery. For example, when
init (see init (1M)) receives the powerfail signal
SIGPWR, it normally reloads programmable hardware such as terminal multiplexers. If a higher-priority
real-time process is eligible to run after the power failure, the running of init is delayed. This condition
temporarily prevents terminal input to any process, including real-time shells of higher priority than the
eligible real-time process. To avoid this situation, a real-time process should catch SIGPWR and suspend
itself until init has finished its powerfail processing.
AUTHOR
rtprio() was developed by HP.
SEE ALSO
rtprio(1), getprivgrp(2), nice(2), plock(2).
Section 2−−294 Hewlett-Packard Company − 2 − HP-UX 11i Version 2: September 2004