sysctl.d file is misnamed and unneeded

Bug #1938585 reported by Dan Streetman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
procps (Ubuntu)
Fix Released
Low
Dan Streetman
Bionic
Invalid
Undecided
Unassigned
Focal
Invalid
Undecided
Unassigned
Hirsute
Won't Fix
Undecided
Unassigned
Impish
Fix Released
Low
Dan Streetman

Bug Description

[impact]

the sysctl.d file /usr/lib/sysctl.d/protect-links.conf is misnamed, due to lacking the expected leading number to order it. This results in it being evaluated after all other number-prefixed conf files, effectively overriding any conflicting configuration in the other files, including any admin-provided files in /etc/sysctl.d.

Additionally, this file should not be included at all, as (unlike Debian) Ubuntu assumes systemd will always be installed, thus the sysctl settings from this file will be provided by the systemd-provided sysctl config files.

[test case]

create a file, e.g. /etc/sysctl.d/99-test.conf, with any config that also exists in /usr/lib/sysctl.d/protect-links.conf but with a different setting, and reboot, then check which value was used.

[regression potential]

any regression would likely result in incorrect or unexpected values for the sysctls contained in this conf file

[scope]

this is needed in f and later

this file is not present in b

however, see other info

[other info]

while this bug exists in f and later, it's also trivial to work around it (though not obvious) by renaming the manual configuration file, e.g. instead of using /etc/sysctl.d/99-custom.conf a local admin should instead use /etc/sysctl.d/z-custom.conf so the custom file is lexically after 'protect-links.conf'.

Since removing the file entirely could result in a change in behavior, if the local admin has explicitly modified the file or taken other steps, and since it's trivial (though again, not obvious) to override the file lexically, this seems like it should not be SRUed, but only fixed in the development release.

Also, since Debian's policy does allow for systems that do *not* use systemd, I'm not opening a bug against Debian to remove the file.

Revision history for this message
Dan Streetman (ddstreet) wrote :

For clarity, I explicitly added SRU release targets and marked them as either invalid (for bionic, since the file doesn't exist there) or wont-fix (as explained in the description).

Changed in procps (Ubuntu Bionic):
status: New → Invalid
Changed in procps (Ubuntu Focal):
status: New → Invalid
Changed in procps (Ubuntu Hirsute):
status: New → Won't Fix
Changed in procps (Ubuntu Impish):
status: New → In Progress
assignee: nobody → Dan Streetman (ddstreet)
importance: Undecided → Low
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package procps - 2:3.3.17-5ubuntu3

---------------
procps (2:3.3.17-5ubuntu3) impish; urgency=medium

  * Remove /usr/lib/sysctl.d/protect-links.conf (LP: #1938585)

 -- Dan Streetman <email address hidden> Fri, 30 Jul 2021 12:17:48 -0400

Changed in procps (Ubuntu Impish):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.