From 210f5429678dba06f361b1f37bcb946f27e2e20b Mon Sep 17 00:00:00 2001 From: Arturo Borrero Gonzalez Date: Mon, 12 Jun 2017 10:34:35 +0200 Subject: conntrackd: make the daemon run in RT mode by default In order to prevent netlink buffer overrun, conntrackd is recommended to run at max priority. Make conntrackd to use a RT (SHED_RR) scheduler by default at max priority. This is common among other HA daemons. For example corosync uses SCHED_RR by default. The scheduler configuration option is kept in order to allow admins to perform fine-tuning, but it is deleted from example configuration files. Note that this default sched priority is so high that it makes the nice value useless, so deprecate the nice configuration. Anyway the nice value can be set externally at runtime using nice/renice. The code is moved to the init() routine. In case of error setting the scheduler, the system default will be used. Report a message to the user and continue working. Signed-off-by: Arturo Borrero Gonzalez Signed-off-by: Pablo Neira Ayuso --- doc/helper/conntrackd.conf | 21 --------------------- 1 file changed, 21 deletions(-) (limited to 'doc/helper/conntrackd.conf') diff --git a/doc/helper/conntrackd.conf b/doc/helper/conntrackd.conf index 1746bfd..4148544 100644 --- a/doc/helper/conntrackd.conf +++ b/doc/helper/conntrackd.conf @@ -102,27 +102,6 @@ Helper { # General settings # General { - # - # Set the nice value of the daemon, this value goes from -20 - # (most favorable scheduling) to 19 (least favorable). Using a - # very low value reduces the chances to lose state-change events. - # Default is 0 but this example file sets it to most favourable - # scheduling as this is generally a good idea. See man nice(1) for - # more information. - # - Nice -20 - - # - # Select a different scheduler for the daemon, you can select between - # RR and FIFO and the process priority (minimum is 0, maximum is 99). - # See man sched_setscheduler(2) for more information. Using a RT - # scheduler reduces the chances to overrun the Netlink buffer. - # - # Scheduler { - # Type FIFO - # Priority 99 - # } - # # Logfile: on (/var/log/conntrackd.log), off, or a filename # Default: off -- cgit v1.2.3