IFSTAT(1)
π IFSTAT(1) π
okay bestie, so this is ifstat β that's "Report InterFace STATistics", and yes the name is literally just the name of the tool spelled out. we're doing the Unix manual thing but make it cute. buckle up. π
It lives in the System Utilities corner of your man pages, so you know it's a little utility that's about to be your new obsession. β¨
β¨ NAME β¨
ifstat β Report InterFace STATistics. that's it. that's the whole name. iconic. π
πΈ SYNOPSIS πΈ
ifstat [-a] [-l] [-z] [-n] [-v] [-h] [-t] [-i if0,if1,...] [-d
drv[:opt]] [-s [comm@][#]host[/nn]] [-T] [-A] [-w] [-W] [-S] [-b] [-q]
[delay[/delay] [count]]
no cap, that's a lot of brackets. don't panic. we go through every single one below. π«Ά
π¦ DESCRIPTION π¦
So like, ifstat is a little tool that reports interface activity. that's the whole vibe. it does for your network interfaces what iostat/vmstat do for other system statistics. main character energy fr fr. β
π OPTIONS π
ifstat accepts the following options (and yes, we're doing all of them, no skips, no shortcuts):
-lβ turns ON monitoring of loopback interfaces (the ones where stats are actually available). by default,ifstatmonitors all non-loopback interfaces that are up. so if you were wondering wherelowent, it's because of this default. mystery solved bestie. π-aβ monitors ALL the interfaces it can find, as long as stats are available for them. yes, all of them. it's giving overachiever. π-zβ hides interfaces whose counters are null, like interfaces that are up but literally not being used. shy interfaces, we don't see them. π-iβ specifies the list of interfaces to monitor, separated by commas. and listen, if an interface name itself has a comma in it, you can escape it with'\'. also cute: if you pass this option multiple times, the instances get added together. stacking, as you do. π-sβ equivalent to-d snmp:[comm@][#]host[/nn]], i.e. poll a remote host through SNMP. details down below, keep reading. π‘-hβ displays a short help message. when in doubt, ask for help. no shame. π«Ά-nβ turns OFF displaying the header periodically. so the header shows up... not periodically. got it. π-tβ adds a timestamp at the beginning of each line. time-stamped and organized, we love a girlboss. β°-Tβ reports total bandwidth for all monitored interfaces. the sum. the whole squad combined. π₯-Aβ disables use of interface indexes. here's the tea: by default, when the polling mechanism is index based (snmp,ifmib),ifstatremembers the indexes of monitored interfaces so it only polls those. but if indexes change a lot (new interfaces being added and whatnot), you might lose some stats, hence this flag. also important, no cap: if you askifstatto monitor a non-existent interface, it will poll all interfaces until it finds the one you asked for β regardless of this flag β so you can totally poll for an interface that goes up and down. queen of persistence. π-wβ uses fixed width columns, instead of enlarging them as needed so interface names fit. rigid. structured. we respect it. π-Wβ wraps lines that are larger than the terminal width. note this implies-w. wrapped lines get prefixed with a cycling letter so they're easier to read. thoughtful king behavior. π-Sβ keeps stats updated on the same line if possible, so there's no scrolling and no wrapping. calm. zen. β¨-bβ reports bandwidth in kbits/sec instead of kbytes/sec. bits not bytes, choose your fighter. βοΈ-qβ quiet mode, warnings are not printed. shhh. π€«-vβ displays the version and the compiled-in drivers. like a little roster of who's on the team. π-dβ specifies a driver to use for gathering stats, plus an eventual option for that driver, separated from the driver name by a colon. if you don't specify this,ifstatuses the first driver compiled in, with no options. defaults gonna default. πΈ
The following drivers are available β though depending on your operating system and compile-time options, not all of them might be present:
procβ gets statistics from Linux's/proc/net/devfile. an alternate file name to get stats from can be passed as the option. π§ifmibβ gets statistics from FreeBSD'sifmibsysctl. it doesn't accept any options. no notes. π§kstatβ gets statistics from Solariskstatinterface. it doesn't accept any options. πifdataβ gets statistics usingSIOCGIFDATAioctl under IRIX and OpenBSD (and heads up, those have different semantics). it doesn't accept any options. πrouteβ gets statistics using routing sysctl on BSD based systems. it doesn't accept any options. π£οΈkvmβ gets statistics by reading the kernel live structures. it accepts an option specifying which files/devices to use, in this format:
[execfile][,[corefile][,swapfile]]
(see kvm_open(3) for details on those fields). if a null string is passed for a parameter, the system default will be used for it.
β οΈ okay serious moment bestie: for this driver to work,ifstatneeds read access to the system memory device. this is usually done by running it as root, or by installing setgid mem or setgid kmem. and here's the thing βifstatwill NOT install setgid by default. it is up to you to decide if you trust it. read that again. π
dlpiβ gets statistics using the DLPI streams interface available on HP-UX. an alternate device to query statistics from can be passed as the option β the default is/dev/dlpi. πwin32β gets statistics using theGetIfTableinterface available on Win32 systems. it doesn't accept any options. windows representation, we love to see it. πͺsnmpβ gets statistics through SNMP. the option, in the form[comm@][#]host[/nn]], specifies the host and eventual community to poll.- default community is
public, but you can change it by prepending"comm@"to the hostname. - if the host starts with a
#, interface names are generated from their index asifNNβ this is a workaround for some equipments that give all interfaces the same description. π - default host is
localhost, and this will be used by default ifsnmpis the only available driver.
- default community is
the driver will try to poll several interfaces at once by grouping requests in SNMP packets. by default interfaces are polled in groups of 8. if that doesn't work well with your equipments, you can lower that number by suffixing the hostname with /nn, where nn is the number of interfaces to poll at once. you can also increase that number if you want to poll a large number of interfaces efficiently and if your server supports it. flexible. adaptable. slay. π₯
delayβ the delay between updates in seconds, which defaults to1. a decimal number can be specified for intervals shorter than a second. (minimum0.1.)
a second delay can also be specified, separated from the first one by a /. in that case, the first delay is used for the first poll after start, and the second one is used for all following polls. this can be used to have a "fast" start when running for a long while with a big delay. honestly? genius. π§
countβ the number of updates before stopping. if not specified, it is unlimited. infinite. boundless. no thoughts, just stats. βΎοΈ
π SEE ALSO π
vmstat(1), iostat(1)
(go read those too, they're the siblings, the family, the whole squad π«Ά)
π AUTHOR π
GaΓ«l Roualland, <gael.roualland@dial.oleane.com> β thank you for this gift, we are obsessed. π
and that's the whole page bestie! this was ifstat version 1.1, dated 2003-11-22, and honestly? a 2003 banger that still eats. go check your interfaces, they're probably doing numbers. bye! πβ¨π¦πΈ
π¦ where this page comes from
- fedora 43: ifstat 1.1-48.fc43 Β· GPL-2.0-or-later
- fedora 44: ifstat 1.1-50.fc44 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms