From: Francis Dupont Date: Mon, 13 Jul 2020 13:44:04 +0000 (+0200) Subject: [#1311] Addressed comments X-Git-Tag: Kea-1.7.10~58 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d25876b77419ee08816d9fab823324f685772208;p=thirdparty%2Fkea.git [#1311] Addressed comments --- diff --git a/ChangeLog b/ChangeLog index 81b616f9ae..f2c47a959b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ -1770. [perf] fdupont +1772. [perf] fdupont Set kea-lfc process priority to lower than default. + This change should alleviate CPU utilization spikes caused + by LFC process observed on some systems. (Gitlab #1311) 1771. [func] fdupont diff --git a/src/bin/lfc/main.cc b/src/bin/lfc/main.cc index 2e67e9b3b7..a04dfe79e8 100644 --- a/src/bin/lfc/main.cc +++ b/src/bin/lfc/main.cc @@ -25,6 +25,10 @@ using namespace isc::lfc; /// errors, EXIT_FAILURE otherwise. int main(int argc, char* argv[]) { // Ask scheduling to not give too much resources to LFC. + // First parameter means to change only the process priority. + // Second parameter (0) means the calling process. + // Third parameter 4 is a bit below the default priority of 0 in + // a range of -20 (highest priority) and 19 or 20 (lowest priority). static_cast(setpriority(PRIO_PROCESS, 0, 4)); int ret = EXIT_SUCCESS;