]> xenbits.xensource.com Git - people/royger/xen.git/commitdiff
oxenstored: initialise logging earlier
authorJonathan Davies <jonathan.davies@citrix.com>
Fri, 7 Apr 2017 13:27:18 +0000 (14:27 +0100)
committerWei Liu <wei.liu2@citrix.com>
Mon, 10 Apr 2017 13:46:19 +0000 (14:46 +0100)
Otherwise we miss out on messages from things that try to log earlier in
the start-up procedure.

Signed-off-by: Jonathan Davies <jonathan.davies@citrix.com>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
Reviewed-by: Christian Lindig <christian.lindig@citrix.com>
Release-acked-by: Julien Grall <julien.grall@arm.com>
tools/ocaml/xenstored/xenstored.ml

index 05ace4dfc6b8be4252b555639a1b8b06a19ce49e..09da25715078a09cb84243cc5e7204b8a3414a6f 100644 (file)
@@ -285,6 +285,8 @@ let _ =
 
        let quit = ref false in
 
+       Logging.init_xenstored_log();
+
        if cf.restart then (
                DB.from_file store domains cons (Paths.xen_run_stored ^ "/db");
                Event.bind_dom_exc_virq eventchn
@@ -311,7 +313,6 @@ let _ =
        Sys.set_signal Sys.sigusr1 (Sys.Signal_handle (fun i -> sigusr1_handler store));
        Sys.set_signal Sys.sigpipe Sys.Signal_ignore;
 
-       Logging.init_xenstored_log();
        if cf.activate_access_log then begin
                let post_rotate () = DB.to_file store cons (Paths.xen_run_stored ^ "/db") in
                Logging.init_access_log post_rotate