New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit dom0 memory to 4GB #1313

Closed
marmarek opened this Issue Oct 9, 2015 · 2 comments

Comments

Projects
None yet
2 participants
@marmarek
Member

marmarek commented Oct 9, 2015

Apparently Linux kernel reserves some internal memory structures based on maximum memory, not the actual one. This is waste of resources, especially on big systems, because normally most of memory is assigned to AppVMs.
This is also along the lines of Xen best practices.

Related to #1136

@qubesuser

This comment has been minimized.

Show comment
Hide comment
@qubesuser

qubesuser Oct 10, 2015

Sounds good, although in addition to 4GB, 8GB and 16GB also seem reasonable candidates for the value to use.

Longer term, it would be nice to get memory hotplugging working for both dom0 and VMs in a way that results in not wasting memory for page structures for unassigned RAM and ballooning instantly, and then maybe remove the dom0 limit again, but I'm not sure if that's feasible.

Sounds good, although in addition to 4GB, 8GB and 16GB also seem reasonable candidates for the value to use.

Longer term, it would be nice to get memory hotplugging working for both dom0 and VMs in a way that results in not wasting memory for page structures for unassigned RAM and ballooning instantly, and then maybe remove the dom0 limit again, but I'm not sure if that's feasible.

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Oct 10, 2015

Member

On Sat, Oct 10, 2015 at 02:30:08PM -0700, qubesuser wrote:

Sounds good, although in addition to 4GB, 8GB and 16GB also seem reasonable candidates for the value to use.

The point is you don't need too much memory in dom0 - all the user
applications are running in VMs. Dom0 is only for running X server,
window manager and some management scripts. In the future we'll split
even that (X server) to a separate GUI domain, so dom0 will be even
smaller.

Longer term, it would be nice to get memory hotplugging working for both dom0 and VMs in a way that results in not wasting memory for page structures for unassigned RAM and ballooning instantly, and then maybe remove the dom0 limit again, but I'm not sure if that's feasible.

I think this would be mostly useful for VMs. BTW currently because of
this overhead maxmem cannot be bigger than initial mem (aka "memory")
times 10:
QubesOS/qubes-core-admin@bf21730

So if we get the memory hot plugging working, we probably could get rid
of that limit.

Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

Member

marmarek commented Oct 10, 2015

On Sat, Oct 10, 2015 at 02:30:08PM -0700, qubesuser wrote:

Sounds good, although in addition to 4GB, 8GB and 16GB also seem reasonable candidates for the value to use.

The point is you don't need too much memory in dom0 - all the user
applications are running in VMs. Dom0 is only for running X server,
window manager and some management scripts. In the future we'll split
even that (X server) to a separate GUI domain, so dom0 will be even
smaller.

Longer term, it would be nice to get memory hotplugging working for both dom0 and VMs in a way that results in not wasting memory for page structures for unassigned RAM and ballooning instantly, and then maybe remove the dom0 limit again, but I'm not sure if that's feasible.

I think this would be mostly useful for VMs. BTW currently because of
this overhead maxmem cannot be bigger than initial mem (aka "memory")
times 10:
QubesOS/qubes-core-admin@bf21730

So if we get the memory hot plugging working, we probably could get rid
of that limit.

Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 20, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 20, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 20, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 20, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 20, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 20, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 20, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 21, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 21, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 21, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 21, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 21, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313

fepitre added a commit to fepitre/anaconda that referenced this issue Sep 22, 2017

anaconda: limit dom0 maxmem to 4GB to limit its overhead on big systems
Linux kernel have some memory overhead depending on maxmem. Dom0 isn't meant to use that much memory (most should be assigned to AppVMs), so on big systems this will be pure waste.

QubesOS/qubes-issues#1136
Fixes QubesOS/qubes-issues#1313
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment