On (28/10/15 09:03), Stephen Gallagher wrote:
On 10/27/2015 05:33 PM, Lukas Slebodnik wrote:
> On (27/10/15 09:48), Stephen Gallagher wrote:
>> We get an error message if we start up SSSD and the debug log
>> does not yet exist.
>
>> From 53592734f73c50029fa573b9bc070437304ea489 Mon Sep 17 00:00:00
>> 2001 From: Stephen Gallagher <sgallagh(a)redhat.com> Date: Tue, 27
>> Oct 2015 09:39:01 -0400 Subject: [PATCH] DEBUG: Don't error on
>> chown of nonexistent file
>>
>> We get an error message if we start up SSSD and the debug log
>> does not yet exist. --- src/util/debug.c | 9 ++++++--- 1 file
>> changed, 6 insertions(+), 3 deletions(-)
>>
>> diff --git a/src/util/debug.c b/src/util/debug.c index
>> a8eea32740155ec3daf6be71ef9a8af6592f74a9..729d9f99d35c7208950a9a1af1f
df3942b23a147
>> 100644 --- a/src/util/debug.c +++ b/src/util/debug.c @@ -331,13
>> +331,16 @@ int chown_debug_file(const char *filename,
>>
>> ret = chown(logpath, uid, gid); free(logpath); if (ret != 0) {
>> ret = errno; - DEBUG(SSSDBG_FATAL_FAILURE, "chown
>> failed for [%s]: [%d]\n", - log_file, ret); -
>> return ret; + if (ret != ENOENT) { + /*
>> Don't write an error message for a nonexistent file */ +
>> DEBUG(SSSDBG_FATAL_FAILURE, "chown failed for [%s]: [%d]\n", +
>> log_file, ret); + return ret; + }
> Patch make sense, But I cannot see an error message even with empty
> directory /var/log/sssd. Do you have an idea why?
>
Start the sssd in interactive mode instead of sending to files and it
will become clear :)
I'm sorry but it is not clear :-)
[root@host ~]# rm -f /var/log/sssd/* /var/lib/sss/{db,mc}/*
[root@host ~]# sssd -i -d 3
(Wed Oct 28 21:43:57 2015) [sssd[be[redhat.com]]] [sysdb_idmap_get_mappings]
(0x0080): Could not locate ID mappings: [No such file or directory]
(Wed Oct 28 21:43:57 2015) [sssd[be[redhat.com]]] [be_process_init] (0x0080):
No SUDO module provided for [
redhat.com] !!
(Wed Oct 28 21:43:57 2015) [sssd[be[redhat.com]]] [be_process_init] (0x0020):
No selinux module provided for [
redhat.com] !!
(Wed Oct 28 21:43:57 2015) [sssd[be[redhat.com]]] [be_process_init] (0x0020):
No host info module provided for [
redhat.com] !!
(Wed Oct 28 21:43:57 2015) [sssd[be[redhat.com]]] [be_process_init] (0x0020):
Subdomains are not supported for [
redhat.com] !!
(Wed Oct 28 21:44:27 2015) [sssd[be[redhat.com]]] [be_run_online_cb] (0x0080):
Going online. Running callbacks.
I think it was fixed in ticket or did I miss something?
https://fedorahosted.org/sssd/ticket/2493
LS