[SSSD] RFC: Improving the debug messages

Jakub Hrozek jhrozek at redhat.com
Tue Jun 30 12:07:24 UTC 2015


On Tue, Jun 30, 2015 at 07:58:45AM -0400, Stephen Gallagher wrote:
> On Tue, 2015-06-30 at 12:04 +0200, Jakub Hrozek wrote:
> > On Tue, Jun 30, 2015 at 10:30:16AM +0200, Jan Pazdziora wrote:
> > > > - Running sssd in environment where all actions complete 
> > > > successfully
> > > >   should emit no debug messages. Default log level should be 
> > > > moved to
> > > >   SSSDBG_OP_FAILURE or CRIT_FAILURE. (This basically amounts to 
> > > > checking
> > > >   all OP, FATAL and CRIT failure messages..)
> > > > 
> > > >   The reason is that sometimes sssd fails, but because logging is
> > > >   totally silent, we don't know what happened at all. Currently 
> > > > we have
> > > >   a couple of small bugs where we might print a loud DEBUG 
> > > > message just
> > > >   because we search for an entry which is not there etc.
> > > 
> > > It'd be great if the default option was to emit one error message 
> > > per
> > > failure (per operation, where operation should be defined from 
> > > user's
> > > point of view, not developer's point of view) and no message for
> > > success. The next level would be to have one error message per 
> > > failure
> > > and one message per success, so that it's easy to observe what is
> > > going on without getting into too much detail.
> > 
> > What someone (sorry, I already forgot who :-/) also suggested during 
> > a
> > discussion was to add a new log level for start and end of an 
> > operation.
> 
> 
> The other thing we might want to be doing is looking at some of the
> more advanced journald logging capabilities. For example, if you look
> at the Cockpit and realmd projects, they have implemented a mechanism
> to use journald tagging to easily identify activities being performed
> by specific clients. We should do the same, so it's possible to limit
> our view of the journal to just the actions we're interested in (which
> will make life easier on a busy server)

Yes, I already looked at realmd and I really liked what I see. It would
be indeed easy to add tagging for the top-level request, but because of
the async nature of SSSD, we would have to pass the tag into the nested
requests..

btw I was also thinking if this would be something useful to add to tevent,
so each tevent request would have an ID, maybe something that would allow
to identify the parents as well. Like:
    parent - 0x0000AA
        subreq1 - 0x00BBAA
        subreq2 - 0x00BCAA
            subsubreq - 0xDDBCAA



More information about the sssd-devel mailing list