Commit 2ece61a4 authored by chris's avatar chris
Browse files


parent de65eda0
......@@ -4,7 +4,7 @@ $Id$
0.2 02/04/02
Added -n option to analyse traffic flows across a network boundary.
Added cummulative traffic totals.
Added cumulative traffic totals.
Graphs now optional.
UI more responsive to key presses.
Auto-sizing bar graph scale.
......@@ -11,7 +11,7 @@ iftop - display bandwidth usage on an interface by host
\fBiftop\fP \fB-h\fP |
[\fB-d\fP] [\fB-p\fP] [\fB-i\fP \fIinterface\fP] [\fB-f\fP \fIfilter code\fP] [\fB-n\fP \fInet\fP/\fImask\fP]
[\fB-dpb\fP] [\fB-i\fP \fIinterface\fP] [\fB-f\fP \fIfilter code\fP] [\fB-n\fP \fInet\fP/\fImask\fP]
\fBiftop\fP listens to network traffic on a named \fIinterface\fP, or \fBeth0\fP
......@@ -58,6 +58,9 @@ Don't do hostname lookups. This setting may be altered at run time.
Run in promiscuous mode, so that traffic which does not pass directly through
the specified interface is also counted.
Don't display bar graphs of traffic. This setting may be altered at run time.
\fB-i\fP \fIinterface\fP
Listen to packets on \fIinterface\fP.
......@@ -13,7 +13,7 @@
options_t options;
char optstr[] = "+i:f:n:dhp";
char optstr[] = "+i:f:n:dhpb";
/* Global options. */
......@@ -68,12 +68,13 @@ static void usage(FILE *fp) {
"iftop: display bandwidth usage on an interface by host\n"
"Synopsis: iftop -h | [-d] [-p] [-i interface] [-f filter code] [-n net/mask]\n"
"Synopsis: iftop -h | [-dpb] [-i interface] [-f filter code] [-n net/mask]\n"
" -h display this message\n"
" -d don't do hostname lookups\n"
" -p run in promiscuous mode (show traffic between other\n"
" hosts on the same network segment)\n"
" -b don't display a bar graph of traffic\n"
" -i interface listen on named interface (default: eth0)\n"
" -f filter code use filter code to select packets to count\n"
" (default: none, but only IP packets are counted)\n"
......@@ -115,6 +116,10 @@ void options_read(int argc, char **argv) {
case 'b':
options.showbars = 0;
case '?':
fprintf(stderr, "iftop: unknown option -%c\n", optopt);
......@@ -34,6 +34,7 @@ void resolver_worker(void* ptr) {
delay.tv_sec = 0;
delay.tv_nsec = 500;
while(1) {
/* Wait until we are told that an address has been added to the
* queue. */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment