Trace statements control tracing options. GateD's tracing options may be configured at many levels. Tracing options include the file specifications, control options, and global and protocol specific tracing options. Unless overridden, tracing options from the next higher level are inherited by lower levels. For example, BGP peer tracing options are inherited from BGP group tracing options, which are inherited from global BGP tracing options, which are inherited from global GateD tracing options. At each level tracing specifications override the inherited options.
traceoptions [" trace_file" [ replace] [ size size [ k| m] files files]]
[ control_options] trace_options [ except trace_options] ;
traceoptions none;
There are two types of global options (or trace_options in the previous syntax description), those which only affect global operations and those which have potential significance to protocols.
The trace flags that only have global significance are:
The options flags that have potential significance to protocols are:
Not all of the above options apply to all of the protocols. In some cases their use does not make sense (for instance, RIP does not have a state machine) and in some instances the requested tracing has not been implemented (such as RIP support of the policy option).
It is not currently possible to specify packet tracing from the command line. This is because a global option for packet tracing would potentially create too much output.
When protocols inherit their tracing options from the global tracing options, tracing levels that don't make sense (such as parse, adv and packet tracing options) are masked out.
Global tracing statements have an immediate effect, especially parsing options that effect the parsing of the configuration file. Tracing values inherited by protocols specified in the configuration file are initially inherited from the global options in effect as they are parsed, unless they are overridden by more specific options. After the configuration file is read, tracing options that were not explicitly specified are inherited from the global options in effect at the end of the configuration file.
Tracing of packets is very flexible. For any given protocol there are one or more options for tracing packets. All protocols allow use of the packets keyword allows for tracing all packets sent and received by the protocol. most protocols have other options for limiting tracing to a useful subset of packet types. These tracing options can be further controlled with the following modifiers:
Detail, if specified, must be before send or recv. If a protocol allows for several different types of packet tracing, modifiers may be applied to each individual type. But be aware that within one tracing specification the trace flags are summed up, so specifying detail packets will turn on full tracing for all packets.