ifstat-rs
ifstat-rs is a straightforward and efficient Rust tool to report network interface stats just like ifstat.
Features
- Real-time Monitoring: Parses and displays RX and TX bytes for each network interface every second.
- Interface Flexibility: Monitor specific interfaces, all interfaces, or just loopback interfaces.
- Configurable Updates: Set delays between updates and limit the number of updates.
Supported Platforms
- Linux: Fully supported with real-time network statistics from
/proc/net/dev. - macOS: Provisions in place, support in development.
- Windows: Supported as of v2.0.0.
Installation
To install ifstat-rs, ensure you have Rust and Cargo installed, then run:
Usage
Options
ifstat-rs
-a: Monitor all interfaces.-l: Include loopback interfaces.-i <interfaces>: Specify interfaces to monitor, separated by commas (e.g.,-i eth0,lo).--first-measurement <seconds>: Set delay before the first measurement (default is the same as --delay).<delay>: Delay between updates in seconds (default is 1 second).<count>: Number of updates before stopping (default is unlimited).
Examples
Monitor specific interfaces:
Monitor all interfaces:
Include loopback interfaces:
Specify delay and count:
Development
Run the tool with:
License
This project is licensed under the MIT License - see the LICENSE file for details.
"This project has been generated with the assistance of ChatGPT. Please be aware that ChatGPT can make mistakes. It is important to review and verify all information provided by the tool." is what it says. Just so you know. Because I guess maybe all the bugs aren't my fault after all.