π An educational tool to analyze router performance by safely sending requests, monitoring responses, and visualizing system usage with real-time graphs.
This project is for educational and diagnostic purposes only. Do NOT use it on networks, routers, or devices you do not own or lack explicit permission to test. Unauthorized testing may be illegal and disruptive.
-
π HTTP request testing across common router endpoints
-
π Telnet (port 23) connection attempts
-
π‘ ICMP ping requests
-
π Real-time system monitoring with
matplotlib
:- CPU usage
- Memory usage
- Network throughput (sent/received)
- Requests per second
-
π Detailed performance report at the end of each test
Clone this repository:
git clone https://github.com/HasnainMARS/Python-Base-Advanced-Router-Performance-Analyzer-with-Real-Time-Graphs.git
cd Python-Base-Advanced-Router-Performance-Analyzer-with-Real-Time-Graphs
Create a virtual environment (recommended):
conda create -n router-test python=3.10
conda activate router-test
Install dependencies:
pip install -r requirements.txt
or manually:
pip install requests psutil matplotlib
Edit the target IP address in main()
of advanced_router_analyzer.py
:
target_ip = "1354.1589.16.21" # replace with your router IP
Run the analyzer:
python advanced_router_analyzer.py
β While the test runs:
- A live graph window will show resource usage and request rates.
- The terminal will display real-time stats.
- A final performance report will print at the end.
Console output snippet:
π STARTING COMPREHENSIVE ROUTER PERFORMANCE TEST
π― Target: 132.1558.145.12 <<<<<<Replace with your IP
β± Duration: 30 seconds
π Start Time: 2025-09-29T10:42:00
======================================================================
π MONITOR: CPU: 15% | RAM: 42% | REQ/s: 35.00 | NET: β12.1KB/s β10.7KB/s
...
π Test complete! Graphs will remain open for a short while...
π COMPREHENSIVE ROUTER PERFORMANCE REPORT
======================================================================
β± Test Duration: 30.15 seconds
π Total Operations: 1,050
π Operations/Second: 34.8
β
Success Rate: 94.5% (993/1,050)
...
π ROUTER PERFORMANCE ASSESSMENT:
π VERY GOOD - Strong consumer router
======================================================================
router-analyzer/
βββ advanced_router_analyzer.py # main script
βββ requirements.txt # dependencies
βββ README.md # this file
- Python 3.8+
- Requests
- psutil
- matplotlib
- Add CLI arguments (
--ip
,--duration
,--workers
) - Save performance logs to CSV/JSON
- Export graphs to PNG automatically
MIT License β free to use, modify, and share. Use responsibly.
PRs are welcome! If you have improvements (e.g., better graphs, safer tests, logging), open a pull request.
- Real-time graphs visualize system resource usage during load.
- CPU spikes = processing load on your computer.
- Memory usage shows script footprint.
- Network graphs illustrate request/response patterns.
- Final report helps understand router resilience under stress.