0

I have a vps with 256m physical ram and 512m swap space,

I am trying to use a software that need more than 256m and less than 512m ram, so it uses swap.

The problem is at some moment of the installation, the installation process checks the available physical ram, it's full (some swap is used), so it pauses the installation and tills that it must be some more ram to continue the installation..

I see that I need to move some of used physical ram to swap while the process is running.. Is there anyway I can do that? or any other solution!

For sorry I am using openvz vps, and the vm.swappiness option can't be modified as a solution.

  • I don't think any sane software would check free physical memory. Maybe it just checks available virtual memory and adding more swap (it can be a swap file) would suffice. 768MB is rather small these days. – Tometzky Nov 09 '13 at 19:51

1 Answers1

1

With an OpenVZ container, not really, if this is just to get a specific bit of software installed then your options are:

1) Ask your host to bump up your ram for an hour while you do your install (most are fine with this)

2) Try to drop your ram caches to free up enough ram to do your install 'echo 3 > /proc/sys/vm/drop_caches'

Example: http://www.hosting.com/support/linux/clear-memory-cache-on-linux-server/

the drop cache function is a none destructive process, because OpenVZ looks at your memory in use when killing your process for hitting the hard limit the cached ram value is included, dropping your cache will hurt performance but only very short term and may just free up enough to complete your install.

This was a common method used to get the filesystem package to install on OpenVZ when the new package was released in CentOS 5.5 (might have been 5.6 or 5.7)

Despite the negative unfounded comments below this is your only option if you do not want to pay for an upgrade or your host will not give you a temporary boost

Backtogeek
  • 557
  • 2
  • 6
  • 14
  • OK so it's an artifact of how OpenVZ calculates container memory usage? That's ... about what I expect from OpenVZ :) Anyway I removed my downvote. – Michael Hampton Nov 09 '13 at 19:51