|
|
|
|
|
|
|
|
|
|
xen-changelog
[Xen-changelog] [xen-3.1-testing] Fix xm mem-max command to restore prev
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1204735376 0
# Node ID 622bb660253b69c04c3e22619fe90b51a644f496
# Parent 033e368f70516338c2226af61583999b576279ae
Fix xm mem-max command to restore previous setting if
xc.domain_setmaxmem fails.
Signed-off-by: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>
xen-unstable changeset: 17125:450be98ef36b1af40ab381d8e0aac647012a60a2
xen-unstable date: Tue Feb 26 15:02:26 2008 +0000
---
tools/python/xen/xend/XendDomainInfo.py | 2 ++
1 files changed, 2 insertions(+)
diff -r 033e368f7051 -r 622bb660253b tools/python/xen/xend/XendDomainInfo.py
--- a/tools/python/xen/xend/XendDomainInfo.py Wed Mar 05 10:04:00 2008 +0000
+++ b/tools/python/xen/xend/XendDomainInfo.py Wed Mar 05 16:42:56 2008 +0000
@@ -687,6 +687,7 @@ class XendDomainInfo:
if limit <= 0:
raise XendError('Invalid memory size')
+ maxmem_cur = self.get_memory_static_max()
MiB = 1024 * 1024
self._safe_set_memory('memory_static_max', limit * MiB)
@@ -695,6 +696,7 @@ class XendDomainInfo:
try:
return xc.domain_setmaxmem(self.domid, maxmem)
except Exception, ex:
+ self._safe_set_memory('memory_static_max', maxmem_cur)
raise XendError(str(ex))
xen.xend.XendDomain.instance().managed_config_save(self)
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-changelog] [xen-3.1-testing] Fix xm mem-max command to restore previous setting if,
Xen patchbot-3.1-testing <=
|
|
|
|
|