[libvirt] [PATCH] docs: Discourage users to set hard_limit

In one of my previous patches I am removing the hard_limit heuristic to guess the correct value if none set. However, it turned out, this limit is hard to guess even for users. We should advise them to not set the limit as their domains may be OOM killed. Sigh. --- docs/formatdomain.html.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 83d551a..93234a4 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -676,7 +676,10 @@ <dt><code>hard_limit</code></dt> <dd> The optional <code>hard_limit</code> element is the maximum memory the guest can use. The units for this value are kibibytes (i.e. blocks - of 1024 bytes)</dd> + of 1024 bytes). <strong>However, users are strongly advised not to set + this limit as domain may get killed by the kernel. To determine the + memory needed for a process to run is <a href="http://en.wikipedia.org/wiki/Undecidable_problem"> + undecidable problem</a>.</strong></dd> <dt><code>soft_limit</code></dt> <dd> The optional <code>soft_limit</code> element is the memory limit to enforce during memory contention. The units for this value are -- 1.8.1.5

On Mon, Aug 19, 2013 at 12:02:47PM +0200, Michal Privoznik wrote:
In one of my previous patches I am removing the hard_limit heuristic to guess the correct value if none set. However, it turned out, this limit is hard to guess even for users. We should advise them to not set the limit as their domains may be OOM killed. Sigh. --- docs/formatdomain.html.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 83d551a..93234a4 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -676,7 +676,10 @@ <dt><code>hard_limit</code></dt> <dd> The optional <code>hard_limit</code> element is the maximum memory the guest can use. The units for this value are kibibytes (i.e. blocks - of 1024 bytes)</dd> + of 1024 bytes). <strong>However, users are strongly advised not to set + this limit as domain may get killed by the kernel. To determine the + memory needed for a process to run is <a href="http://en.wikipedia.org/wiki/Undecidable_problem"> + undecidable problem</a>.</strong></dd> <dt><code>soft_limit</code></dt> <dd> The optional <code>soft_limit</code> element is the memory limit to enforce during memory contention. The units for this value are
Can you s/users/users of QEMU and KVM/ since it is fine for LXC guests Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|

On 19.08.2013 12:06, Daniel P. Berrange wrote:
On Mon, Aug 19, 2013 at 12:02:47PM +0200, Michal Privoznik wrote:
In one of my previous patches I am removing the hard_limit heuristic to guess the correct value if none set. However, it turned out, this limit is hard to guess even for users. We should advise them to not set the limit as their domains may be OOM killed. Sigh. --- docs/formatdomain.html.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 83d551a..93234a4 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -676,7 +676,10 @@ <dt><code>hard_limit</code></dt> <dd> The optional <code>hard_limit</code> element is the maximum memory the guest can use. The units for this value are kibibytes (i.e. blocks - of 1024 bytes)</dd> + of 1024 bytes). <strong>However, users are strongly advised not to set + this limit as domain may get killed by the kernel. To determine the + memory needed for a process to run is <a href="http://en.wikipedia.org/wiki/Undecidable_problem"> + undecidable problem</a>.</strong></dd> <dt><code>soft_limit</code></dt> <dd> The optional <code>soft_limit</code> element is the memory limit to enforce during memory contention. The units for this value are
Can you s/users/users of QEMU and KVM/ since it is fine for LXC guests
Daniel
Fixed and pushed. Thanks. Michal

On 08/19/2013 04:02 AM, Michal Privoznik wrote:
In one of my previous patches I am removing the hard_limit heuristic to guess the correct value if none set. However, it turned out, this limit is hard to guess even for users. We should advise them to not set the limit as their domains may be OOM killed. Sigh. --- docs/formatdomain.html.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 83d551a..93234a4 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -676,7 +676,10 @@ <dt><code>hard_limit</code></dt> <dd> The optional <code>hard_limit</code> element is the maximum memory the guest can use. The units for this value are kibibytes (i.e. blocks - of 1024 bytes)</dd> + of 1024 bytes). <strong>However, users are strongly advised not to set + this limit as domain may get killed by the kernel. To determine the
Maybe make it clear that "may get killed by the kernel if the guess is too low"
+ memory needed for a process to run is <a href="http://en.wikipedia.org/wiki/Undecidable_problem">
Missing an article, s/is/is an/
+ undecidable problem</a>.</strong></dd> <dt><code>soft_limit</code></dt> <dd> The optional <code>soft_limit</code> element is the memory limit to enforce during memory contention. The units for this value are
-- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
participants (3)
-
Daniel P. Berrange
-
Eric Blake
-
Michal Privoznik