With most of the important linux distributions making the move to systemd you might be asking how can you manage the services and features that your computer enables during boot?. Disabling IPv6 on a Fedora 20 is an easy way to learn the new method of doing things with systemd.
There is a magic tool for configuring kernel parameters which is sysctl.
In your Fedora box you will find a detailed man page on how to use this tool, but if you want to have a look at a simpler version check this one out.
Now which options do we have and which are their current settings? Let’s list all the current variables and filter them for this ipv6 example:
1 2 3 4 5 6 7 8 9 10 11 12 13 14
The last line shown here is exactly what we wanted to change. As you might have guessed 0 is false and 1 is true, so here ipv6 is enabled (which is the default)
I found two methods for doing the change:
- The easiest ways is to set the value with sysctl itself:
- The second and a bit longer way is to write the change to
/etc/sysctl.confand then ask sysctl to read the config file. You can do it with:
The second way is a bit longer but it keeps everything documented in one place and changes are more likely to survive future kernel upgrades. So if you can choose, do the second one be a happy sysadmin :)
This is the same method you would use on CentOS 7 and Red Hat Linux 7.
With this simple example you have learned how to easily change parameters on systemd. In the step where we listed the ipv6 options you will find other options to disable it for just a specific adapter and many more kernel configuration options.