balloon ram error on MS Server 2008 R2 ( pc.ram: Cannot allocate memory )

andrewww

New Member
Aug 27, 2014
3
0
1
Hi!
Ihave a physical machine, where is running MS Win server 2008 R2.

I successfully (almost successful, there were some problems with MBR and bootcode) to move it to Proxmox 3.2 using Clonezilla. (using disk IDE in guest VM and fixed (not Balloon) RAM )
Next install virtio drivers, install balloon service, reboot, and shutdown.
After this i'm wanted to configure balloon RAM and set RAM size to 512/6000.
But when machine started, i saw error:

Cannot set up guest memory 'pc.ram': Cannot allocate memory
TASK ERROR: start failed: command '/usr/bin/kvm -id 101 -chardev 'socket,id=qmp,path=/var/run/qemu-server/101.qmp,server,nowait' -mon 'chardev=qmp,mode=control' -vnc unix:/var/run/qemu-server/101.vnc,x509,password -pidfile /var/run/qemu-server/101.pid -daemonize -smbios 'type=1,uuid=809fc45c-c170-4d73-bfd6-49ce8fc78f1d' -name ntc-srv-v1c -smp 'sockets=1,cores=4' -nodefaults -boot 'menu=on' -vga std -no-hpet -cpu 'kvm64,hv_spinlocks=0xffff,hv_relaxed,+lahf_lm,+x2apic,+sep' -k en-us -m 4096 -device 'piix3-usb-uhci,id=uhci,bus=pci.0,addr=0x1.0x2' -readconfig /usr/share/qemu-server/pve-usb.cfg -device 'usb-tablet,id=tablet,bus=uhci.0,port=1' -device 'usb-host,hostbus=1,hostport=1.5' -device 'virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3' -iscsi 'initiator-name=iqn.1993-08.org.debian:01:84ac71905dc2' -drive 'file=/var/lib/vz/images/101/vm-101-disk-1.qcow2,if=none,id=drive-virtio1,format=qcow2,cache=writeback,aio=native' -device 'virtio-blk-pci,drive=drive-virtio1,id=virtio1,bus=pci.0,addr=0xb' -drive 'file=/var/lib/vz/images/101/vm-101-disk-3.qcow2,if=none,id=drive-ide0,format=qcow2,cache=writeback,aio=native' -device 'ide-hd,bus=ide.0,unit=0,drive=drive-ide0,id=ide0,bootindex=101' -drive 'file=/mnt/pve/ntc-disk-iso/template/iso/virtio-win-0.1-81.iso,if=none,id=drive-ide2,media=cdrom,aio=native' -device 'ide-cd,bus=ide.1,unit=0,drive=drive-ide2,id=ide2' -netdev 'type=tap,id=net0,ifname=tap101i0,script=/var/lib/qemu-server/pve-bridge,downscript=/var/lib/qemu-server/pve-bridgedown,vhost=on' -device 'virtio-net-pci,romfile=,mac=42:20:A5:4C:4B:DE,netdev=net0,bus=pci.0,addr=0x12,id=net0' -rtc 'driftfix=slew,base=localtime' -global 'kvm-pit.lost_tick_policy=discard'' failed: exit code 1

After several unsuccessful attempts to find a working configuration RAM, I stopped at a working version 512/4096.

The same error is detected at the other server which was installed and not migrate, and which also uses IDE disk.

I'm install test server with virtio disk (MS Server 2008 R2), but there is no such error, and it work fine.
I'm don't know, whether there is a relationship between these cases or is it some kind of magic? :D

Sorry for my bad bad english :rolleyes:
 
Hi, that mean that you don't have enough free memory on your host to start the vm.

with 512/6000, it need 6000M memory free at start. After boot, the balloon service will try to lowering the value to 512.

 
Thanks for answer, you were right.
Today saw another problem:
in task manager VM100 (server 2008 R2) uses 787MB of 7.8 GB RAM
in web interface summary server uses 6.8 of 7.8 GB RAM
and proxmox node uses RAM (output 'free -m')
root@virt:~# free -m
total used free shared buffers cached
Mem: 15936 10825 5110 0 0 33
-/+ buffers/cache: 10791 5144
Swap: 7167 1735 5432
screenshot



Why such differences in indication, and which ones are correct?
 
Last edited:
The problem is that windows is filling the memory with zeros values at boot.
so it's really taking what you see on the host side.

Hopefully, we have KSM feature on host, which should merge theses memory pages, when host memory reach 80%.
 
But in other guest OS this is not observed, although there is also windows, with the same settings.
 
Thanks for answer, you were right.
Today saw another problem:
in task manager VM100 (server 2008 R2) uses 787MB of 7.8 GB RAM
in web interface summary server uses 6.8 of 7.8 GB RAM
and proxmox node uses RAM (output 'free -m')

screenshot



Why such differences in indication, and which ones are correct?

You are looking at correct behavior really. You should take all of them into consideration since all of them are correct. The amount of memory usage that shown by Windows Task Manager will almost never match with memory usage seen on Proxmox WebGUI. The reason simply lot more happening on Cluster side than Windows side. You will see a difference if you have only 1 Windows VM on a physical Proxmox node. Since node memory is shared among multiple VMs it shows different usage per VM. To get clear picture of how much Windows actually using, follow the task manager usage stats.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!