summaryrefslogtreecommitdiffstats
path: root/glusterfsd/src
diff options
context:
space:
mode:
Diffstat (limited to 'glusterfsd/src')
-rw-r--r--glusterfsd/src/glusterfsd.c8
-rw-r--r--glusterfsd/src/glusterfsd.h1
2 files changed, 9 insertions, 0 deletions
diff --git a/glusterfsd/src/glusterfsd.c b/glusterfsd/src/glusterfsd.c
index 204c617be6c..ebf58706107 100644
--- a/glusterfsd/src/glusterfsd.c
+++ b/glusterfsd/src/glusterfsd.c
@@ -240,6 +240,8 @@ static struct argp_option gf_options[] = {
" [default: \"yes\"]"},
{"secure-mgmt", ARGP_SECURE_MGMT_KEY, "BOOL", OPTION_ARG_OPTIONAL,
"Override default for secure (SSL) management connections"},
+ {"localtime-logging", ARGP_LOCALTIME_LOGGING_KEY, 0, 0,
+ "Enable localtime logging"},
{0, 0, 0, 0, "Miscellaneous Options:"},
{0, }
};
@@ -1271,6 +1273,10 @@ no_oom_api:
argp_failure (state, -1, 0,
"unknown secure-mgmt setting \"%s\"", arg);
break;
+
+ case ARGP_LOCALTIME_LOGGING_KEY:
+ cmd_args->localtime_logging = 1;
+ break;
}
return 0;
@@ -1635,6 +1641,8 @@ logging_init (glusterfs_ctx_t *ctx, const char *progpath)
/* finish log set parameters before init */
gf_log_set_loglevel (cmd_args->log_level);
+ gf_log_set_localtime (cmd_args->localtime_logging);
+
gf_log_set_logger (cmd_args->logger);
gf_log_set_logformat (cmd_args->log_format);
diff --git a/glusterfsd/src/glusterfsd.h b/glusterfsd/src/glusterfsd.h
index 3461d6d01f0..c1d5dc08405 100644
--- a/glusterfsd/src/glusterfsd.h
+++ b/glusterfsd/src/glusterfsd.h
@@ -96,6 +96,7 @@ enum argp_option_keys {
#ifdef GF_LINUX_HOST_OS
ARGP_OOM_SCORE_ADJ_KEY = 176,
#endif
+ ARGP_LOCALTIME_LOGGING_KEY = 177,
};
struct _gfd_vol_top_priv {