qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] vl: Adjust the place of processing '-mon'
@ 2015-03-04 10:59 zhanghailiang
  2015-03-04 11:08 ` Paolo Bonzini
  2015-03-04 17:02 ` Markus Armbruster
  0 siblings, 2 replies; 8+ messages in thread
From: zhanghailiang @ 2015-03-04 10:59 UTC (permalink / raw)
  To: qemu-devel
  Cc: pbonzini, arei.gonglei, peter.huangpeng, Xiangyou Xie,
	zhanghailiang

From: Xiangyou Xie <xiexiangyou@huawei.com>

If VM is configured with large size of hugepage, when startup,
it will consume lots of time to zero the hugepage memory in the function
'os_mem_prealloc'.
Libvirtd will wait 30 seconds for qemu to establish the monitor,
If the timeout triggers, libvirtd will send TERM signal to kill qemu.

To solve the problem, adjust the processing of '-mon' to the ahead of '-object'.

Signed-off-by: Xiangyou Xie <xiexiangyou@huawei.com>
Signed-off-by: zhanghailiang <zhang.zhanghailiang@huawei.com>
---
 vl.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/vl.c b/vl.c
index 86bdce0..d0c03fe 100644
--- a/vl.c
+++ b/vl.c
@@ -4000,6 +4000,10 @@ int main(int argc, char **argv, char **envp)
         exit(0);
     }
 
+    if (qemu_opts_foreach(qemu_find_opts("mon"), mon_init_func, NULL, 1) != 0) {
+        exit(1);
+    }
+
     if (qemu_opts_foreach(qemu_find_opts("object"),
                           object_create, NULL, 0) != 0) {
         exit(1);
@@ -4154,10 +4158,6 @@ int main(int argc, char **argv, char **envp)
 
     parse_numa_opts();
 
-    if (qemu_opts_foreach(qemu_find_opts("mon"), mon_init_func, NULL, 1) != 0) {
-        exit(1);
-    }
-
     if (foreach_device_config(DEV_SERIAL, serial_parse) < 0)
         exit(1);
     if (foreach_device_config(DEV_PARALLEL, parallel_parse) < 0)
-- 
1.7.12.4

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2015-03-06 13:42 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-04 10:59 [Qemu-devel] [PATCH] vl: Adjust the place of processing '-mon' zhanghailiang
2015-03-04 11:08 ` Paolo Bonzini
2015-03-04 17:02 ` Markus Armbruster
2015-03-06  8:58   ` zhanghailiang
2015-03-06  9:51   ` Peter Maydell
2015-03-06 10:08     ` zhanghailiang
2015-03-06 12:05     ` Markus Armbruster
2015-03-06 12:11       ` Peter Maydell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).