RENICE command not working with '-u'

Kernels & Hardware, configuring network, installing services

RENICE command not working with '-u'

Postby Daffy_Duck » 2019-11-14 10:25

Hi, :)
I'm trying to use the command 'RENICE' for the first time and i run into a problem.
My CPU usage is between 2-9%. And if i run './xmr-stak' it will take all the free CPU power, so i have to lower the priority like i did it on Windows.
But if i use "RENICE -n 15 -u xmr-stak" then 'xmr-stak' will use 0% CPU. It only works if i use "RENICE -n 15 -p <ProcessID>".
How can i do so that 'xmr-stak' will always start with priority 15. :?:
Daffy_Duck
 
Posts: 3
Joined: 2019-11-14 10:10

Re: RENICE command not working with '-u'

Postby wizard10000 » 2019-11-14 10:50

renice can only change a running process. If you want to *start* the process with a higher priority use nice instead. nice's man page explains pretty clearly.

Hope this helps -
we see things not as they are, but as we are.
-- anais nin
User avatar
wizard10000
 
Posts: 104
Joined: 2019-04-16 23:15
Location: southeastern us

Re: RENICE command not working with '-u'

Postby Daffy_Duck » 2019-11-14 12:31

I get the same problem with "NICE -n 19 ./xmr-stak" vs "NICE -n 15 -p <ProcessID>". For some strange reason NICE/RENICE only works with the 'ProcessID' and not with the 'ProcessName' or 'UserName'.
Daffy_Duck
 
Posts: 3
Joined: 2019-11-14 10:10

Re: RENICE command not working with '-u'

Postby wizard10000 » 2019-11-14 13:40

The little bit of research I've done suggests this is a shell script. If you renice a shell script the only thing that gets reniced is bash. You'll probably have to edit the script and use nice to launch commands there.

Hope this helps -
we see things not as they are, but as we are.
-- anais nin
User avatar
wizard10000
 
Posts: 104
Joined: 2019-04-16 23:15
Location: southeastern us

Re: RENICE command not working with '-u'

Postby Daffy_Duck » 2019-11-14 14:38

I cannot edit this 'xmr-stak' file, it's a a bin file.
Daffy_Duck
 
Posts: 3
Joined: 2019-11-14 10:10

Re: RENICE command not working with '-u'

Postby wizard10000 » 2019-11-14 15:11

I guess maybe someone needs to update nice's man page then. Sorry I wasn't helpful :(
we see things not as they are, but as we are.
-- anais nin
User avatar
wizard10000
 
Posts: 104
Joined: 2019-04-16 23:15
Location: southeastern us


Return to System configuration

Who is online

Users browsing this forum: No registered users and 12 guests

fashionable