Skip to main content
Topic: OpenRC Sysctl service stopped loading .conf file. (Read 447 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

OpenRC Sysctl service stopped loading .conf file.

Hello, I try to diasble IPv6 networking using this in the .conf file:
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1
net.ipv6.conf.tun.disable_ipv6 = 1
but for some reason it stopped loading it and I have to do it manually after every reboot. Any ideas why?

Re: OpenRC Sysctl service stopped loading .conf file.

Reply #1
Which .conf file.?

Should work if you put it in ANYTHING.conf within /etc/sysctl.d
So long as the sysctl service is enabled.

Take note of the following.
Quote
--system
      Load settings from all system configuration files. Files are read from directories in  the  fol‐
      lowing  list  in given order from top to bottom.  Once a file of a given filename is loaded, any
      file of the same name in subsequent directories is ignored.
      /etc/sysctl.d/*.conf
      /run/sysctl.d/*.conf
      /usr/local/lib/sysctl.d/*.conf
      /usr/lib/sysctl.d/*.conf
      /lib/sysctl.d/*.conf
      /etc/sysctl.conf
So if you happen to have created /etc/sysctl.conf (I say created as it doesn't exist on my system) and there's a file named the same in one of the previous directories /etc/sysctl.conf would be ignored. Unlikely but you never know.

Another option is just to add ipv6.disable=1 to the kernel cmdline. Which is how I do it. Why I did it like that can't remember ?