Mailing List Archive

[PATCH 4 of 4 V2] oxenstored: Always log something at start of day (if logging enabled at all)
# HG changeset patch
# User Ian Campbell <ian.campbell@citrix.com>
# Date 1323792620 0
# Node ID f2e14742b2a2c1f40bc36063a1485b4072865fd1
# Parent fd321c47d4b8e7095758e008ad3801e5d16461a7
oxenstored: Always log something at start of day (if logging enabled at all)

Otherwise at the default level we rarely log anything at all.

A completely empty log file is a good sign, but only if you know you are
looking in the right place...

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>

diff -r fd321c47d4b8 -r f2e14742b2a2 tools/ocaml/xenstored/logging.ml
--- a/tools/ocaml/xenstored/logging.ml Tue Dec 13 16:08:57 2011 +0000
+++ b/tools/ocaml/xenstored/logging.ml Tue Dec 13 16:10:20 2011 +0000
@@ -117,6 +117,9 @@ let init_xenstored_log () =
make_logger
!xenstored_log_file !xenstored_log_nb_files !xenstored_log_nb_lines
!xenstored_log_nb_chars ignore in
+ let date = string_of_date() in
+ logger.write ("[%s|%5s|%s] Xen Storage Daemon, version %d.%d") date "" "startup"
+ Define.xenstored_major Define.xenstored_minor;
xenstored_logger := Some logger

let xenstored_logging level key (fmt: (_,_,_,_) format4) =
diff -r fd321c47d4b8 -r f2e14742b2a2 tools/ocaml/xenstored/xenstored.ml
--- a/tools/ocaml/xenstored/xenstored.ml Tue Dec 13 16:08:57 2011 +0000
+++ b/tools/ocaml/xenstored/xenstored.ml Tue Dec 13 16:10:20 2011 +0000
@@ -284,9 +284,6 @@ let _ =
Logging.init_access_log post_rotate
end;

- info "Xen Storage Daemon, version %d.%d"
- Define.xenstored_major Define.xenstored_minor;
-
let spec_fds =
(match rw_sock with None -> [] | Some x -> [ x ]) @
(match ro_sock with None -> [] | Some x -> [ x ]) @

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel