Port-amd64 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: nice question (pun optional)



Thanks for responding, but you haven't really tackled my question.
With both PRI and NICE lower numbers mean more priority.  In the case
of NICE, the superuser can set NICE to be negative, giving the process
concerned more priority.  But the PRI number goes up, i.e. *less*
priority.  That's what I don't understand.

I want to allow certain processes to be priority-greedy, to have a
priority claim on memory space and CPU cycles, and I suppose adjusting
the value of NICE to be the simplest way of achiving this.   Am I
wrong.

BTW, on my mail servr I observe (in top(1)) PID 0 [system] with NICE at
0 but PRI varying between 0 and 124.  anvil (part of postfix/dovecot providing
IMAP service) has NICE at 0 and PRI at 26.


--
Steve Blinkhorn <steve%prd.co.uk@localhost>

You wrote:
> 
> On Thu, Jun 9, 2022 at 5:04 AM Steve Blinkhorn <steve%prd.co.uk@localhost> wrote:
> >
> > I have a process that I want to run at the highest possible priority.
> > Tt curr4ently runs with NICE set at 0 and PRI showing at 43.  Most
> > other swtuff shows up with a PRI at 85.  As I understand things, the
> > highest priority is 0.
> >
> > So I use renice(1) to set NICE to -20, which is the highest priority,
> > but the value of PRI goes from 43 to 63, i.e. a lower priority.
> >
> > This happens regardless of which shell I use, BTW.
> >
> > What's going on, or what am I misunderstanding?
> 
> - is incrementing lower, + increments higher (higher priority). 0 is
> highest. Any process with a nice number larger than 0 is a lower
> priority. According to top, almost every process on my system is at
> nice 0.
> 
> Andy
> 




Home | Main Index | Thread Index | Old Index