aboutsummaryrefslogtreecommitdiff
path: root/qapi
diff options
context:
space:
mode:
authorPrasanna Kumar Kalever <prasanna.kalever@redhat.com>2016-07-22 20:26:48 +0530
committerJeff Cody <jcody@redhat.com>2016-09-13 01:34:47 -0400
commite9db8ff38e539260a2cb5a7918d1155b7d92a264 (patch)
tree6a27c80f4411bb1b5f7dca8439b37e97d1dfab32 /qapi
parent7263da78045dc91cc207f350911efe4259e99b3c (diff)
block/gluster: add support to choose libgfapi logfile
currently all the libgfapi logs defaults to '/dev/stderr' as it was hardcoded in a call to glfs logging api. When the debug level is chosen to DEBUG/TRACE, gfapi logs will be huge and fill/overflow the console view. This patch provides a commandline option to mention log file path which helps in logging to the specified file and also help in persisting the gfapi logs. Usage: ----- *URI Style: --------- -drive file=gluster://hostname/volname/image.qcow2,file.debug=9,\ file.logfile=/var/log/qemu/qemu-gfapi.log *JSON Style: ---------- 'json:{ "driver":"qcow2", "file":{ "driver":"gluster", "volume":"volname", "path":"image.qcow2", "debug":"9", "logfile":"/var/log/qemu/qemu-gfapi.log", "server":[ { "type":"tcp", "host":"1.2.3.4", "port":24007 }, { "type":"unix", "socket":"/var/run/glusterd.socket" } ] } }' Reviewed-by: Jeff Cody <jcody@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com> Signed-off-by: Jeff Cody <jcody@redhat.com>
Diffstat (limited to 'qapi')
-rw-r--r--qapi/block-core.json5
1 files changed, 4 insertions, 1 deletions
diff --git a/qapi/block-core.json b/qapi/block-core.json
index 31f9990754..59128f7f89 100644
--- a/qapi/block-core.json
+++ b/qapi/block-core.json
@@ -2154,13 +2154,16 @@
#
# @debug-level: #optional libgfapi log level (default '4' which is Error)
#
+# @logfile: #optional libgfapi log file (default /dev/stderr)
+#
# Since: 2.7
##
{ 'struct': 'BlockdevOptionsGluster',
'data': { 'volume': 'str',
'path': 'str',
'server': ['GlusterServer'],
- '*debug-level': 'int' } }
+ '*debug-level': 'int',
+ '*logfile': 'str' } }
##
# @BlockdevOptions