lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 1 | .TH RTMON 8 |
| 2 | .SH NAME |
| 3 | rtmon \- listens to and monitors RTnetlink |
| 4 | .SH SYNOPSIS |
| 5 | .B rtmon |
| 6 | .RI "[ options ] file FILE [ all | LISTofOBJECTS ]" |
| 7 | .SH DESCRIPTION |
| 8 | This manual page documents briefly the |
| 9 | .B rtmon |
| 10 | command. |
| 11 | .PP |
| 12 | .B rtmon |
| 13 | listens on |
| 14 | .I netlink |
| 15 | socket and monitors routing table changes. |
| 16 | |
| 17 | .I rtmon |
| 18 | can be started before the first network configuration command is issued. |
| 19 | For example if you insert: |
| 20 | |
| 21 | .B rtmon file /var/log/rtmon.log |
| 22 | |
| 23 | in a startup script, you will be able to view the full history later. |
| 24 | Certainly, it is possible to start rtmon at any time. It prepends the history with the state snapshot dumped at the moment of starting. |
| 25 | |
| 26 | .SH OPTIONS |
| 27 | .I rtmon supports the following options: |
| 28 | .TP |
| 29 | .B \-Version |
| 30 | Print version and exit. |
| 31 | .TP |
| 32 | .B help |
| 33 | Show summary of options. |
| 34 | .TP |
| 35 | .B file FILE [ all | LISTofOBJECTS ] |
| 36 | Log output to FILE. LISTofOBJECTS is the list of object types that we |
| 37 | want to monitor. It may contain 'link', 'address', 'route' |
| 38 | and 'all'. 'link' specifies the network device, 'address' the protocol |
| 39 | (IP or IPv6) address on a device, 'route' the routing table entry |
| 40 | and 'all' does what the name says. |
| 41 | .TP |
| 42 | .B \-family [ inet | inet6 | link | help ] |
| 43 | Specify protocol family. 'inet' is IPv4, 'inet6' is IPv6, 'link' |
| 44 | means that no networking protocol is involved and 'help' prints usage information. |
| 45 | .TP |
| 46 | .B \-4 |
| 47 | Use IPv4. Shortcut for -family inet. |
| 48 | .TP |
| 49 | .B \-6 |
| 50 | Use IPv6. Shortcut for -family inet6. |
| 51 | .TP |
| 52 | .B \-0 |
| 53 | Use a special family identifier meaning that no networking protocol is involved. Shortcut for -family link. |
| 54 | .SH USAGE EXAMPLES |
| 55 | .TP |
| 56 | .B # rtmon file /var/log/rtmon.log |
| 57 | Log to file /var/log/rtmon.log, then run: |
| 58 | .TP |
| 59 | .B # ip monitor file /var/log/rtmon.log |
| 60 | to display logged output from file. |
| 61 | .SH SEE ALSO |
| 62 | .BR ip (8) |
| 63 | .SH AUTHOR |
| 64 | .B rtmon |
| 65 | was written by Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>. |
| 66 | .PP |
| 67 | This manual page was written by Michael Prokop <mika@grml.org>, |
| 68 | for the Debian project (but may be used by others). |