SurlyJake Blog

Updating FreeBSD Ports Nicely Using Nice

| Comments

Thanks to: http://scottspare.com/bsdfun/?p=75 for pointing me in the right direction. Compiling port updates can take a while and slow down your server. What you can do is use the ‘nice’ utility to force the processes to a lower priority. This will help your server to run almost normally during an update.

When you use the ‘nice’ command inside of csh or tcsh, you need to mind that you give the full path to the binary so you dont use the built-in ‘nice’ command.

# /usr/bin/nice -n 10 {your update command}

What i use is:

# /usr/bin/nice -n 10 portupgrade -aRrP

Man page for ‘nice’: http://www.freebsd.org/cgi/man.cgi?query=nice&apropos=0&sektion=0&manpath=FreeBSD+8.0-RELEASE&format=html

Comments