tuned icon indicating copy to clipboard operation
tuned copied to clipboard

plugin_sysctl.py: sysctl configs apply order

Open alexeyantropov opened this issue 3 years ago • 4 comments

This block https://github.com/redhat-performance/tuned/blob/master/tuned/plugins/plugin_sysctl.py#L119-L123 applies configuration files in an unexpected order. At the first it applies override values from the sysctl.d drop-in directory, and at the last it applies values from main sysctl.conf config.

I reckon it's wrong. In the general case sysctl.conf has only default values and files from sysctl.d/*.conf have some custom values. However tuned (re)start breaks this drop-in approach and custom values are rewritten by the default values from the main config.

For example, it could be net.ipv4.ip_forward=1 in /etc/sysctl.d/foo.conf and net.ipv4.ip_forward=0 in /etc/sysctl.conf for virtualization systems like lxc, docker, kvm. After tuned (re)start virtual machines will be lost.

alexeyantropov avatar Feb 04 '22 09:02 alexeyantropov

Ping?

alexeyantropov avatar Sep 12 '22 18:09 alexeyantropov

Hello there! How about this issue? Is anybody alive here?

alexeyantropov avatar Aug 29 '23 15:08 alexeyantropov

Although I think it's systemd fault and other tools, especially sysctl, which we took as the standard for the implementation, do it the same way, we will probably add some workaround for it.

There is downstream Red Hat bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2213614

yarda avatar Aug 31 '23 19:08 yarda

Thx for the answer, got it

alexeyantropov avatar Sep 04 '23 11:09 alexeyantropov