Troubleshoot - by Hostrare
Linux helpful management is Run Process With Qualified Scheduling Priority ( nicenesses ). With the advice of the Nice facility in Linux, you can set method preference. If you give a method a higher superiority, then Kernel will allocate more CPU time to that method.
By error when a program is started in Linux, it gets started with the superiority of ‘0’. However, you can modify the priority of your programs in each of the following ways.
You can start a program with your expected priority. Or you can also change the advantage of an already running method.
Process security interests classify from -20 to 19. A method with a nice profit of -20 is supposed to be on top of the superiority. And a method with a nice value of 19 is recognized to be low on the priority list.
You can use ps -al, top, and various commands to check superiority. The line that starts with “NI” gives the nice profit(priority of the method). You can see that most of them have got a ‘0’ superiority.
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 31102 nobody 16 0 269m 22m 10m R 2.0 0.6 0:04.44 /usr/local/apache/bin/httpd -k start -DSSL 27956 root 15 0 12884 1268 832 R 1.0 0.0 2:53.60 top -c 22384 mysql 5 -10 2830m 204m 3864 S 0.7 5.2 372:40.00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --log-error=/var/lib/mysql/serv.med1med 1 root 15 0 10368 584 552 S 0.0 0.0 0:03.09 init  2 root RT -5 0 0 0 S 0.0 0.0 0:06.15 [migration/0] 3 root 34 19 0 0 0 S 0.0 0.0 0:00.28 [ksoftirqd/0] 4 root RT -5 0 0 0 S 0.0 0.0 0:00.00 [watchdog/0]
To change the priority of an already running process, you can use the “renice” command.
Think you see that your device is running delayed due to some lengthy method(which is not a needed process at the time), then you can decrease the superiority of that method with the help of renice command. And also grow the superiority of your necessary process at the time.
renice command is very much related to the nice power( in terms of choices in priority), however, it does vary slightly in terms of parameters. You can give a username, group name, etc in renice command as a parameter.
renice 15 -p 20380 (this will set the priority of process id no 20380 to 15)
renice -17 -p 24132 -u mysql (this will set the priority of the process id 24132 to -17)
renice 11 -u cpanel,nobody -g testuser (this will set all process owned by “cpanel”,”nobody” and also the group “testuser” to 11)
Whether you are looking for a personal website hosting plan or a business website hosting plan, We are the perfect solution for you. Our powerful website hosting services will not only help you achieve your overall website goals, but will also provide you with the confidence you need in knowing that you are partnered with a reliable and secure website hosting platform.
Any hosting service you require, you can avail 50% Discount with new verified account. Chat with your Team Now