Previous page

Next page

Locate page in Contents

Print this page

Validating Container Configuration

The system resource control parameters have complex interdependencies. The violation of these interdependencies can be catastrophic for the Container. In order to ensure that a Container does not break them, it is important to validate the Container configuration file before creating Containers on its basis.

The typical validation scenario is shown below:

# vzcfgvalidate /etc/vz/conf/101.conf

Error: kmemsize.bar should be > 1835008 (currently, 25000)

Recommendation: dgramrcvbuf.bar should be > 132096 (currently, 65536)

Recommendation: othersockbuf.bar should be > 132096 \

(currently, 122880)

# pctl set 101 --kmemsize 2211840:2359296 --save

Saved parameters for Container 101

# vzcfgvalidate /etc/vz/conf/101.conf

Recommendation: kmemsize.lim-kmemsize.bar should be > 163840 \

(currently, 147456)

Recommendation: dgramrcvbuf.bar should be > 132096 (currently, 65536)

Recommendation: othersockbuf.bar should be > 132096 \

(currently, 122880)

Validation completed: success

The utility checks constraints on the resource management parameters and displays all the constraint violations found. There can be three levels of violation severity:

Recommendation

This is a suggestion, which is not critical for Container or server operations. The configuration is valid in general; however, if the system has enough memory, it is better to increase the settings as advised.

Warning

A constraint is not satisfied, and the configuration is invalid. The Container applications may not have optimal performance or may fail in an ungraceful way.

Error

An important constraint is not satisfied, and the configuration is invalid. The Container applications have increased chances to fail unexpectedly, to be terminated, or to hang.

In the scenario above, the first run of the vzcfgvalidate utility found a critical error for the kmemsize parameter value. After setting reasonable values for kmemsize , the resulting configuration produced only recommendations, and the Container can be safely run with this configuration.