Separate names with a comma.
Discussion in 'Security' started by nitaish, Feb 19, 2010.
How can I tune sysctl.conf without disturbing the server and the websites hosted on it?
basiaclly just change the values and then run
echo "# Enable TCP SYN Cookie Protection
net.ipv4.tcp_syncookies = 1" > /etc/sysctl.conf
Use the sysctl command to alter the settings:
"sysctl -w parameter=new value"
eg: If I want to increase the file descriptors limit, I would run:
sysctl -w fs.file-max=xxxxxx; where xxxxxx is the new value.
if I recall correctly that doesnt persist through a reboot though, so you would need to set it in sysctl.conf file if you wanted to make the change persist through a reboot - I could be wrong though, its been known to happen
Changes won't be lost upon reboot when you set the values using sysctl-w. But you need to make sure that the same values aren't mentioned in sysctl.conf file.
If you edit sysctl.conf file, run sysctl -p to reflect the changes without rebooting the server.