The SYSCTL directive is the setting of the core parameters of the system:
Usage:
-A parameter lists all the core settings in the system
Of course, these core settings are files that are stored in the /proc/sys/net directory.
To cite a representative example:
net.ipv4.icmp_echo_ignore_all = 0 change all the points to / you can do it.
[[email protected] net]# Net.ipv4.icmp_echo_ignore_all = 0
[Email protected] net]# CD ipv4/
[email protected] ipv4]# cat Icmp_echo_ignore_all
0
We can edit or import the method should not file, but also have the relevant command modification:
- W The argument is valid only for English words and is not valid for numbers. You can also see that the relative path is not possible to use an absolute path.
To use a relative path:
The import method is only valid for relative paths.
Tips:
the file equals 1 , it is forbidden to be Ping .
[[email protected] ipv4]# cat Icmp_echo_ignore_all//Such modification is only temporary, the system will be re-assigned after reboot, want to take it into effect permanently, write the article into/etc/sysctl.conf
1
echo "Icmp_echo_ignore_all = 1" >>/etc/sysctl.conf
here 's a look. Sysctl A valid file for this instruction.
# vim/etc/sysctl.conf
turn on kernel routing: default parameters =0
Et.ipv4.ip_forward = 1
make it directly effective after configuration: # sysctl–p
# sysctl–p command can also specify Sysctl instruction configuration file, the system default is stored in the /etc/sysctl.conf , you can actually specify it yourself.