You are not logged in.

#1 2015-09-06 22:40:41

BlueYoshi
Member
Registered: 2015-03-14
Posts: 62

[SOLVED] Resetting sysctl to default

I've set a decent number of custom rules in command line like '# sysctl kernel.example=1' that I'd like removed through a default reset.

Is there any command to reset all sysctl rules to defaults? Or must I find the directory/file they're written to, and then find a default version of the file?

Last edited by BlueYoshi (2015-09-06 23:15:55)

Offline

#2 2015-09-06 22:52:04

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 11,901
Website

Re: [SOLVED] Resetting sysctl to default

As far as I know, there is no command to "reset" sysctl settings in a live system. However, changing sysctl values in the way that you described only last until you reboot. When you reboot, the default values are used unless you have overridden them in sysctl.d config files.

https://wiki.archlinux.org/index.php/Sy … figuration


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#3 2015-09-06 23:01:56

BlueYoshi
Member
Registered: 2015-03-14
Posts: 62

Re: [SOLVED] Resetting sysctl to default

WorMzy wrote:

As far as I know, there is no command to "reset" sysctl settings in a live system. However, changing sysctl values in the way that you described only last until you reboot. When you reboot, the default values are used unless you have overridden them in sysctl.d config files.

https://wiki.archlinux.org/index.php/Sy … figuration

Ah, I'd forgotten. I've been compulsively going through journalctl all day trying to clear up any sort of warning I could find.

I think I realize what the issue is now. I was seeing this in the logs: [systemd-sysctl[235]: Couldn't write '1' to 'net/ipv6/conf/all/disable_ipv6', ignoring: No such file or directory], and I just remembered now that since I also disable the IPv6 stack from kernel parameter, the sysctl.d file to disable must be failing since IPv6 was already killed before it was executed.

Offline

Board footer

Powered by FluxBB