<br><br><div class="gmail_quote">2009/7/10 Arjen de Korte <span dir="ltr">&lt;<a href="mailto:nut%2Bdevel@de-korte.org">nut+devel@de-korte.org</a>&gt;</span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">Citeren Charles Lepple &lt;<a href="mailto:clepple@gmail.com" target="_blank">clepple@gmail.com</a>&gt;:<br>
<br>
</div><div class="im"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

In most cases, I&#39;d welcome more debugging output, especially in the case of<br>
USB drivers. But in that case, I would rather see this logged at loglevel<br>
LOG_DEBUG, to prevent flooding the syslog with messages. The LOG_ERR level<br>
is fairly high and on many systems these messages will be logged to the<br>
syslog.<br>
</blockquote>
To me, the log level is orthogonal to the message printed at a given log level.<br>
</blockquote>
<br></div>
I have no idea what ortogonal means here (sorry, English is not my native language). What I meant to say is, when configuring syslog usually it will log message from a specified level and higher. which messages to log and it will log all messages with that level and higher. Since LOG_ERR is ranked quite high, this might mean that if for some unfortunate reason usb_clear_halt() is called often, this will show up each time.<br>

<br>
In this particular case, I don&#39;t think the ordinary sysadmin has any means to resolve this problem and since we&#39;ve had quite some complaints about NUT &#39;spamming&#39; the syslog before, I&#39;d rather see things like this being logged at LOG_DEBUG (which is rarely used in a production environment and only then if there is a problem to be debugged).<div class="im">
<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
If you have no objections to the message, I will add usb_strerror().<br>
</blockquote>
<br></div>
Please do.<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
If you would like me to change the log level at the same time, I can<br>
do that, but I don&#39;t have a strong opinion on that (probably because I<br>
haven&#39;t had my syslog flooded recently).<br>
</blockquote>
<br></div>
Neither have I, but see above. We should be conservative about what to write to the syslog.</blockquote><div><br>I second Arjen&#39;s position here: I still have at least 2 Debian bugs related to NUT (USB layer) spamming the syslog (though iirc related to the kernel itself). Switching to LOG_DEBUG would ensure that we don&#39;t spam when it&#39;s not &quot;desired&quot;. Moreover, in such case (all the current LOG_ERR in nut_usb.c are related to low level USB), there is nothing much we can do apart from asking for a debug session.<br>
<br>and I&#39;m all for adding the usb_strrerror() calls too.<br><br>Arnaud<br></div></div>-- <br>Linux / Unix Expert R&amp;D - Eaton - <a href="http://www.eaton.com/mgeops">http://www.eaton.com/mgeops</a><br>Network UPS Tools (NUT) Project Leader - <a href="http://www.networkupstools.org/">http://www.networkupstools.org/</a><br>
Debian Developer - <a href="http://www.debian.org">http://www.debian.org</a><br>Free Software Developer - <a href="http://arnaud.quette.free.fr/">http://arnaud.quette.free.fr/</a><br><br>