Changes

Jump to: navigation, search

UBC consistency check

128 bytes added, 22:35, 23 November 2014
highlight vzcfgvalidate
{{UBC toc}}
System resource control parameters have certain interdependencies. Constraints on the parameter settings are listed below. Indexes <code>bar </code> and <code>lim</code> in the formulae below mean the barrier and the limit of the parameters, respectively.
Configuration of resource control parameters for a Virtual Environmentcontaineris invalid if these constraints are not satisfied. '''The best way to ensure thevalidity of the configuration is to use [http://openvz.org/documentation/the {{man/vzcfgvalidate.8 |vzcfgvalidate(|8)] }} utility.'''
All the interdependencies discussed below and their importance are summarized in [[UBC interdependencies table]].
The configured limits can be checked through
* <code>/[[proc/user_beancounters]] interface;* [[BC proc entries|/proc/user beancounters<bc/code> ]] interface;* Virtual Environment {{Man|vzubc|8}} utility;* container configuration files in <code>/etc/vz/conf/</code> directory.;
(<code>avnumproc</code> here stands for the expected average number of processes).
This constraint is important for reliable applications to work of applications reliably in theVirtual Environmentcontainer.If it is not satisfied, applications will start to fail at in the middle ofoperations instead of failing at the moment of while spawning more processes,and the application abilities 's ability to handle resource shortage will be very
limited.
Selecting the left side equal to the right side in the inequalities
above ensures minimal performance of network communications.
Increasing the left side will increase performance to a certain extent.
== UDP socket buffers should be big large enough if the system is not tight on memory ==
<math>dgramrcvbuf_{bar} \ge 129KB</math>
These constraints are desired, but not essential.
Big Large enough buffers for UDP sockets improve reliability of datagram delivery.
However, note that if the UDP traffic is so bursty that it needs larger
buffers, the datagrams will likely be lost not because of resource control
limits, but because of other memory and performance limitations.
== Number of file files limit should be adequate for the expected number of processes ==
<math>numfile \ge avnumproc \cdot 32</math>
Note that each process after a <code>execve(2)</code> system call
requires a file for each loaded shared library.
Too A too low <code>numfile</code> limit will increase the chances of failuresduring <code>execve(2)</code> call calls with diagnostics error messages that are not clearfor to the users.
== The limit on the total size of <code>dentry</code> and <code>inode</code> structures locked in memory should be adequate for allowed number of files ==
<math>dcachesize_{bar} \ge numfile \cdot 384\ \rm(bytes)</math>
Too A too low <code>dcachesize</code> limit will increase the chances offile operation refusals not expected by applicationsresulting in unexpected application failures.
== Barrier should be less or equal than limit ==
should be maintained for each parameter.
 
== Code ==
See [[User:Grin/openvz checker.pl]] for a contributed code to check the consistency.
[[Category:Troubleshooting]]

Navigation menu