Smokes your problems, coughs fresh air.

Setting max memory of a Xen Dom0

I’ve had some issues with Xen crashing when I wanted to create a DomU for which the Dom0 had to shrink (see bug report). Therefore, it’s better to force a memory limit on the dom0. That is done with a kernel param.

Add this to /etc/default/grub:

# Start dom0 with less RAM
GRUB_CMDLINE_XEN_DEFAULT="dom0_mem=512M"

And make sure you disabling ballooning of dom0 in /etc/xen/xend-config.sxp:

(enable-dom0-ballooning no)

Then run update-grub2 and reboot.

2 Comments

  1. Rowan Rodrik

    Dude, I recall you saying at some time that it’d be impossible to beat my post count, because I had such a big head start… Well, a few posts ago, you did. Just sayin’. 😉

  2. Gabriel

    neat, this was the piece of the puzzle that was missing on my setup.

    I’ve disabled dom0 ballooning entirely to try and avoid resizing crash issues (what a bad bug ..) but the dom0 was then taking all the available space for itself and wouldn’t let it go for VMs.

    now it’s restricted to 500Mb and the rest is available to domUs.

    thanks for your post!

© 2024 BigSmoke

Theme by Anders NorenUp ↑