GNOME Bugzilla – Bug 756175
[review] add logging level "KEEP" and clear platform sysctl logging cache [th/logging-keep-bgo756175]
Last modified: 2015-10-09 13:00:03 UTC
please review
The idea sounds good, but this behavior is unexpected in my opinion: $ nmcli g l LEVEL DOMAINS INFO DNS,CORE $ nmcli g l level KEEP domains PPP:TRACE $ nmcli g l LEVEL DOMAINS INFO PPP:TRACE,DNS,CORE $ nmcli g l level ERR $ nmcli g l LEVEL DOMAINS ERR PPP:TRACE Shouldn't the result be the like this? LEVEL DOMAINS ERR PPP,DNS,CORE Maybe global.log_domains should be rebuilt when the global KEEP level is set.
(In reply to Beniamino Galvani from comment #1) > The idea sounds good, but this behavior is unexpected in my opinion: > > $ nmcli g l > LEVEL DOMAINS > INFO DNS,CORE > $ nmcli g l level KEEP domains PPP:TRACE > $ nmcli g l > LEVEL DOMAINS > INFO PPP:TRACE,DNS,CORE > $ nmcli g l level ERR > $ nmcli g l > LEVEL DOMAINS > ERR PPP:TRACE > > Shouldn't the result be the like this? > > LEVEL DOMAINS > ERR PPP,DNS,CORE > > Maybe global.log_domains should be rebuilt when the global KEEP level > is set. What exactly is unexpected there? When you did: nmcli g l level ERR without specifying the domains, it would do: »···if (!domains || !*domains) »···»···domains = global.log_domains ? global.log_domains : "DEFAULT"; Thus, in the previous command you set: global.log_domains = "PPP:TRACE" and you end up with what you see. That isn't at all related to the KEEP option and already present behavior. But I agree, it's unexpected...
(In reply to Thomas Haller from comment #2) > (In reply to Beniamino Galvani from comment #1) > That isn't at all related to the KEEP option and already present behavior. > But I agree, it's unexpected... OK, before the KEEP option this issue was not possible. Pushed a new commit to fix this. How is it now?
(In reply to Thomas Haller from comment #3) > Pushed a new commit to fix this. > > How is it now? Branch looks ok to me now. Pushed a couple of trivial fixes.
(In reply to Beniamino Galvani from comment #4) > (In reply to Thomas Haller from comment #3) > > Pushed a new commit to fix this. > > > > How is it now? > > Branch looks ok to me now. Pushed a couple of trivial fixes. Thanks Merged to master: http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=c71c301c3b34092d8bdac3cec11f85c4fc737143