On 18 October 2017 at 15:15, D. Hugh Redelmeier <[email protected]> wrote:
> | From: Andrew Cagney <[email protected]> > > | I'm wondering if debug output should be prefixed with the > connection/state > | information as in: > | > | | "westnet-eastnet" #1: ..... > | > | for our our tests it doesn't matter, but in the field when there are lots > | of connections, being able to grep for this string makes things easier > > The original theory was: > > 1. Debug lines are for the developers. If the users need them, that > itself is a bug. > > Good theory .... However, we also need to be able to enable find-grained tracing of specific sub-systems on large servers. To be specific, --debug xauth to see how we interact with the xauth server (the reality is that our debug options are so useless that this isn't possible, instead --debug all rules the day). 2. Debug lines are not stand-alone, they have a context. All state > switches appear as debug lines > > Except when threads and sub-processes interleave their [debug] log lines! grep '#NNN' is a lot easier to explain and understand 3. (non-debug) log lines can be interleaved since an arbitrary number > of negotiations can be going on simultaneously > > 4. debug lines are not interleaved: switching of attention happens > rarely and is noted. > > See above, this assumption isn't true. For the grep problem, just grep for the thing of interest AND for > focus shifts. > > I think that is too complex (short of also including a script to do it, and needing the script is too complex). Debug lines are long, noisy, and expensive already. Adding a prefix might > well make this noticeably worse. > > Andrew
_______________________________________________ Swan-dev mailing list [email protected] https://lists.libreswan.org/mailman/listinfo/swan-dev
