|
GNU Linux system variables (sysctl configuration commands) integrated use
See all values of kernel variables
sysctl -a
How to check the value of a system variable
1), cat / proc / sys / net / ipv4 / ip_local_port_range
3276861000
2), sysctl -a | grep ip_local_port_range
net.ipv4.ip_local_port_range = 32768 61000
Modification method:
1), echo "1024 65535"> / proc / sys / net / ipv4 / ip_local_port_range
2), make the following settings in /etc/sysctl.conf in:
net.ipv4.ip_local_port_range = 1024 65535
Then execute: sysctl -p these settings to take effect;
3), use the command directly to optimize the system variables
sysctl -w net.ipv4.ip_local_port_range = 1024 65535
In the above second method, many people might like to respect net.ipv4.ip_local_port_range. Separated variable does not know how to, in fact, this wording is a system variable path in / proc / sys / directory the hierarchical representation; the full path, such as cat / proc / sys / net / ipv4 / ip_local_port_range view system variables when this method is the direct use for viewing values; |
|
|
|