diff options
author | Jakub Hrozek <jhrozek@redhat.com> | 2009-09-25 13:20:13 +0200 |
---|---|---|
committer | Stephen Gallagher <sgallagh@redhat.com> | 2009-09-25 10:19:56 -0400 |
commit | 05315b44feaa9819e62f18477f2c6d20914eb7ce (patch) | |
tree | 82e28792e306de9e461ea9dde5203d6a3a9de7fa /server/providers | |
parent | 6cec00b7fe2aed71b8df21d2a0d97df8b448cc85 (diff) | |
download | sssd-05315b44feaa9819e62f18477f2c6d20914eb7ce.tar.gz sssd-05315b44feaa9819e62f18477f2c6d20914eb7ce.tar.bz2 sssd-05315b44feaa9819e62f18477f2c6d20914eb7ce.zip |
Send debug messages to logfile
Introduces a new option --debug-to-files which makes SSSD output its
debug information to a file instead of stderr, which is still the
default.
Also introduces a new confdb option debug_to_files which does the same,
but can be specified per-service in the config file.
The logfiles are stored in /var/log/sssd by default.
Changes the initscript to log to files by default.
Diffstat (limited to 'server/providers')
-rw-r--r-- | server/providers/data_provider.c | 4 | ||||
-rw-r--r-- | server/providers/data_provider_be.c | 4 |
2 files changed, 7 insertions, 1 deletions
diff --git a/server/providers/data_provider.c b/server/providers/data_provider.c index f727c555..0838cd02 100644 --- a/server/providers/data_provider.c +++ b/server/providers/data_provider.c @@ -992,7 +992,9 @@ int main(int argc, const char *argv[]) poptFreeContext(pc); - /* set up things like debug , signals, daemonization, etc... */ + /* set up things like debug, signals, daemonization, etc... */ + debug_log_file = "sssd_dp"; + ret = server_setup("sssd[dp]", 0, CONFDB_DP_CONF_ENTRY, &main_ctx); if (ret != EOK) return 2; diff --git a/server/providers/data_provider_be.c b/server/providers/data_provider_be.c index 62ce7bbe..29d6fa0e 100644 --- a/server/providers/data_provider_be.c +++ b/server/providers/data_provider_be.c @@ -947,7 +947,11 @@ int main(int argc, const char *argv[]) poptFreeContext(pc); + /* set up things like debug , signals, daemonization, etc... */ + debug_log_file = talloc_asprintf(NULL, "sssd_%s", be_domain); + if (!debug_log_file) return 2; + srv_name = talloc_asprintf(NULL, "sssd[be[%s]]", be_domain); if (!srv_name) return 2; |