Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [nice]

Use for questions concerning the Linux/Unix nice program, or the related renice or ionice programs, used for controlling process priority. For questions concerning the NICE Media Player, use the [nice-media-player] tag.

1
vote
0answers
23 views

Set niceness value in a systemd user service

I'd like to start xcape with a nice value of -20 as non-root. However setting a nice value of -20 requires root permissions. So I was wondering whether this is somehow possible. I also tried to create ...
0
votes
0answers
14 views

What is the difference between PR shown in top output vs PRI shown in ps output

I would assume both to be the same, but on my system these are different. Top displays PR=20,NI=0 while ps displays PRI=80,NI=0. Whats going on here?? Top: PID USER PR NI VIRT RES SHR ...
-1
votes
1answer
271 views

What is the purpose of 'nice' command without a niceness parameter?

I often see this code in anacrontab samples on the internet: # environment variables SHELL=/bin/sh PATH=/sbin:/bin:/usr/sbin:/usr/bin MAILTO=root RANDOM_DELAY=30 # Anacron jobs will start between 6am ...
0
votes
1answer
97 views

Unrecognized option when nice used through ssh

How to use nice on remote host via ssh? I want to decrease priority for long interactive process, executed on remote host: ssh server1 nice -n tar --update --preserve-permissions --file /opt/share/...
5
votes
2answers
1k views

limit priority/threads for Gradle/Android Studio builds?

When Android Studio builds my project, it easily eats up all my 8 cores. I'd like to be able to fluently browse the internet while my app is compiling. Is there a way I can set Gradle's java processes ...
3
votes
1answer
544 views

nice has no effect in Linux unless the same shell is used

If I enter in two different root terminals: nice -n 19 burnK7 & and nice -n -19 burnK7 & Then both processes receive about 50% of the available CPU time - not expected and certainly not ...
0
votes
1answer
129 views

rtorrent with Seeds and Downloads

I'm using rtorrent for a very long time. I'm fan. This is one of the greatest console torrent manager ever. However, I can't found cool way to keep seeding. My downloads separated into two ...
0
votes
1answer
99 views

can I `dtach` or `renice` graphical programs like `evince`?

I sometimes open PDF's and then want them "sort of" open "to read later", but I'm not looking at them at the moment. While I'm not looking at them I'd like the OS to spend less effort keeping them up. ...
0
votes
1answer
112 views

Extra low priority processes in linux?

On Linux processes have "nice" values ranging from -20 to 19. I wish I could assign even lower priority like 100 so that "background work" will yield as much as possible to other process but still ...
0
votes
0answers
58 views

Nicing processes and unresponsive computers

I've a of process running on a machine. The machines are 6-core hyperthreaded for an effective total of 12 cores and the process takes 400% of the cpu so 4 cores. I niced the process to +19 for a ...
1
vote
1answer
80 views

Too many processes have realtime or -20 niceness

For some reason a lot of my processes are real-time and and keep making my audio lag. Are these supposed to be real-time? I tried both a hard reboot and soft reboot, I even restarted pulse but to no ...
1
vote
1answer
1k views

'nice' does not work, even when using 'sudo'. “Permission Denied”

I am attempting to set the priority on an application to be higher, but I keep getting 'permission denied' when attempting to do som even as the superuser. From the Terminal: Alexandsteins-Macbook:~ ...
2
votes
1answer
1k views

Cron job not abiding by the nice command

I got a script that backs up minecraft worlds, when ran by command (nice -19 ./backup.sh) it doesn't lag what so ever, server load stays low. When I try to do nice -19 ./backup.sh in a cronjob, it ...
0
votes
0answers
81 views

Linux command line: run mon nice and C exectuable together

I'm trying to run ./a.out, but monitored (using mon) and nice'd to highest priority. Here are the commands separately: nice -n -20 /home/pi/a.out //works fine mon /home/pi/a.out //works fine ...
4
votes
1answer
8k views

Nice commands in a .sh script for cron jobs

I have this php script that I need to run on shared webhosting. I have created a cron job that executes an sh script. The command for the cron was: /bin/sh /home/user/script.sh So I'm assuming it is ...
0
votes
2answers
951 views

Why I can decrease the process's priority by using nice() function with a typical user permission(except ROOT) in linux?

As I understand every user in linux can change the every process's priority by using nice and renice commands. Also I know that the all users just can increase the priority of processes and the only ...
4
votes
2answers
5k views

Does the Linux 'nice' command work on any shell script?

Does nice work on any shell script, or does it work on basic Linux commands only? For example, if I have a custom shell script that contains a sort function, and I call nice myscript.sh would the ...
2
votes
2answers
440 views

Remember the nice value in Linux

On Linux, how to make the processes remember their nice between starts ? For XP+ you can use Prio to remember the priority and also the IO priority on VISTA+. However, on Linux, and only for running ...
3
votes
1answer
171 views

Tell 'nice' to stop +19 processes if load >= 1

I've noticed my computer gets sluggish when the load increases past 1 (ie, the first number after "load average:" from the "uptime" command). Heavy-duty processes (like rsync) often raise the load ...
4
votes
3answers
4k views

How do I elevate the priority of a process without giving that process superuser rights?

I have a high priority service that I start with sudo nice -n -10 process. This process does not need superuser rights though, except for the priority elevation. But nice requires superuser privileges ...
3
votes
4answers
2k views

ALWAYS run commands with low priority on unix?

I am not asking how to nice and renice a command on UNIX. What happens is that on a particular machine into which I frequently log I am only allowed to run long-running processes with low priority (...