Giter Site home page Giter Site logo

Suggest to rename `sysctl.conf` about sysctl HOT 2 CLOSED

k4yt3x avatar k4yt3x commented on June 19, 2024
Suggest to rename `sysctl.conf`

from sysctl.

Comments (2)

k4yt3x avatar k4yt3x commented on June 19, 2024

I spent some time thinking about this problem. I'm still not sure whether to recommend putting this configuration before 99-sysctl.conf or after it. One of the ways to use this configuration file is to make this configuration file static and name it something like 98-k4yt3x.conf. The user can then edit /etc/sysctl.conf to overwrite any of the rules. When the hardened profile gets an update, the new file can be dropped in without too many modifications.

However, according to this quote from README.sysctl, either the developer of procps-ng or Linus suggests to name the local configuration such that it's read after 99-sysctl.conf. This method could be more suitable for those that only want to take this file as a reference, then make their changes of the highest priority permanently.

My personal preference would be for local system settings to go into
/etc/sysctl.d/local.conf but as long as you follow the rules for the names
of the file, anything will work. See sysctl.conf(8) man page for details
of the format.

I think this topic is still debatable, and we can always include all three solutions.


As for loading the configuration file, the README.sysctl file says the following:

After making any changes, please run "service procps reload" (or, from
a Debian package maintainer script "deb-systemd-invoke restart procps.service").

In summary, the effect of sysctl --system, systemctl restart procps and systemctl restart systemd-sysctl should be equivalent. They all reload the kernel configuration from all configuration directories. sysctl -p on the other hand, only loads from /etc/sysctl.conf. For a more consistent result, I think preferring sysctl --system or systemctl restart procps would be more ideal like you said. I'll add that shortly.

from sysctl.

k4yt3x avatar k4yt3x commented on June 19, 2024

I've added a whole bunch of stuff into README. Take a look.

from sysctl.

Related Issues (3)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.