from small one page howto to huge articles all in one place

search text in:




Other .linuxhowtos.org sites: www.linuxhowtos.org
toolsntoys.linuxhowtos.org



Last additions:
How to make X listen on port 6000

How to make X listen on port 6000

words:

34

views:

82290

userrating:

average rating: 1.2 (52 votes) (1=very good 6=terrible)


May, 25th 2007:
April, 26th 2007:
Apr, 10th. 2007:
Druckversion . pdf icon
You are here: Tips&Tricks

nice and PORTAGE_NICENESS

Very simply put, the Linux kernel has a (process) scheduler that selects which process to run next in your system. One factor influencing the scheduler's decision about which process to assign CPU time to, is the priority of a process. Processes with a high priority will run before those with a lower priority, and processes with the same priority will take turns in running, one after the other and over again.

Better have a look at it for yourself: Run top from a terminal on your host and pay special attention to the PR and NI columns:

Sample top output

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND 
 8005 root      20   0 85188  33m  57m R  3.3  6.7   8:43.77 X 
 8148 tobias    20  10 25624 2376  24m S  0.3  0.5   0:00.60 xscreensaver 
    1 root      20   0  2476  552 2304 S  0.0  0.1   0:00.31 init 
    2 root      39  19     0    0    0 S  0.0  0.0   0:00.00 ksoftirqd/0 
    3 root      15  -5     0    0    0 S  0.0  0.0   0:00.09 events/0

The PR column indicates the priority level of a process, the value in the NI column displays the so-called nice value of process, which allows you to adjust the priority of a running process. Possible values range from -20 (very high priority), via 0 (standard priority) to 20 (very low priority). In our little example the xscreensaver process has a higher nice value than X, which indicates that X has a higher priority than xscreensaver.

Now, how do we make this work to our advantage when using Portage?

If you keep using your computer while compiling packages you will notice that your box is much less responsive as usal. This is caused by having two "groups" of processes with the same nice priority: your usual running tasks on one side, and emerge (and its child processes) on the other. Now, if you could renice emerge and its children to a higher nice (i.e. lower priority!) value (default is 0), compiling would inevitably take somewhat longer, but you could use your workstation without noticing much difference to its usual performance. That's what the PORTAGE_NICENESS parameter in /etc/make.conf is for:

Code Listing 1: Put this in /etc/make.conf

PORTAGE_NICENESS="15"

You can generally "renice" individual processes from the commandline, (e.g. renice 0 -p 8148 to prioritize xscreensaver in the above example), but this will not work with emerge, as Portage reads the PORTAGE_NICENESS setting from /etc/make.conf once and executes all child processes with the specified nice value.

From http://www.gentoo.org/news/en/gwn/20041101-newsletter.xml

back



Support us on Content Nation

New Packages

- as rdf newsfeed
- as rss newsfeed
- as Atom newsfeed
2025-12-04
djbdns - 1.05-r42
Ebuild name:

net-dns/djbdns-1.05-r42

Description

Collection of DNS client/server software

Added to portage

2025-12-04

poppler - 25.12.0
Ebuild name:

app-text/poppler-25.12.0

Description

PDF rendering library based on the xpdf-3.0 code base

Added to portage

2025-12-04

2025-12-03
ansible-compat - 25.12.0
Ebuild name:

dev-python/ansible-compat-25.12.0

Description

Contains functions that facilitate working with various versions

Added to portage

2025-12-03

aws-sam-translator - 1.105.0
Ebuild name:

dev-python/aws-sam-translator-1.105.0

Description

A library that transform SAM templates into AWS CloudFormatio

Added to portage

2025-12-03

awscli - 1.43.7
Ebuild name:

app-admin/awscli-1.43.7

Description

Universal Command Line Environment for AWS

Added to portage

2025-12-03

borgbackup - 1.4.3
Ebuild name:

app-backup/borgbackup-1.4.3

Description

Deduplicating backup program with compression and authenticated encrypt

Added to portage

2025-12-03

boto3 - 1.42.1
Ebuild name:

dev-python/boto3-1.42.1

Description

The AWS SDK for Python

Added to portage

2025-12-03

botocore - 1.42.1
Ebuild name:

dev-python/botocore-1.42.1

Description

Low-level, data-driven core of boto 3

Added to portage

2025-12-03

django - 4.2.27
Ebuild name:

dev-python/django-4.2.27

Description

High-level Python web framework

Added to portage

2025-12-03

django - 5.1.15
Ebuild name:

dev-python/django-5.1.15

Description

High-level Python web framework

Added to portage

2025-12-03

django - 5.2.9
Ebuild name:

dev-python/django-5.2.9

Description

High-level Python web framework

Added to portage

2025-12-03

gentoo-sources - 6.18.0
Ebuild name:

sys-kernel/gentoo-sources-6.18.0

Description

Full sources including the Gentoo patchset for the . kernel tree

Added to portage

2025-12-03

icaclient - 25.05.0.44-r1
Ebuild name:

net-misc/icaclient-25.05.0.44-r1

Description

ICA Client for Citrix Presentation servers

Added to portage

2025-12-03

indilib - 2.1.7
Ebuild name:

sci-libs/indilib-2.1.7

Description

INDI Astronomical Control Protocol library

Added to portage

2025-12-03

krita - 6.0.0_alpha_pre20251203
Ebuild name:

media-gfx/krita-6.0.0_alpha_pre20251203

Description

Free digital painting application. Digital Painting, Creati

Added to portage

2025-12-03

libnftnl - 1.3.1
Ebuild name:

net-libs/libnftnl-1.3.1

Description

Netlink API to the in-kernel nf_tables subsystem

Added to portage

2025-12-03

libsdl2 - 2.32.60
Ebuild name:

media-libs/libsdl2-2.32.60

Description

Simple Direct Media Layer

Added to portage

2025-12-03

libsdl3 - 3.2.28
Ebuild name:

media-libs/libsdl3-3.2.28

Description

Simple Direct Media Layer

Added to portage

2025-12-03

libwebsockets - 4.5.2
Ebuild name:

net-libs/libwebsockets-4.5.2

Description

A flexible pure-C library for implementing network protocols

Added to portage

2025-12-03

linux-docs - 6.18
Ebuild name:

sys-kernel/linux-docs-6.18

Description

Developer documentation generated from the Linux kernel

Added to portage

2025-12-03

linux-firmware - 20251125_p20251202
Ebuild name:

sys-kernel/linux-firmware-20251125_p20251202

Description

Linux firmware files

Added to portage

2025-12-03

numpydoc - 1.10.0
Ebuild name:

dev-python/numpydoc-1.10.0

Description

Sphinx extension to support docstrings in Numpy format

Added to portage

2025-12-03

nwjs - 0.100.1
Ebuild name:

dev-libs/nwjs-0.100.1

Description

Framework that lets you call all Node.js modules directly from the DOM

Added to portage

2025-12-03

nwjs - 0.104.1-r1
Ebuild name:

dev-libs/nwjs-0.104.1-r1

Description

Framework that lets you call all Node.js modules directly from the DOM

Added to portage

2025-12-03

nwjs - 0.106.0
Ebuild name:

dev-libs/nwjs-0.106.0

Description

Framework that lets you call all Node.js modules directly from the DOM

Added to portage

2025-12-03

nwjs - 0.86.0
Ebuild name:

dev-libs/nwjs-0.86.0

Description

Framework that lets you call all Node.js modules directly from the DOM

Added to portage

2025-12-03

openhab-bin - 5.0.2-r1
Ebuild name:

app-misc/openhab-bin-5.0.2-r1

Description

An open-source automation software for your home

Added to portage

2025-12-03

openhab-bin - 5.0.3-r1
Ebuild name:

app-misc/openhab-bin-5.0.3-r1

Description

An open-source automation software for your home

Added to portage

2025-12-03

pecl-mongodb - 1.16.2-r1
Ebuild name:

dev-php/pecl-mongodb-1.16.2-r1

Description

MongoDB database driver for PHP

Added to portage

2025-12-03

php-mode - 9999
Ebuild name:

app-emacs/php-mode-9999

Description

GNU Emacs major mode for editing PHP code

Added to portage

2025-12-03

pinentry - 0.1_p20250408
Ebuild name:

app-emacs/pinentry-0.1_p20250408

Description

GnuPG Pinentry server implementation for Emacs

Added to portage

2025-12-03

pkg-info - 0.6
Ebuild name:

app-emacs/pkg-info-0.6

Description

Provide information about Emacs packages

Added to portage

2025-12-03

planner - 3.42-r1
Ebuild name:

app-emacs/planner-3.42-r1

Description

Maintain a local Wiki using Emacs-friendly markup

Added to portage

2025-12-03

popcorntime-bin - 0.5.1-r2
Ebuild name:

media-video/popcorntime-bin-0.5.1-r2

Description

BitTorrent client that includes an integrated media player

Added to portage

2025-12-03

psycopg - 3.3.1
Ebuild name:

dev-python/psycopg-3.3.1

Description

PostgreSQL database adapter for Python

Added to portage

2025-12-03

pydyf - 0.12.1
Ebuild name:

dev-python/pydyf-0.12.1

Description

A low-level PDF generator

Added to portage

2025-12-03

pymongo - 4.15.5
Ebuild name:

dev-python/pymongo-4.15.5

Description

Python driver for MongoDB

Added to portage

2025-12-03

pyside - 6.10.1-r1
Ebuild name:

dev-python/pyside-6.10.1-r1

Description

Python bindings for the Qt framework

Added to portage

2025-12-03

pytest-httpx - 0.36.0
Ebuild name:

dev-python/pytest-httpx-0.36.0

Description

Send responses to HTTPX using pytest

Added to portage

2025-12-03

python - 0.3.13.10
Ebuild name:

dev-lang/python-0.3.13.10

Description

Freethreading (no-GIL) version of Python programming language

Added to portage

2025-12-03

python - 0.3.14.1
Ebuild name:

dev-lang/python-0.3.14.1

Description

Freethreading (no-GIL) version of Python programming language

Added to portage

2025-12-03

python - 3.13.10
Ebuild name:

dev-lang/python-3.13.10

Description

An interpreted, interactive, object-oriented programming language

Added to portage

2025-12-03

python - 3.14.1
Ebuild name:

dev-lang/python-3.14.1

Description

An interpreted, interactive, object-oriented programming language

Added to portage

2025-12-03

python-tests - 0.3.13.10
Ebuild name:

dev-python/python-tests-0.3.13.10

Description

Test modules from dev-lang/python

Added to portage

2025-12-03

python-tests - 0.3.14.1
Ebuild name:

dev-python/python-tests-0.3.14.1

Description

Test modules from dev-lang/python

Added to portage

2025-12-03

python-tests - 3.13.10
Ebuild name:

dev-python/python-tests-3.13.10

Description

Test modules from dev-lang/python

Added to portage

2025-12-03

python-tests - 3.14.1
Ebuild name:

dev-python/python-tests-3.14.1

Description

Test modules from dev-lang/python

Added to portage

2025-12-03

pyzotero - 1.7.6
Ebuild name:

dev-python/pyzotero-1.7.6

Description

A Python client for the Zotero API

Added to portage

2025-12-03

roundcube - 1.7_beta2
Ebuild name:

mail-client/roundcube-1.7_beta2

Description

A browser-based multilingual IMAP client with an application-like u

Added to portage

2025-12-03

ruff - 0.14.7
Ebuild name:

dev-util/ruff-0.14.7

Description

An extremely fast Python linter, written in Rust

Added to portage

2025-12-03

sabctools - 9.0.0
Ebuild name:

dev-python/sabctools-9.0.0

Description

Module providing raw yEnc encoding/decoding for SABnzbd

Added to portage

2025-12-03

safetensors - 0.7.0
Ebuild name:

sci-ml/safetensors-0.7.0

Description

Simple, safe way to store and distribute tensors

Added to portage

2025-12-03

sphinx-gallery - 0.20.0
Ebuild name:

dev-python/sphinx-gallery-0.20.0

Description

Sphinx extension to automatically generate an examples gallery

Added to portage

2025-12-03

sqlglot - 28.1.0
Ebuild name:

dev-python/sqlglot-28.1.0

Description

An easily customizable SQL parser and transpiler

Added to portage

2025-12-03

sybil - 9.3.0
Ebuild name:

dev-python/sybil-9.3.0

Description

Automated testing for the examples in your documentation

Added to portage

2025-12-03

syncthing - 2.0.12
Ebuild name:

net-p2p/syncthing-2.0.12

Description

Open Source Continuous File Synchronization

Added to portage

2025-12-03

tmuxp - 1.59.0
Ebuild name:

app-misc/tmuxp-1.59.0

Description

tmux session manager. built on libtmux

Added to portage

2025-12-03

urwid - 3.0.4
Ebuild name:

dev-python/urwid-3.0.4

Description

Curses-based user interface library for Python

Added to portage

2025-12-03

uv - 0.9.15
Ebuild name:

dev-python/uv-0.9.15

Description

A Python package installer and resolver, written in Rust

Added to portage

2025-12-03

uv-build - 0.9.15
Ebuild name:

dev-python/uv-build-0.9.15

Description

PEP517 uv build backend

Added to portage

2025-12-03

weasyprint - 67.0
Ebuild name:

dev-python/weasyprint-67.0

Description

Visual rendering engine for HTML and CSS that can export to PDF

Added to portage

2025-12-03

wordpress - 6.9
Ebuild name:

www-apps/wordpress-6.9

Description

Wordpress PHP and MySQL based content management system (CMS)

Added to portage

2025-12-03

xkbcomp - 1.5.0
Ebuild name:

x11-apps/xkbcomp-1.5.0

Description

XKB keyboard description compiler

Added to portage

2025-12-03

zlib-ng - 2.3.2
Ebuild name:

sys-libs/zlib-ng-2.3.2

Description

Fork of the zlib data compression library

Added to portage

2025-12-03

rdf newsfeed | rss newsfeed | Atom newsfeed
Copyright 2004-2025 Sascha Nitsch Unternehmensberatung GmbH
- Copyright and legal notices -
Time to create this page: 86.2 ms