OpenVZ Forum


Home » General » Support » inconsistent physpages when validating config file (inconsistent behaviour of vzcfgvalidate or container's memory)
inconsistent physpages when validating config file [message #44196] Wed, 23 November 2011 19:21 Go to next message
narcisgarcia is currently offline  narcisgarcia
Messages: 41
Registered: May 2009
Member
I'm using Debian 6 (stable, Linux 2.6.32) with vzctl version 3.0.24
Look at error message and same memory results in the container.
$ getconf PAGE_SIZE
4096

$ vzctl create 777 --ostemplate debian-6.0-x86
Creating container private area (debian-6.0-x86)
Performing postcreate actions
Container private area was created

$ vzctl set 777 --physpages 0:256m --swappages 0:512m --setmode restart --save
Saved parameters for CT 777

$ vzlist --all --output ctid,physpages.b,physpages.l,swappages.b,swappages.l
      CTID    PHYSP.B    PHYSP.L    SWAPP.B    SWAPP.L
       777          0      65536          0     131072

$ vzctl start 777
Starting container ...
Container is mounted
Setting CPU units: 1000
Container start in progress...

$ vzctl exec 777 "free -m"
             total       used       free     shared    buffers     cached
Mem:           256         10        245          0          0          0
-/+ buffers/cache:         10        245
Swap:          512          0        512

$ vzcfgvalidate -r /etc/vz/conf/777.conf
Error: limit should be = 2147483647 for physpages (currently, 65536)
set to 2147483647
Validation completed: success

$ vzctl stop 777
Stopping container ...
Container was stopped
Container is unmounted

$ vzctl start 777
Starting container ...
Container is mounted
Setting CPU units: 1000
Container start in progress...

$ vzlist --all --output ctid,physpages.b,physpages.l,swappages.b,swappages.l
      CTID    PHYSP.B    PHYSP.L    SWAPP.B    SWAPP.L
       777          0 2147483647          0          0

$ vzctl exec 777 "free -m"
             total       used       free     shared    buffers     cached
Mem:           256         10        245          0          0          0
-/+ buffers/cache:         10        245
Swap:          512          0        512

$ vzcfgvalidate -r /etc/vz/conf/777.conf
Validation completed: success


I don't understand why physpages.l should be 2147483647 instead of 65536, and why once the value is "corrected", RAM and Swap for the container still have the initial values set.


Narcis Garcia
Re: inconsistent physpages when validating config file [message #44745 is a reply to message #44196] Tue, 27 December 2011 09:19 Go to previous messageGo to next message
narcisgarcia is currently offline  narcisgarcia
Messages: 41
Registered: May 2009
Member
What's wrong in the memory setting command?
Why vzcfgvalidate finds invalid values and why resultant strange values are right?


Narcis Garcia
Re: inconsistent physpages when validating config file [message #44746 is a reply to message #44196] Tue, 27 December 2011 10:55 Go to previous messageGo to next message
Artem is currently offline  Artem
Messages: 9
Registered: December 2011
Location: Belarus, Minsk
Junior Member
can you provide your OpenVZ kernel version (uname -sr) ?

What are 'vmguarpages' and 'privvmpages' values set in your config? (I suppose they are set to near 256m). It is possible that you are using non-VSwap kernel, then you need to set physpages to 0:MAXLONG and use other *pages to configure memory.

wiki.openvz.org/VSwap
Re: inconsistent physpages when validating config file [message #44748 is a reply to message #44746] Tue, 27 December 2011 12:48 Go to previous message
narcisgarcia is currently offline  narcisgarcia
Messages: 41
Registered: May 2009
Member
$ lsb_release -sd
Debian GNU/Linux 6.0.3 (squeeze)

$ uname -sr
Linux 2.6.32-5-openvz-686

$ vzctl --version
vzctl version 3.0.24


Narcis Garcia
Previous Topic: NFQUEUE support in VMs
Next Topic: noobie network question
Goto Forum:
  


Current Time: Sat Aug 24 16:10:50 GMT 2024

Total time taken to generate the page: 0.03329 seconds