Difference between revisions of "Performance tuning"
m (Performance measurement moved to OpenVZ performance tuning) |
|||
Line 1: | Line 1: | ||
− | This page describes how to | + | This page describes how to improve performance of OpenVZ system. |
− | = | + | = HW node environment tuning = |
− | == | + | == Disable unnecessary services == |
− | |||
− | + | Disable all default services that you do not need to use and then reboot your host. | |
− | |||
− | |||
− | + | For example, the <code>audit</code> daemon can significantly decrease performance of linux kernel system calls (up to ~<font color=red>20%</font>) even if you do not use any audit rules, or even if you just stopped this service without host reboot! | |
− | |||
− | + | To setup default services, use <code>chkconfig</code> or <code>ntsysv</code> in RedHat, or <code>rc-update</code> in Gentoo, <code>update-rc.dv</code> on Debian | |
− | |||
− | + | == network checksumming == | |
+ | ('''TODO''') | ||
− | + | = Virtual Environment tuning = | |
− | + | == CPU distribution inside VE on SMP hosts == | |
− | + | * If the total number of VE's in your host is more than CPUs number, and there are many tasks running inside each VE, and they are scheduled quite often, it's better to give just one CPU for each VE. In this case the VirtualCPU-scheduler overhead can be significantly decreased, and overall performance can be increased up to ~<font color=red>50-100%</font>! | |
− | |||
− | |||
− | + | To set the number of CPUs available inside VE use: | |
− | |||
− | + | # vzctl set $VEID --cpus N | |
− | |||
− | + | = Recompiling the kernel = | |
− | + | == Disable all unnecessary options == | |
− | + | * You can disable all <code>_DEBUG_</code> options in the kernel, this can increase performance up to ~<font color=red>20%</font> on some applications. | |
− | * | ||
− | + | * other options ('''TODO''') | |
− | '''TODO''' |
Revision as of 15:49, 3 August 2007
This page describes how to improve performance of OpenVZ system.
Contents
HW node environment tuning
Disable unnecessary services
Disable all default services that you do not need to use and then reboot your host.
For example, the audit
daemon can significantly decrease performance of linux kernel system calls (up to ~20%) even if you do not use any audit rules, or even if you just stopped this service without host reboot!
To setup default services, use chkconfig
or ntsysv
in RedHat, or rc-update
in Gentoo, update-rc.dv
on Debian
network checksumming
(TODO)
Virtual Environment tuning
CPU distribution inside VE on SMP hosts
- If the total number of VE's in your host is more than CPUs number, and there are many tasks running inside each VE, and they are scheduled quite often, it's better to give just one CPU for each VE. In this case the VirtualCPU-scheduler overhead can be significantly decreased, and overall performance can be increased up to ~50-100%!
To set the number of CPUs available inside VE use:
# vzctl set $VEID --cpus N
Recompiling the kernel
Disable all unnecessary options
- You can disable all
_DEBUG_
options in the kernel, this can increase performance up to ~20% on some applications.
- other options (TODO)