Author: marek
Date: 2010-01-07 06:19:03 +0100 (Thu, 07 Jan 2010)
New Revision: 1533
Modified:
trunk/batctl/man/batctl.8
Log:
batctl: manpage rework
General rework of the manpage to reflext the latest batctl changes
and fix numerous typos.
Signed-off-by: Andrew Lunn <andrew(a)lunn.ch>
Modified: trunk/batctl/man/batctl.8
===================================================================
--- trunk/batctl/man/batctl.8 2010-01-02 20:09:47 UTC (rev 1532)
+++ trunk/batctl/man/batctl.8 2010-01-07 05:19:03 UTC (rev 1533)
@@ -2,7 +2,7 @@
.\" First parameter, NAME, should be all caps
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
.\" other parameters are allowed: see man(7), man(1)
-.TH batctl 8 "Aug 01, 2009"
+.TH "BATCTL" "8" "Jan 04, 2010" "Linux"
"B.A.T.M.A.N. Advanced Control Tool"
.\" Please adjust this date whenever revising the manpage.
.\"
.\" Some roff macros, for reference:
@@ -19,85 +19,164 @@
.\" Process this file with
.\" groff -man batctl.8 -Tutf8
.\" --------------------------------------------------------------------------
-.TH "batctl" 8
+.ad l
.SH NAME
-batctl \- B.A.T.M.A.N. advanced control and managing tool
+batctl \- B.A.T.M.A.N. advanced control and management tool
.SH SYNOPSIS
.B batctl
.I [\fIbatctl\-options\fP]\ \fIcommand\fP\ [\fIcommand\-options\fP]
.br
.SH DESCRIPTION
-B.A.T.M.A.N. advanced operates on layer 2 and thus all hosts participating in the virtual
switch are completely transparent for all protocols above layer 2. Therefore the common
diagnosis tools do not work as expected. To overcome these problems \fBbatctl\fP was
created. At the moment the batctl contains \fBping\fP, \fBtraceroute\fP, \fBtcpdump\fP
interfaces to the kernel module settings.
+batctl offers a convenient way to configure the batman\-adv kernel
+module as well as displaying debug information such as originator
+tables, translation tables and the debug log. In combination with a
+bat\-hosts file batctl allows the use of host names instead of MAC
+addresses.
.PP
-batctl uses the /dev/batman\-adv device provided by the B.A.T.M.A.N. advanced kernel
module to inject custom icmp packets into the data flow. That's why ping and
traceroute work almost like their IP based counterparts. Tcpdump analyzes the traffic and
packet types used by B.A.T.M.A.N. advanced.
+B.A.T.M.A.N. advanced operates on layer 2. Thus all hosts
+participating in the virtual switched network are transparently
+connected together for all protocols above layer 2. Therefore the
+common diagnosis tools do not work as expected. To overcome these
+problems batctl contains the commands \fBping\fP, \fBtraceroute\fP,
+\fBtcpdump\fP which provide similar functionality to the normal
+\fBping\fP(1), \fBtraceroute\fP(1), \fBtcpdump\fP(1) commands, but
+modified to layer 2 behaviour or using the B.A.T.M.A.N. advanced
+protocol.
.PP
-Furthermore batctl offers an convenient way to configure the batman\-adv kernel module as
well as displaying debug information such as originator tables, translation tables and
debug log. In combination with a bat\-hosts file batctl allows working with easy to
remember names instead of mac addresses.
.PP
.SH OPTIONS
.TP
.I \fBbatctl\-options:
-\-h print general batctl help
+\-h print general batctl help
.br
-\-v print batctl version
+\-v print batctl version
.br
.TP
.I \fBcommands:
-.IP "\fBinterface|if [none|interface]\fP"
-If no parameter is given the current interface settings are displayed otherwise the
parameter(s) are added as new interfaces. Use the "none" keyword to deactivate
all interfaces.
+.IP "\fBinterface\fP|\fBif\fP [\fBnone\fP|\fIinterface\fP]"
+If no parameter is given the current interface settings are displayed
+otherwise the parameter(s) are added as new interfaces. Use the "none"
+keyword to deactivate all interfaces.
.br
-.IP "\fBoriginators|o\fP"
-Once started batctl will refresh the displayed originator table every second. Use the
"\-b" option to let batctl display the table only once (useful for scripts). If
"\-n" was given batctl will not replace the mac addresses with bat\-host names
in the output.
+.IP "\fBoriginators\fP|\fBo\fP [\fB\-b\fP][\fB\-n\fP]"
+Display the originator table. Once started batctl will refresh the
+displayed originator table every second. The "\-b" option causes the
+table to be displayed only once (useful for scripts). If "\-n" is
+given batctl will not replace the MAC addresses with bat\-host names
+in the output.
.br
-.IP "\fBinterval|it [orig_interval]\fP"
-If no parameter is given the current originator interval settings are displayed otherwise
the parameter is used to set the originator interval.
+.IP "\fBinterval\fP|\fBit\fP [\fIorig_interval\fP]"
+If no parameter is given the current originator interval setting is
+displayed otherwise the parameter is used to set the originator
+interval. The interval is in units of milliseconds.
.br
-.IP "\fBloglevel|ll [level]\fP"
-If no parameter is given the current log level settings are displayed otherwise the
parameter is used to set the log level.
+.IP "\fBloglevel\fP|\fBll\fP [\fIlevel\fP]"
+If no parameter is given the current log level settings are displayed
+otherwise the parameter is used to set the log level. Level 0 disables
+all logging. Level 1 enables messages related to routing / flooding /
+broadcasting. Level 2 enables messages related to route or hna added /
+changed / deleted. Level 3 enables all messages. The messages are sent
+to the kernel log. Use \fBdmesg\fP(1) to see them.
.br
-.IP "\fBlog|l\fP "
-Once started batctl will continuously read the log produced by the kernel module (the
amount of log message can be influenced by modifying the log level). Whenever there are
new log messages sent by the kernel batctl will display it. Use the "\-b" option
to let batctl exit after the existing log buffer has been displayed. If "\-n"
was given batctl will not replace the mac addresses with bat\-host names in the output.
+.IP "\fBlog\fP|\fBl\fP [\fIlogfile\fP][\fB\-b\fP][\fB\-n\fP]\fP"
+batctl will read the file logfile, or stdin if the logfile parameter
+is not given, applying filtering so only the B.A.T.M.A.N. Advanced
+messages are displayed. Whenever there are new log messages appended
+to the file batctl will display them. The option "\-b" causes batctl
+to exit once the end of the file has been reached. If "\-n" is given
+batctl will not replace the MAC addresses with bat\-host names in the
+output.
.br
-.IP "\fBtranslocal|tl\fP"
-Once started batctl will refresh the displayed local translation table every second. Use
the "\-b" option to let batctl display the table only once (useful for scripts).
If "\-n" was given batctl will not replace the mac addresses with bat\-host
names in the output.
+.IP "\fBtranslocal\fP|\fBtl\fP [\fB\-b\fP][\fB\-n\fP]"
+Display the local translation table. batctl will refresh the
+displayed table every second. The "\-b" option causes the table to be
+displayed only once (useful for scripts). If "\-n" is given batctl
+will not replace the MAC addresses with bat\-host names in the output.
.br
-.IP "\fBtransglobal|tg\fP"
-Once started batctl will refresh the displayed global translation table every second. Use
the "\-b" option to let batctl display the table only once (useful for scripts).
If "\-n" was given batctl will not replace the mac addresses with bat\-host
names in the output.
+.IP "\fBtransglobal\fP|\fBtg\fP [\fB\-b\fP][\fB\-n\fP]"
+Display the global translation table. batctl will refresh the
+displayed table every second. The "\-b" option causes the table to be
+displayed only once (useful for scripts). If "\-n" is given batctl
+will not replace the MAC addresses with bat\-host names in the output.
.br
-.IP "\fBvis dot\fP"
-Display the visualisation data in graphviz dot(1) format. If
-"\--numbers" or "\-n" batctl will not replace the mac addresses with
-bat-host names in the output. With "\--no-HNA" or "\-h" the HNA
-entries are not displayed, so the pure mesh topology can be seen. With
-"\--no-2nd" or "\-2" a dot cluster is not formed around primary and
-secondary addresses from the same device.
+.IP "\fBvis dot\fP
[\fB\-n\fP|\fB\-\-numbers\fP][\fB\-h\fP|\fB\-\-no-HNA\fP][\fB\-2\fP|\fB\-\-no-2nd\fP]"
+Display the visualisation data in graphviz \fBdot\fP(1) format. If
+"\-\-numbers" or "\-n" is given batctl will not replace the MAC
+addresses with bat-host names in the output. With "\-\-no-HNA" or
+"\-h" the HNA entries are not displayed, so the pure mesh topology can
+be seen. With "\-\-no-2nd" or "\-2" a dot cluster is not formed
around
+primary and secondary addresses from the same device.
.br
-.IP "\fBvis json\fP"
-Display the visualisation data in JSON format. If
-"\--numbers" or "\-n" batctl will not replace the mac addresses with
-bat-host names in the output. With "\--no-HNA" or "\-h" the HNA
-entries are not displayed, so the pure mesh topology can be seen. With
-"\--no-2nd" or "\-2" a dot cluster is not formed around primary and
+.IP "\fBvis json\fP
[\fB\-n\fP|\fB\-\-numbers\fP][\fB\-h\fP|\fB\-\-no-HNA\fP][\fB\-2\fP|\fB\-\-no-2nd\fP]"
+Display the visualisation data in JSON format. If "\-\-numbers" or
+"\-n" is given batctl will not replace the MAC addresses with bat-host
+names in the output. With "\-\-no-HNA" or "\-h" the HNA entries are
+not displayed, so the pure mesh topology can be seen. With
+"\-\-no-2nd" or "\-2" a dot cluster is not formed around primary and
secondary addresses from the same device.
.br
-.IP "\fBaggregation|ag [0|1]\fP"
-If no parameter is given the current aggregation settings are displayed otherwise the
parameter is used to enable or disable the packet aggregation.
+.IP "\fBaggregation\fP|\fBag\fP [\fB1\fP|\fB0\fP]"
+If no parameter is given the current aggregation setting is displayed.
+Otherwise the parameter is used to enable or disable packet
+aggregation.
.br
-.IP "\fBping|p mac\ address|bat\-host\ name\fP"
-Layer 2 ping mac address or bat\-host name (batctl will try to find bat\-host name if the
given parameter was not a mac address) until batctl has been stopped with CTRL + C. The
"\-c" option tells batctl how often it should ping the given host before it
stops by itself. With "\-i" and "\-t" you can influence the default
interval time between pings and the timeout time for replies respectively.
+.IP "\fBping\fP|\fBp\fP [\fB\-c \fP\fIcount\fP][\fB\-i \fP\fIinterval\fP][\fB\-t
\fP\fItime\fP] \fIMAC_address\fP|\fIbat\-host_name\fP"
+Layer 2 ping of a MAC address or bat\-host name. batctl will try to
+find the bat\-host name if the given parameter was not a MAC
+address. The "\-c" option tells batctl how man pings should be sent
+before the program exits. Without the "\-c" option batctl will continue
+pinging without end. Use CTRL + C to stop it. With "\-i" and "\-t"
+you can set the default interval between pings and the timeout time
+for replies, both in seconds.
.br
-.IP "\fBtraceroute|tr mac\ address|bat\-host\ name\fP"
-Layer 2 traceroute mac address or bat\-host name (batctl will try to find bat\-host name
if the given parameter was not a mac address). batctl will send 3 packets to each host and
display the response time. If "\-n" was given batctl will not replace the mac
addresses with bat\-host names in the output.
-.IP "\fBtcpdump|td interface [interface]\fP"
-Per default batctl will display all packets that were seen on the given interface(s). The
"\-p" options allows to filter certain packet types: 1 displays batman ogm
packets only, 2 displays batman icmp packets only, etc. These numbers can be added to
filter more than one packet type, e.g. use "\-p 3" to display batman ogm packets
and batman icmp packets only. If "\-n" was given batctl will not replace the mac
addresses with bat\-host names in the output.
+.IP "\fBtraceroute\fP|\fBtr\fP [\fB\-n\fP]
\fIMAC_address\fP|\fIbat\-host_name\fP"
+Layer 2 traceroute to a MAC address or bat\-host name. batctl will try
+to find the bat\-host name if the given parameter was not a MAC
+address. batctl will send 3 packets to each host and display the
+response time. If "\-n" is given batctl will not replace the MAC
+addresses with bat\-host names in the output.
.br
-.IP "\fBbisect logfile1 logfile2 .. logfileN\fP"
-Analyzes the logfiles to build a small internal database of all sent sequence numbers and
routing table changes. This database can be used to search for routing loops (default
action), to trace OGMs of a host (use "\-t" to specify the mac address or
bat\-host name) throughout the network or to display routing tables of the nodes (use
"\-r" to specify the mac address or bat\-host name). You can name a specific
sequence number or a range using the "\-s" option to limit the output's
range. Furthermore you can filter the output by specifying an originator (use
"\-o" to specify the mac address or bat\-host name) to only see data connected
to this originator. If "\-n" was given batctl will not replace the mac addresses
with bat\-host names in the output.
+.IP "\fBtcpdump\fP|\fBtd\fP [\fB\-p \fP\fIfilter\fP][\fB\-n\fP] \fIinterface
...\fP"
+batctl will display all packets that are seen on the given
+interface(s). The "\-p" options allows the filtering of certain packet
+types: 1 - batman ogm packets, 2 - batman icmp packets, 4 - unicast
+packets, 8 - broadcast packets, 16 - vis packets, and 32 - none batman
+packets. These numbers can be added to filter more than one packet
+type, e.g. use "\-p 3" to display batman ogm packets and batman icmp
+packets only. If "\-n" is given batctl will not replace the MAC
+addresses with bat\-host names in the output.
.br
+.IP "\fBbisect\fP [\fB\-l \fP\fIMAC\fP][\fB\-t \fP\fIMAC\fP][\fB\-r
\fP\fIMAC\fP][\fB\-s \fP\fImin\fP [\fB\- \fP\fImax\fP]][\fB\-o \fP\fIMAC\fP][\fB\-n\fP]
\fIlogfile1\fP [\fIlogfile2\fP ... \fIlogfileN\fP]"
+Analyses the logfiles to build a small internal database of all sent
+sequence numbers and routing table changes. This database can then be
+analyzed in a number of different ways. With "\-l" the database can be
+used to search for routing loops. Use "\-t" to trace OGMs of a host
+throughout the network. Use "\-r" to display routing tables of the
+nodes. The option "\-s" can be used to limit the output to a range of
+sequence numbers, between min and max, or to one specific sequence
+number, min. Furthermore using "\-o" you can filter the output to a
+specified originator. If "\-n" is given batctl will not replace the
+MAC addresses with bat\-host names in the output.
+.br
.SH FILES
.TP
.I "\fBbat-hosts\fP"
-This file is similar to the /etc/hosts file. You can write one mac address and one host
name per line. batctl will search for bat-hosts in /etc, your home directory and the
current directory. The found data is used to match mac address to your provided host name
or replace mac addresses in debug output and logs. Host names are much easier to remember
than mac addresses.
+This file is similar to the /etc/hosts file. You can write one MAC
+address and one host name per line. batctl will search for bat-hosts
+in /etc, your home directory and the current directory. The found data
+is used to match MAC address to your provided host name or replace MAC
+addresses in debug output and logs. Host names are much easier to
+remember than MAC addresses.
+.SH SEE ALSO
+.BR ping (1),
+.BR traceroute (1),
+.BR tcpdump (1),
+.BR dmesg (1),
+.BR dot (1)
.SH AUTHOR
-batctl was written by Andreas Langer <a.langer(a)q-dsl.de> and Marek Lindner
<lindner_marek(a)yahoo.de>de>.
+batctl was written by Andreas Langer <a.langer(a)q-dsl.de> and Marek
+Lindner <lindner_marek(a)yahoo.de>de>.
.PP
-This manual page was written by Simon Wunderlich <siwu(a)hrz.tu-chemnitz.de> and
Marek Lindner <lindner_marek(a)yahoo.de>de>.
+This manual page was written by Simon Wunderlich
+<siwu(a)hrz.tu-chemnitz.de>de>, Marek Lindner <lindner_marek(a)yahoo.de> and
+Andrew Lunn <andrew(a)lunn.ch>