3

I need to configure only one vps in a openvz node. The node will have only one vps.

I need help to configure the memory limits correctly.

The node have 4GB memory with 4GB swap.

I would like to use as much memory as possible without compromising the stability of node.

I have read the documentation openvz but I'm confused with the value of required parameters.

Anybody can give me a recipe or guide lines to do so?

Roberto
  • 87
  • 1
  • 7
  • Roberto, there has been some recent simplifications / improvements in how you can configure resources on OpenVZ. In /etc/vz/conf/XXX can basically just specify MEMORY, SWAP - and that's it. All the other resources are set to unlimited. What OpenVZ kernel version do you need this for? – Aleksandr Levchuk Jun 23 '11 at 07:17

1 Answers1

2

You basically need to set three values for defining the memory settings of your openvz node

vzctl set VTID --privvmpages 4G --save
vzctl set VTID --swappages 4G --save

I guess you should not use the full ram and swap you have on your physical node.

You can define also Ram values if your physical node has not enough memory check the documentation about oomguarpages,shmpages,physpages and vmguarpages

dasrecht
  • 153
  • 1
  • 1
  • 8