Monday, September 19, 2011

changing the RAM of Domain-0 in xen

Sponsored Links
This post explains how to set or change Domain-0 RAM allocation. This is a dynamic method so I'm not sure it will survive reboot.

Current usage

[root@test ~]# xm list
Name                                      ID Mem(MiB) VCPUs State   Time(s)
Domain-0                                   0    19002     8 r----- 331242.1
vm649                                     27     1007     2 r-----  81706.6
vm652                                     20     2007     2 -b---- 156137.8
vm770                                     26     2007     2 r----- 230305.3

Now setting the Domain-0 RAM to 4GB

[root@test ~]# xm mem-set 0 4096

After changing the RAM of Domain-0

[root@test ~]# xm list
Name                                      ID Mem(MiB) VCPUs State   Time(s)
Domain-0                                   0     4096     8 r----- 331416.8
vm649                                     27     1007     2 r-----  82261.6
vm652                                     20     2007     2 -b---- 156240.8
vm770                                     26     2007     2 r----- 230515.7
[root@test ~]#

There is also another method which edits grub.conf
#vi /etc/grub.conf

title CentOS (2.6.18-238.19.1.el5xen)
        root (hd0,0)
        kernel /boot/xen.gz-2.6.18-238.19.1.el5 dom0_mem=4096
        module /boot/vmlinuz-2.6.18-238.19.1.el5xen ro root=LABEL=/ rhgb quiet
        module /boot/initrd-2.6.18-238.19.1.el5xen.img
It needs rebooting the system

Sponsored Links

No comments:

Post a Comment

Be nice. That's all.