Skip to content

Keysight/IxOSMonitoring

Repository files navigation

IxOS Metrics Plotter

Real-time monitoring and visualization of Ixia/Keysight IxOS chassis port utilization with parallel polling, time-series storage, and interactive dashboards.

Docker Python InfluxDB Grafana


🎯 Overview

Monitor multiple IxOS chassis simultaneously with real-time visibility into:

  • Port Ownership - Track which user/session owns each port
  • Link Status - Monitor port connectivity (up/down)
  • Transmit State - Track traffic state (active/idle)
  • Resource Utilization - View total, owned, and free ports

Key Benefits:

  • ⚑ Parallel polling - Monitor 10+ chassis in ~2 seconds
  • πŸ“Š Time-series visualization - Historical analysis with Grafana
  • 🐳 One-command deployment - Docker Compose for quick setup
  • πŸ”„ Synchronized timestamps - Aligned data across all chassis

πŸ—οΈ Solution Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                        IxOS CHASSIS FLEET                           β”‚
β”‚   [Chassis 1] ─── [Chassis 2] ─── ... ─── [Chassis N]             β”‚
β”‚      :8443            :8443                    :8443                β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                               β”‚ REST API (Parallel Polling)
                               β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                      HOST MACHINE                                   β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”    β”‚
β”‚  β”‚  IxOS Poller (Python)                                      β”‚    β”‚
β”‚  β”‚  β€’ portInfoPoller.py  β†’ Port metrics (InfluxDB)           β”‚    β”‚
β”‚  β”‚  β€’ perfMetricsPoller.py β†’ Performance metrics (Prometheus)β”‚    β”‚
β”‚  β”‚  β€’ Parallel polling with ThreadPoolExecutor                β”‚    β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                        β”‚                   β”‚
        HTTP :8086      β”‚                   β”‚ HTTP :9001
                        β”‚                   β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                      DOCKER COMPOSE STACK                           β”‚
β”‚                                                                     β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚   InfluxDB       β”‚  β”‚   Prometheus     β”‚  β”‚    Grafana      β”‚  β”‚
β”‚  β”‚   :8086          β”‚  β”‚   :9090          β”‚  β”‚    :3000        β”‚  β”‚
β”‚  β”‚                  β”‚  β”‚                  β”‚  β”‚                 β”‚  β”‚
β”‚  β”‚ β€’ Port metrics   β”‚  β”‚ β€’ Perf metrics   β”‚  β”‚ β€’ Dashboards    β”‚  β”‚
β”‚  β”‚ β€’ Time-series DB β”‚  β”‚ β€’ System health  β”‚  β”‚ β€’ Visualization β”‚  β”‚
β”‚  β”‚ β€’ Infinite store β”‚  β”‚ β€’ 15d retention  β”‚  β”‚ β€’ Multi-source  β”‚  β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚
β”‚                                                                     β”‚
β”‚  πŸ“¦ Persistent Volumes: influxdb-data, prometheus-data, grafana-data β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Data Flow:

  1. Python poller queries all chassis in parallel (2-3s for 10+ chassis)
  2. Port metrics β†’ InfluxDB | Performance metrics β†’ Prometheus
  3. Grafana visualizes both data sources with synchronized timestamps

✨ Features

  • ⚑ Parallel Polling - ThreadPoolExecutor for simultaneous chassis queries
  • πŸ”„ Synchronized Timestamps - Aligned data across all chassis
  • πŸ“Š Dual Storage - InfluxDB (port data) + Prometheus (system metrics)
  • 🎨 Interactive Dashboards - State Timeline, Time Series, Gauges
  • 🐳 Docker Compose - One-command infrastructure deployment
  • πŸ›‘οΈ Health Monitoring - Automatic service health checks
  • πŸ’Ύ Persistent Storage - Data survives container restarts
  • πŸ”§ Configurable - Environment-based configuration

πŸ“‹ Prerequisites

  • Docker 20.10+ & Docker Compose 2.0+
  • Python 3.7+ with pip
  • Network access to IxOS chassis (REST API enabled)
  • 2GB free disk space

πŸš€ Quick Start

1. Clone and Configure

git clone https://github.com/yourusername/IxPortUtilizationPlotter.git
cd IxPortUtilizationPlotter
cp env.example .env

2. Edit Configuration

.env file (TO start Docker services):

INFLUXDB_PORT=8086
PROMETHEUS_PORT=9090
GRAFANA_PORT=3000

# InfluxDB Configuration
INFLUXDB_ADMIN_USER=admin
INFLUXDB_ADMIN_PASSWORD=admin
INFLUXDB_ORG=keysight
INFLUXDB_BUCKET=ixosChassisStatistics
INFLUXDB_TOKEN='eegHpR9kkgxg5KG7rklj2zQI86-5z7yNETx0P0qQpSnw1owDxSL5IF-uQruOP-J8M_xmrhT3KWECh-QGbsdyYA=='
INFLUXDB_RETENTION=0  # 0 = infinite retention, or specify in seconds

# Grafana Configuration
GRAFANA_ADMIN_USER=admin
GRAFANA_ADMIN_PASSWORD=admin
INFLUXDB_TOKEN=<your-super-secret-token-change-me>

2.1 .Once you have these values set. Start the Containers:

# Start Docker infrastructure (InfluxDB, Prometheus, Grafana)
docker compose up -d

In .env file modify following polling intervals and chassis list **

# Polling interval in seconds - This is for my influxDB to select metrics push intevals
POLLING_INTERVAL=120
# Polling interval in seconds - This is for my prometheus to select metrics push intevals
POLLING_INTERVAL_PERF_METRICS=110
CHASSIS_LIST = [
    {"ip": "10.36.75.205", "username": "admin", "password": "admin"},
]

3. Start Python Poller to get data from Ixia Chassis

# Install Python dependencies
pip install -r requirements.txt

# Start pollers on host
chmod +x run_pollers.sh stop_pollers.sh

./run_pollers.sh

4. Access Web Interfaces

Service URL Credentials
Grafana http://localhost:3000 admin / admin
InfluxDB http://localhost:8086 admin / keysight12345
Prometheus http://localhost:9090 No auth

πŸ”§ Management Commands

# View logs
docker compose logs -f                 # All services
docker compose logs -f influxdb        # Specific service
tail -f portInfoPoller.log             # Poller logs

# Control services
docker compose stop                    # Stop all
docker compose restart                 # Restart all
./stop_pollers.sh                      # Stop pollers

# Health checks
docker compose ps                      # Service status
curl http://localhost:8086/health      # InfluxDB health
curl http://localhost:9090/-/healthy   # Prometheus health

πŸ“š Documentation

Document Description
SOLUTION_DEPLOYMENT.md Complete deployment guide with troubleshooting
ENVIRONMENT_VARIABLES.md All environment variables reference
config.py Chassis list and poller configuration
prometheus.yml Prometheus scrape configuration

πŸ” Troubleshooting

Issue Solution
No data in Grafana Verify INFLUXDB_TOKEN matches in .env and config.py
Connection timeout Check chassis is reachable: ping <chassis_ip>
Port already in use Customize ports in .env: INFLUXDB_PORT=8087
Poller not starting Check logs: tail -f portInfoPoller.log
Stale data in timeline Add elapsed() filter to Flux query (see Common Queries)

Detailed troubleshooting: See SOLUTION_DEPLOYMENT.md


πŸ“Š Data Schema

Measurement: portUtilization

Type Name Description Example
Tags chassis Chassis IP 10.36.75.205
card Card number 1
port Port number 5
Fields owner Port owner Free or user/session
linkState Link status linkUp, linkDown
transmitState Traffic state active, idle
totalPorts Total ports 48
ownedPorts Owned ports 12
freePorts Available ports 36

🎨 Performance

Parallel vs Sequential Polling:

Chassis Count Sequential Parallel Improvement
1 chassis 2s 2s 0%
5 chassis 10s 2-3s 70-80%
10 chassis 20s 2-3s 85-90%
20 chassis 40s 3-4s 90-92%

πŸ“ Project Structure

IxPortUtilizationPlotter/
β”œβ”€β”€ 🐳 Docker Infrastructure
β”‚   β”œβ”€β”€ docker-compose.yml         # Service orchestration
β”‚   β”œβ”€β”€ prometheus.yml             # Prometheus config
β”‚   └── grafana/provisioning/      # Auto-configured data sources
β”‚
β”œβ”€β”€ 🐍 Python Pollers
β”‚   β”œβ”€β”€ portInfoPoller.py          # Port metrics (InfluxDB)
β”‚   β”œβ”€β”€ perfMetricsPoller.py       # Performance metrics (Prometheus)
β”‚   β”œβ”€β”€ influxDBclient.py          # InfluxDB operations
β”‚   β”œβ”€β”€ IxOSRestAPICaller.py       # IxOS REST API client
β”‚   └── RestApi/                   # Low-level REST interface
β”‚
β”œβ”€β”€ βš™οΈ Configuration
β”‚   β”œβ”€β”€ .env                       # Docker environment vars
β”‚   β”œβ”€β”€ config.py                  # Chassis list & settings
β”‚   └── requirements.txt           # Python dependencies
β”‚
β”œβ”€β”€ πŸš€ Management Scripts
β”‚   β”œβ”€β”€ run_pollers.sh             # Start pollers
β”‚   └── stop_pollers.sh            # Stop pollers
β”‚
└── πŸ“š Documentation
    β”œβ”€β”€ README.md                  # This file
    β”œβ”€β”€ SOLUTION_DEPLOYMENT.md     # Detailed deployment guide
    └── ENVIRONMENT_VARIABLES.md   # Configuration reference

πŸ“Έ Dashboard Examples

Port Ownership State Timeline

Port Ownership Timeline

Features:

  • 🟒 Green = Free ports (available)
  • πŸ”΄ Red = Owned ports (user/session)
  • πŸ• Synchronized timestamps across all chassis
  • πŸ“Š Real-time updates with historical view

Multi-Port Monitoring

Multi-Port Dashboard

Visualization: Multiple chassis monitored simultaneously with instant visibility into port transitions and resource utilization.


🀝 Contributing

Contributions welcome! Open an issue or submit a pull request.


πŸ“„ License

Open source project for Keysight/Ixia IxOS chassis monitoring.


Built with ❀️ for network test automation teams

πŸ“Š Happy Monitoring!

About

This repository contains code to integrate Ixia Chassis metrics like

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published