Differences
This shows you the differences between two versions of the page.
— | sysctl [2015/11/30 21:24] (current) – created - external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== sysctl ====== | ||
+ | * [[OpenBSD]] | ||
+ | * [[NetBSD]] | ||
+ | |||
+ | == Display disk drives == | ||
+ | |||
+ | < | ||
+ | sysctl hw.disknames | ||
+ | </ | ||
+ | |||
+ | ==== Linux ==== | ||
+ | |||
+ | Changes to '' | ||
+ | |||
+ | Once your changes are made, you can reload from all the system files: | ||
+ | |||
+ | < | ||
+ | sysctl --system | ||
+ | </ | ||
+ | |||
+ | To display all sysctl settings: | ||
+ | |||
+ | < | ||
+ | |||
+ | You can set a value directly as well: | ||
+ | |||
+ | < | ||
+ | sysctl -w net.ipv4.ip_forward=1 | ||
+ | </ | ||
+ | |||
+ | === Swappiness === | ||
+ | |||
+ | * [[http:// | ||
+ | |||
+ | In Linux, set the percentage to 10 in ''/ | ||
+ | |||
+ | < | ||
+ | vm.swappiness = 10 | ||
+ | </ | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | * vm.swappiness = 0 - swap only to avoid an OOM | ||
+ | * vm.swappiness = 1 - minimum amount of swapping without disabling it completely | ||
+ | * vm.swappiness = 10 - recommended value when sufficient memory exists in a system |