IPTraf has a few optional command-line parameters. As with most UNIX commands, IPTraf command-line parameters are case-sensitive (-l is NOT the same as -L).
The following command-line parameters can be supplied to the iptraf command:
causes the IP traffic monitor to start immediately on the specified interface. If -i all is specified, all interfaces are monitored.
starts the general interface statistics
shows detailed statistics for the specified interface
starts the TCP/UDP traffic monitor for the specified interface
starts the packet size breakdown for the specified interface
starts the LAN station monitor on the specified interface. If -l all is specified, all LAN interfaces are monitored.
The -t parameter, when used with one of the other parameters that specify a facility to start, tells IPTraf to run the indicated facility for only timeout minutes, after which the facility exits. The -t parameter is ignored in menu mode.
If this parameter is not specified, the facility runs until the exit keystroke is pressed.
Redirects all terminal output to the "bit bucket" /dev/null, closes standard input, and places the program in the background. This parameter can be used only with one of the -i, -g, -d, -s, -z, or -l parameters. See Background Operation in Chapter 9. -B is ignored in menu mode.
Allows you to specify an alternate log file name when the any facility is directly started from the command line, whether in foreground or background mode. If specified in foreground mode, the log filename prompt is bypassed, even when logging is turned on in the Configure... menu. If this parameter is omitted in background mode, the default log filename is used.
This parameter always turns on logging.
If an absolute path is not specified, the log file will be created in the default log file directory
Sets the logging interval (in minutes) when the -L parameter is used. This overrides the Log interval... setting in the Configure... menu. If omitted, the configured value is used. This parameter is ignored when the -L parameter is omitted and logging is disabled.
The value specified here will affect all facilities except for the IP traffic monitor.
Previously used to suppress the warning screen when IPTraf is run on kernels with IP masquerading. Since the masquerading code now processes packets in a way better suited to raw capture, this parameter is no longer needed and is retained only for compatibility.
Forces IPTraf to clear all lock files and reset all instance counters to zero before running any facilities. IPTraf will then think it's the first instance of itself.
The -f parameter overrides the existing locks and counters imposed by the IPTraf process and by the various facilities, causing this instance to think it is the first and that there are no other facilities running. Use this parameter with great caution. A common use for this parameter is to recover from abrupt or abnormal terminations which may leave stale locks and counters still lying around.
The -f parameter may be used together with the others.
displays a short help screen
While the command-line options are case-sensitive, interactive keystroke at the IPTraf full-screen interface are not.