Fedora /etc/sysctl.conf not loaded upon boot

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
2
down vote

favorite
1












I am running Fedora 27 with kernel 4.14.5 and have a problem that /etc/sysctl.conf is not being loaded upon boot.



If I run:



sudo sysctl -p


after boot, my settings are loaded and everything works fine.



What do I need to do to enable the loading of /etc/sysctl.conf or what alternatives are there to load it?







share|improve this question














migrated from serverfault.com Dec 16 '17 at 6:08


This question came from our site for system and network administrators.


















    up vote
    2
    down vote

    favorite
    1












    I am running Fedora 27 with kernel 4.14.5 and have a problem that /etc/sysctl.conf is not being loaded upon boot.



    If I run:



    sudo sysctl -p


    after boot, my settings are loaded and everything works fine.



    What do I need to do to enable the loading of /etc/sysctl.conf or what alternatives are there to load it?







    share|improve this question














    migrated from serverfault.com Dec 16 '17 at 6:08


    This question came from our site for system and network administrators.
















      up vote
      2
      down vote

      favorite
      1









      up vote
      2
      down vote

      favorite
      1






      1





      I am running Fedora 27 with kernel 4.14.5 and have a problem that /etc/sysctl.conf is not being loaded upon boot.



      If I run:



      sudo sysctl -p


      after boot, my settings are loaded and everything works fine.



      What do I need to do to enable the loading of /etc/sysctl.conf or what alternatives are there to load it?







      share|improve this question














      I am running Fedora 27 with kernel 4.14.5 and have a problem that /etc/sysctl.conf is not being loaded upon boot.



      If I run:



      sudo sysctl -p


      after boot, my settings are loaded and everything works fine.



      What do I need to do to enable the loading of /etc/sysctl.conf or what alternatives are there to load it?









      share|improve this question













      share|improve this question




      share|improve this question








      edited Dec 16 '17 at 6:56









      Vlastimil

      6,4211147119




      6,4211147119










      asked Dec 16 '17 at 5:56









      Anton Althoff

      133




      133




      migrated from serverfault.com Dec 16 '17 at 6:08


      This question came from our site for system and network administrators.






      migrated from serverfault.com Dec 16 '17 at 6:08


      This question came from our site for system and network administrators.






















          2 Answers
          2






          active

          oldest

          votes

















          up vote
          3
          down vote



          accepted










          In systemd operating systems like Fedora, loading these settings is done with the systemd-sysctl commmand, run by the systemd-sysctl service. Your problem is that you have put the settings in the wrong configuration file.



          systemd-sysctl does not read /etc/sysctl.conf. It reads a whole bunch of *.conf files in (amongst other places) the /etc/sysctl.d directory. You should create such a file and put your settings there.



          Further reading



          • Lennart Poettering et al. (2016). systemd-sysctl. systemd manual pages. Freedesktop.org.

          • Lennart Poettering et al. (2016). sysctl.d. systemd manual pages. Freedesktop.org.





          share|improve this answer



























            up vote
            1
            down vote













            Edit your root's CRON:



            sudo crontab -e


            Paste the following:



            @reboot /sbin/sysctl --load=/etc/sysctl.conf





            share|improve this answer






















            • This will work, but is a kludge around a different configuration problem.
              – mattdm
              Dec 16 '17 at 14:12










            • @mattdm I myself am using it. Tell me in detail, what problems it might cause as for your claim. Thanks.
              – Vlastimil
              Dec 16 '17 at 14:19










            • It's not the normal way to configure this. There's many ways to do things, and if you like a certain way, that's fine, but the other answer represents the standard way. That's important if you ever work on other systems, or if other people work on yours, or if you want the knowledge to transfer for a job or something.
              – mattdm
              Dec 16 '17 at 15:13






            • 1




              Additionally, this will trigger after a reboot when cron starts. The systemd-sysctl service usually starts very early. That's probably not going to cause a problem in real life, but could, depending on what you want to set.
              – mattdm
              Dec 16 '17 at 15:14










            Your Answer







            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "106"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            convertImagesToLinks: false,
            noModals: false,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );








             

            draft saved


            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f411210%2ffedora-etc-sysctl-conf-not-loaded-upon-boot%23new-answer', 'question_page');

            );

            Post as a guest






























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            3
            down vote



            accepted










            In systemd operating systems like Fedora, loading these settings is done with the systemd-sysctl commmand, run by the systemd-sysctl service. Your problem is that you have put the settings in the wrong configuration file.



            systemd-sysctl does not read /etc/sysctl.conf. It reads a whole bunch of *.conf files in (amongst other places) the /etc/sysctl.d directory. You should create such a file and put your settings there.



            Further reading



            • Lennart Poettering et al. (2016). systemd-sysctl. systemd manual pages. Freedesktop.org.

            • Lennart Poettering et al. (2016). sysctl.d. systemd manual pages. Freedesktop.org.





            share|improve this answer
























              up vote
              3
              down vote



              accepted










              In systemd operating systems like Fedora, loading these settings is done with the systemd-sysctl commmand, run by the systemd-sysctl service. Your problem is that you have put the settings in the wrong configuration file.



              systemd-sysctl does not read /etc/sysctl.conf. It reads a whole bunch of *.conf files in (amongst other places) the /etc/sysctl.d directory. You should create such a file and put your settings there.



              Further reading



              • Lennart Poettering et al. (2016). systemd-sysctl. systemd manual pages. Freedesktop.org.

              • Lennart Poettering et al. (2016). sysctl.d. systemd manual pages. Freedesktop.org.





              share|improve this answer






















                up vote
                3
                down vote



                accepted







                up vote
                3
                down vote



                accepted






                In systemd operating systems like Fedora, loading these settings is done with the systemd-sysctl commmand, run by the systemd-sysctl service. Your problem is that you have put the settings in the wrong configuration file.



                systemd-sysctl does not read /etc/sysctl.conf. It reads a whole bunch of *.conf files in (amongst other places) the /etc/sysctl.d directory. You should create such a file and put your settings there.



                Further reading



                • Lennart Poettering et al. (2016). systemd-sysctl. systemd manual pages. Freedesktop.org.

                • Lennart Poettering et al. (2016). sysctl.d. systemd manual pages. Freedesktop.org.





                share|improve this answer












                In systemd operating systems like Fedora, loading these settings is done with the systemd-sysctl commmand, run by the systemd-sysctl service. Your problem is that you have put the settings in the wrong configuration file.



                systemd-sysctl does not read /etc/sysctl.conf. It reads a whole bunch of *.conf files in (amongst other places) the /etc/sysctl.d directory. You should create such a file and put your settings there.



                Further reading



                • Lennart Poettering et al. (2016). systemd-sysctl. systemd manual pages. Freedesktop.org.

                • Lennart Poettering et al. (2016). sysctl.d. systemd manual pages. Freedesktop.org.






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Dec 16 '17 at 10:46









                JdeBP

                28.6k459134




                28.6k459134






















                    up vote
                    1
                    down vote













                    Edit your root's CRON:



                    sudo crontab -e


                    Paste the following:



                    @reboot /sbin/sysctl --load=/etc/sysctl.conf





                    share|improve this answer






















                    • This will work, but is a kludge around a different configuration problem.
                      – mattdm
                      Dec 16 '17 at 14:12










                    • @mattdm I myself am using it. Tell me in detail, what problems it might cause as for your claim. Thanks.
                      – Vlastimil
                      Dec 16 '17 at 14:19










                    • It's not the normal way to configure this. There's many ways to do things, and if you like a certain way, that's fine, but the other answer represents the standard way. That's important if you ever work on other systems, or if other people work on yours, or if you want the knowledge to transfer for a job or something.
                      – mattdm
                      Dec 16 '17 at 15:13






                    • 1




                      Additionally, this will trigger after a reboot when cron starts. The systemd-sysctl service usually starts very early. That's probably not going to cause a problem in real life, but could, depending on what you want to set.
                      – mattdm
                      Dec 16 '17 at 15:14














                    up vote
                    1
                    down vote













                    Edit your root's CRON:



                    sudo crontab -e


                    Paste the following:



                    @reboot /sbin/sysctl --load=/etc/sysctl.conf





                    share|improve this answer






















                    • This will work, but is a kludge around a different configuration problem.
                      – mattdm
                      Dec 16 '17 at 14:12










                    • @mattdm I myself am using it. Tell me in detail, what problems it might cause as for your claim. Thanks.
                      – Vlastimil
                      Dec 16 '17 at 14:19










                    • It's not the normal way to configure this. There's many ways to do things, and if you like a certain way, that's fine, but the other answer represents the standard way. That's important if you ever work on other systems, or if other people work on yours, or if you want the knowledge to transfer for a job or something.
                      – mattdm
                      Dec 16 '17 at 15:13






                    • 1




                      Additionally, this will trigger after a reboot when cron starts. The systemd-sysctl service usually starts very early. That's probably not going to cause a problem in real life, but could, depending on what you want to set.
                      – mattdm
                      Dec 16 '17 at 15:14












                    up vote
                    1
                    down vote










                    up vote
                    1
                    down vote









                    Edit your root's CRON:



                    sudo crontab -e


                    Paste the following:



                    @reboot /sbin/sysctl --load=/etc/sysctl.conf





                    share|improve this answer














                    Edit your root's CRON:



                    sudo crontab -e


                    Paste the following:



                    @reboot /sbin/sysctl --load=/etc/sysctl.conf






                    share|improve this answer














                    share|improve this answer



                    share|improve this answer








                    edited Dec 16 '17 at 11:54

























                    answered Dec 16 '17 at 6:24









                    Vlastimil

                    6,4211147119




                    6,4211147119











                    • This will work, but is a kludge around a different configuration problem.
                      – mattdm
                      Dec 16 '17 at 14:12










                    • @mattdm I myself am using it. Tell me in detail, what problems it might cause as for your claim. Thanks.
                      – Vlastimil
                      Dec 16 '17 at 14:19










                    • It's not the normal way to configure this. There's many ways to do things, and if you like a certain way, that's fine, but the other answer represents the standard way. That's important if you ever work on other systems, or if other people work on yours, or if you want the knowledge to transfer for a job or something.
                      – mattdm
                      Dec 16 '17 at 15:13






                    • 1




                      Additionally, this will trigger after a reboot when cron starts. The systemd-sysctl service usually starts very early. That's probably not going to cause a problem in real life, but could, depending on what you want to set.
                      – mattdm
                      Dec 16 '17 at 15:14
















                    • This will work, but is a kludge around a different configuration problem.
                      – mattdm
                      Dec 16 '17 at 14:12










                    • @mattdm I myself am using it. Tell me in detail, what problems it might cause as for your claim. Thanks.
                      – Vlastimil
                      Dec 16 '17 at 14:19










                    • It's not the normal way to configure this. There's many ways to do things, and if you like a certain way, that's fine, but the other answer represents the standard way. That's important if you ever work on other systems, or if other people work on yours, or if you want the knowledge to transfer for a job or something.
                      – mattdm
                      Dec 16 '17 at 15:13






                    • 1




                      Additionally, this will trigger after a reboot when cron starts. The systemd-sysctl service usually starts very early. That's probably not going to cause a problem in real life, but could, depending on what you want to set.
                      – mattdm
                      Dec 16 '17 at 15:14















                    This will work, but is a kludge around a different configuration problem.
                    – mattdm
                    Dec 16 '17 at 14:12




                    This will work, but is a kludge around a different configuration problem.
                    – mattdm
                    Dec 16 '17 at 14:12












                    @mattdm I myself am using it. Tell me in detail, what problems it might cause as for your claim. Thanks.
                    – Vlastimil
                    Dec 16 '17 at 14:19




                    @mattdm I myself am using it. Tell me in detail, what problems it might cause as for your claim. Thanks.
                    – Vlastimil
                    Dec 16 '17 at 14:19












                    It's not the normal way to configure this. There's many ways to do things, and if you like a certain way, that's fine, but the other answer represents the standard way. That's important if you ever work on other systems, or if other people work on yours, or if you want the knowledge to transfer for a job or something.
                    – mattdm
                    Dec 16 '17 at 15:13




                    It's not the normal way to configure this. There's many ways to do things, and if you like a certain way, that's fine, but the other answer represents the standard way. That's important if you ever work on other systems, or if other people work on yours, or if you want the knowledge to transfer for a job or something.
                    – mattdm
                    Dec 16 '17 at 15:13




                    1




                    1




                    Additionally, this will trigger after a reboot when cron starts. The systemd-sysctl service usually starts very early. That's probably not going to cause a problem in real life, but could, depending on what you want to set.
                    – mattdm
                    Dec 16 '17 at 15:14




                    Additionally, this will trigger after a reboot when cron starts. The systemd-sysctl service usually starts very early. That's probably not going to cause a problem in real life, but could, depending on what you want to set.
                    – mattdm
                    Dec 16 '17 at 15:14












                     

                    draft saved


                    draft discarded


























                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f411210%2ffedora-etc-sysctl-conf-not-loaded-upon-boot%23new-answer', 'question_page');

                    );

                    Post as a guest













































































                    Popular posts from this blog

                    Peggy Mitchell

                    Palaiologos

                    The Forum (Inglewood, California)