From 79e7872530c4dcdfcfccc5ca6ce7b08a3e1cafb0 Mon Sep 17 00:00:00 2001 From: Laine Stump Date: Mon, 21 Dec 2015 10:53:57 -0500 Subject: [PATCH] docs: update to properly reflect meaning of fields in log filter The documentation (and comment in libvirtd.conf) says that the text in a log filter is compared to the "source file name", and gives the example of "util/json", but this is not correct (at least not since commit 2835c1e, possibly earlier). It is instead compared to the string given in the VIR_LOG_INIT() macro invocation at the top of each source file, which is always "similar to but not the same as" the source file name (in the example above, the proper name is "util.json", while the file name is "util/virjson.c"). This patch corrects the misstatement in both the documentation and in libvirtd.conf. --- daemon/libvirtd.conf | 14 ++++++++++---- docs/logging.html.in | 15 +++++++++------ 2 files changed, 19 insertions(+), 10 deletions(-) diff --git a/daemon/libvirtd.conf b/daemon/libvirtd.conf index 514e6e4813..5485f98539 100644 --- a/daemon/libvirtd.conf +++ b/daemon/libvirtd.conf @@ -344,10 +344,16 @@ # The format for a filter is one of: # x:name # x:+name -# where name is a string which is matched against source file name, -# e.g., "remote", "qemu", or "util/json", the optional "+" prefix -# tells libvirt to log stack trace for each message matching name, -# and x is the minimal level where matching messages should be logged: + +# where name is a string which is matched against the category +# given in the VIR_LOG_INIT() at the top of each libvirt source +# file, e.g., "remote", "qemu", or "util.json" (the name in the +# filter can be a substring of the full category name, in order +# to match multiple similar categories), the optional "+" prefix +# tells libvirt to log stack trace for each message matching +# name, and x is the minimal level where matching messages should +# be logged: + # 1: DEBUG # 2: INFO # 3: WARNING diff --git a/docs/logging.html.in b/docs/logging.html.in index d8d8f1e899..b6dc91cd58 100644 --- a/docs/logging.html.in +++ b/docs/logging.html.in @@ -104,12 +104,15 @@
   x:name  (log message only)
   x:+name (log message + stack trace)
-

where name is a string which is matched against source - file name, e.g., remote, qemu, or - util/json, the optional + prefix tells libvirt - to log stack trace for each message matching name, and - x is the minimal level where matching messages should - be logged:

+

where name is a string which is matched against + the category given in the VIR_LOG_INIT() at the top of each + libvirt source file, e.g., remote, qemu, + or util.json (the name in the filter can be a + substring of the full category name, in order to match multiple + similar categories), the optional + prefix tells + libvirt to log stack trace for each message + matching name, and x is the minimal + level where matching messages should be logged: