Skip to main content

Monitoring

Monitoring AthenaBNG services and performance.

Overview

AthenaBNG provides multiple monitoring capabilities:

  • CLI Monitoring — Real-time session events
  • Prometheus Metrics — Time-series metrics
  • SNMP — NOC integration
  • Syslog — Centralized logging
  • Service Logs — systemd journal

CLI Monitoring

Real-Time Session Monitor

abng> monitor subscribers

Displays live session events:

  • session_up — Session established
  • session_down — Session terminated
  • rate_change — Rate changed via CoA

Session Queries

# Get session count
abng> show subscribers summary

# Get QoS coverage
abng> show qos | count

# Get interface list
abng> show interfaces

Prometheus Metrics

Scrape Configuration

Add to Prometheus prometheus.yml:

scrape_configs:
- job_name: 'athenabng'
static_configs:
- targets: ['localhost:9100']
scrape_interval: 15s

Key Metrics

MetricDescription
athenabng_sessions_totalTotal active sessions
athenabng_sessions_pppoePPPoE sessions
athenabng_sessions_dhcpDHCP sessions
athenabng_qos_sessionsSessions with QoS
athenabng_vlan_interfacesDynamic VLAN interfaces
athenabng_uptime_secondsSystem uptime

SNMP Monitoring

Query Session Count

snmpget -v2c -c my-community localhost 1.3.6.1.4.1.65245.2.1.0

Check Service Health

# Walk all daemon health checks (TruthValue: 1=up, 2=down)
snmpwalk -v2c -c my-community localhost 1.3.6.1.4.1.65245.6

Walk All Metrics

snmpwalk -v2c -c my-community localhost 1.3.6.1.4.1.65245

Syslog Forwarding

Configuration

monitoring:
syslog:
enabled: true
server: "10.255.0.20"
port: 514
protocol: "udp"

Verify Forwarding

sudo journalctl -u abngd | grep "syslog"

Service Logs

View All Logs

sudo journalctl -u AthenaBNG.target -f

View Specific Service

sudo journalctl -u abngd -f
sudo journalctl -u abng-demux -f
sudo journalctl -u accel-ppp -f

Filter by Level

# Errors only
sudo journalctl -u abngd -p err

# Warnings and errors
sudo journalctl -u abngd -p warning

Health Checks

Check Service Status

sudo systemctl status AthenaBNG.target

Check Socket Connectivity

echo '{"jsonrpc":"2.0","method":"show.system","params":{},"id":1}' | \
nc -U /opt/athena-bng/run/abngd.sock

Check Session Count

abng -c "show subscribers" | wc -l

Alerting

Session Count Alert

Alert when sessions exceed threshold:

- alert: HighSessionCount
expr: athenabng_sessions_total > 5000
for: 5m

Service Down Alert

Alert when service is down:

- alert: ServiceDown
expr: up{job="athenabng"} == 0
for: 1m

Next Steps