Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

If I do the following command on my standard Linux Mint installation:

comp ~ $ ps -eo rtprio,nice,cmd
RTPRIO  NI CMD
...
99   - [migration/0]
99   - [watchdog/0]
99   - [migration/1]
 -   0 [ksoftirqd/1]
99   - [watchdog/1]

I get some of the processes with realtime priority of 99.

What is the meaning of rtprio in a non real time Linux? Does this mean that if I just run a program with rtprio 99 it runs real time? Where do real time OSes fall in this story?

share|improve this question
add comment

1 Answer

up vote 4 down vote accepted

"Real time" means processes that must be finished by their deadlines, or Bad Things (TM) happen. A real-time kernel is one in which the latencies by the kernel are strictly bounded (subject to possiby misbehaving hardware which just doesn't answer on time), and in which most any activity can be interrupted to let higher-priority tasks run. In the case of Linux, the vanilla kernel isn't set up for real-time (it has a cost in performance, and the realtime patches floating around depend on some hacks that the core developers consider gross). Besides, running a real-time kernel on a machine that just can't keep up (most personal machines) makes no sense.

That said, the vanilla kernel handles real time priorities, which gives them higher priority than normal tasks, and those tasks will generally run until they voluntarily yield the CPU. This gives better response to those tasks, but means that other tasks get hold off.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.