[asterisk-dev] [Code Review]: Separate verbose level for logging
Tzafrir Cohen
tzafrir.cohen at xorcom.com
Tue Nov 29 03:17:41 CST 2011
On Mon, Nov 28, 2011 at 04:24:56PM -0000, Tilghman Lesher wrote:
> Most people, when they start Asterisk for ad-hoc testing, simply hold
> down the v key for a brief period. That rarely means that verbosity
> is consistent, runtime-to-runtime. Could be 5 or 7 or 16 or 22. We
> could inherit from whatever option_verbose is set to at the time. My
> issue with that, though, is that the verbosity level can be changed
> during runtime and a 'logger reload' would thus change the logger
> verbosity level, which most people would consider unexpected behavior.
>
> Thus, I think 3 is an acceptable default.
Regarding the current defaults, I'll just point out to the following
code in contrib/scripts/safe_asterisk:
TTY=9
CONSOLE=yes
# ... (No sourcing of any config file in between)
if test "x$TTY" != "x" ; then
if test -c /dev/tty${TTY} ; then
TTY=tty${TTY}
elif test -c /dev/vc/${TTY} ; then
TTY=vc/${TTY}
else
message "Cannot find specified TTY (${TTY})"
exit 1
fi
ASTARGS="${ASTARGS} -vvvg"
if test "x$CONSOLE" != "xno" ; then
ASTARGS="${ASTARGS} -c"
fi
fi
So if you use safe_asterisk and you don't manually patch a non-config
file (that will get verriden on net 'make install'), you get verbosity
level 3.
Which is why some distributions have gotten in to the odd habit of not
including a 'console' entry in their default lopgger.conf .
--
Tzafrir Cohen
icq#16849755 jabber:tzafrir.cohen at xorcom.com
+972-50-7952406 mailto:tzafrir.cohen at xorcom.com
http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir
More information about the asterisk-dev
mailing list