A lightweight, agentless multi-server GPU monitoring tool and usage dashboard.
This is a lightweight tool for monitoring multiple remote GPU servers from a single dashboard.
It connects to remote Linux servers over SSH, runs nvidia-smi commands, identifies which Linux user owns each GPU process, and saves the data into a local SQLite database. A web interface built with Streamlit displays real-time GPU statistics and historical usage timelines.
No client-side software or agent is required on the GPU servers. As long as the servers have SSH and nvidia-smi, they can be monitored.
- No Agent Needed: Uses standard SSH connections to fetch
nvidia-smimetrics. No background daemons needed on the remote machines. - Process & User Identification: Correlates GPU processes with Linux usernames, making it easy to see who is currently using which GPU.
- Real-time Metrics: Displays GPU model, memory usage, utilization percentage, and power draw in a clean card layout.
- Historical Timeline: Visualizes past GPU usage over 1 to 28 days using interactive Plotly Gantt charts.
- Lightweight Storage: Stores metrics locally in SQLite with low overhead.
- Demo Mode Included: Comes with a demo data generator to test the interface without remote servers.
- Python 3.8 or higher
git clone https://github.com/Tison6/Remote-GPU-Monitor.git
cd Remote-GPU-Monitor
pip install -r requirements.txtIf you want to view the interface before configuring real servers:
# Generate sample data
python generate_demo_data.py
# Launch web dashboard
streamlit run monitor_gpu_viewer.pySwitch the database path in the sidebar to ./data/demo_gpu_history.db.
Copy config.example.json to config.json:
# Linux / macOS
cp config.example.json config.json
# Windows
copy config.example.json config.jsonEdit config.json with your server connection details:
{
"database": {
"path": "./data/gpu_history.db"
},
"servers": [
{
"id": "Server-1",
"host": "192.168.1.101",
"port": 22,
"username": "ubuntu",
"auth_type": "key",
"key_path": "~/.ssh/id_rsa"
},
{
"id": "Server-2",
"host": "192.168.1.102",
"port": 22,
"username": "admin",
"auth_type": "password",
"password": "your_password"
}
],
"user_mapping": {
"user_a": "Alice",
"user_b": "Bob"
}
}Note:
config.jsonis listed in.gitignoreso your private credentials and hostnames will not be committed to Git.
# Windows
start_logger.bat
# or: python monitor_gpu_logger.py
# Linux / macOS
chmod +x start_logger.sh
./start_logger.sh
# or: python3 monitor_gpu_logger.py# Windows
start_viewer.bat
# or: streamlit run monitor_gpu_viewer.py
# Linux / macOS
chmod +x start_viewer.sh
./start_viewer.shOpen http://localhost:8501 in your browser.
| Option | Description | Default |
|---|---|---|
database.path |
SQLite database file location | ./data/gpu_history.db |
monitor.refresh_interval_sec |
Frequency of polling real-time metrics | 5 |
monitor.history_log_interval_sec |
Frequency of archiving history snapshots | 60 |
monitor.busy_memory_threshold_mb |
VRAM threshold (MB) to classify GPU as busy | 1024 |
servers[].id |
Display name for the server | - |
servers[].host |
Server IP address or hostname | - |
servers[].port |
SSH port | 22 |
servers[].auth_type |
Authentication method ("key" or "password") |
"key" |
servers[].key_path |
Private key path if using key auth | - |
user_mapping |
Optional mapping from Linux usernames to display names | {} |
This project is licensed under the MIT License.