Fortinet black logo

KVM Administration Guide

sysctl

Copy Link
Copy Doc ID 40495042-8674-11eb-9995-00505692583a:351745
Download PDF

sysctl

You can use sysctl to modify kernel parameters at runtime. For a performant system, the following tuning can be persisted across system restarts using a file in the appropriate directory. The following shows an example:

[root@rhel-tiger-14-6 ~]# touch /etc/sysctl.d/10-tiger.conf

[root@rhel-tiger-14-6 ~]# chown root:root /etc/sysctl.d/10-tiger.conf

[root@rhel-tiger-14-6 ~]# chmod 644 /etc/sysctl.d/10-tiger.conf

[root@rhel-tiger-14-6 ~]# cat /etc/sysctl.d/10-tiger.conf
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.core.netdev_budget=900
vm.swappiness = 0
net.ipv4.tcp_timestamps=0
net.core.netdev_max_backlog=250000
net.core.rmem_max=4194304
net.core.wmem_max=4194304
net.core.rmem_default=4194304
net.core.wmem_default=4194304
net.core.optmem_max=4194304
net.ipv4.tcp_rmem=4096 87380 4194304
net.ipv4.tcp_wmem=4096 65536 4194304
net.ipv4.tcp_low_latency=1

[root@rhel-tiger-14-6 ~]# reboot
  • net.core.netdev_budget=900 represents the maximum number of packets that a single CPU poll receives. The default is 300, but this is tuned up for high load systems.
  • vm.swappiness = 0 shows that swap (virtual memory) is disabled. This helps achieve low latency operations.

sysctl

You can use sysctl to modify kernel parameters at runtime. For a performant system, the following tuning can be persisted across system restarts using a file in the appropriate directory. The following shows an example:

[root@rhel-tiger-14-6 ~]# touch /etc/sysctl.d/10-tiger.conf

[root@rhel-tiger-14-6 ~]# chown root:root /etc/sysctl.d/10-tiger.conf

[root@rhel-tiger-14-6 ~]# chmod 644 /etc/sysctl.d/10-tiger.conf

[root@rhel-tiger-14-6 ~]# cat /etc/sysctl.d/10-tiger.conf
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.core.netdev_budget=900
vm.swappiness = 0
net.ipv4.tcp_timestamps=0
net.core.netdev_max_backlog=250000
net.core.rmem_max=4194304
net.core.wmem_max=4194304
net.core.rmem_default=4194304
net.core.wmem_default=4194304
net.core.optmem_max=4194304
net.ipv4.tcp_rmem=4096 87380 4194304
net.ipv4.tcp_wmem=4096 65536 4194304
net.ipv4.tcp_low_latency=1

[root@rhel-tiger-14-6 ~]# reboot
  • net.core.netdev_budget=900 represents the maximum number of packets that a single CPU poll receives. The default is 300, but this is tuned up for high load systems.
  • vm.swappiness = 0 shows that swap (virtual memory) is disabled. This helps achieve low latency operations.