Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

What is the relation of nice and priority in Linux?

Posted on 2011-09-23
1
Medium Priority
?
367 Views
Last Modified: 2012-05-12
Hello, I would to understand the relationship of nice and priority in Linux, as per my current knowledge the nice value range is 19 to -20, where -20 is the highest number to set for high priority CPU scheduling. Could someone please explain me how is the priority number is affected by the nice value? Thanks!
0
Comment
Question by:beer9
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 9

Accepted Solution

by:
_3mp3ror_ earned 2000 total points
ID: 36590800
The nice command allows programs to be started at a lower or higher than normal scheduling priority.
This allows you to control which processes the kernel should favor when dividing processor time among running programs.
Processes with the lowest nice number are executed with the highest priority and vice versa.

On most systems, priority levels for normal users range from 0 to 19, with 0 being the highest priority and 19 being the lowest priority. The root user can create processes with a range of -20 (highest) to 19 (lowest).
Most programs start with a nice level of 0 by default. Critical system services usually have a negative nice level so that they are always given preference over user programs.

This quote  is from a realy good book which is free btw. If you are new to linux commands I highly recommend it.
http://dontfearthecommandline.blogspot.com/
0

Featured Post

Fill in the form and get your FREE NFR key NOW!

Veeam® is happy to provide a FREE NFR server license to certified engineers, trainers, and bloggers.  It allows for the non‑production use of Veeam Agent for Microsoft Windows. This license is valid for five workstations and two servers.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Over the last ten+ years I have seen Linux configuration tools come and go. In the early days there was the tried-and-true, all-powerful linuxconf that many thought would remain the one and only Linux configuration tool until the end of times. Well,…
Fine Tune your automatic Updates for Ubuntu / Debian
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
Suggested Courses
Course of the Month11 days, 18 hours left to enroll

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question