TestimoX

Monitoring Setup Guide

Edit on GitHub

Install and configure TestimoX.Monitoring for continuous Active Directory infrastructure health monitoring.

Monitoring Setup Guide

This guide walks through installing, configuring, and running the TestimoX.Monitoring service for continuous Active Directory infrastructure monitoring.

Prerequisites

  • .NET 8.0 Runtime or later
  • Active Directory domain membership (for auto-discovery) or manual target configuration
  • Network access to domain controllers on required probe ports (53, 88, 123, 389, 443, 636, 9389)
  • TestimoX license (Community edition supports basic monitoring)

Installation

CLI (Standalone)

dotnet tool install --global TestimoX.Monitoring

Windows Service

# Install as a Windows service
testimox-monitoring install --service-name "TestimoX.Monitoring"

# Start the service
Start-Service -Name "TestimoX.Monitoring"

PowerShell Module

Install-Module -Name TestimoX.PowerShell -Scope CurrentUser

Configuration

Monitoring is configured via a JSON configuration file. By default the service looks for monitoring.json in the working directory.

Minimal Configuration

{
  "monitoring": {
    "interval": 300,
    "targets": {
      "discovery": "auto"
    },
    "probes": [
      { "type": "Ping" },
      { "type": "DNS" },
      { "type": "LDAP" },
      { "type": "Kerberos" }
    ]
  }
}

Full Configuration Example

{
  "monitoring": {
    "interval": 300,
    "timeout": 30,
    "retries": 2,
    "targets": {
      "discovery": "auto",
      "include": ["dc01.contoso.com", "dc02.contoso.com"],
      "exclude": ["dc-test.contoso.com"]
    },
    "probes": [
      { "type": "Ping" },
      { "type": "DNS" },
      { "type": "LDAP", "ports": [389, 636] },
      { "type": "Kerberos" },
      { "type": "NTP" },
      { "type": "HTTPS", "paths": ["/"] },
      { "type": "Port", "ports": [3268, 3269, 9389] },
      { "type": "Replication" },
      { "type": "Directory" },
      { "type": "ADWS" }
    ],
    "thresholds": {
      "latency_warning_ms": 500,
      "latency_critical_ms": 2000
    },
    "notifications": {
      "email": {
        "enabled": false,
        "smtp_server": "smtp.contoso.com",
        "recipients": ["ad-team@contoso.com"],
        "on_status_change": true
      }
    },
    "dashboard": {
      "enabled": true,
      "port": 8080,
      "bind": "localhost"
    },
    "history": {
      "retention_days": 30,
      "store_path": "./monitoring-data"
    }
  }
}

Configuration Reference

General Settings

SettingTypeDefaultDescription
intervalint300Probe execution interval in seconds
timeoutint30Per-probe timeout in seconds
retriesint1Retry attempts on probe failure

Target Discovery

SettingTypeDefaultDescription
discoverystringautoauto for AD-based discovery, manual for explicit targets
includestring [][]Additional targets to include
excludestring [][]Targets to exclude from monitoring

Probe Settings

Each probe entry in the probes array supports:

SettingTypeDescription
typestringProbe type (Ping, DNS, LDAP, Kerberos, NTP, HTTPS, Port, Replication, Directory, ADWS, DnsService)
enabledboolEnable or disable this probe (default: true)
portsint []Override default ports for Port and LDAP probes
pathsstring []URL paths for HTTPS probes
intervalintOverride global interval for this probe

Dashboard

SettingTypeDefaultDescription
enabledbooltrueEnable the HTML dashboard
portint8080Dashboard HTTP port
bindstringlocalhostBind address

Notifications

SettingTypeDescription
email.enabledboolEnable email notifications
email.smtp_serverstringSMTP server address
email.recipientsstring []Notification recipients
email.on_status_changeboolSend only on status transitions

Running Monitoring

CLI Mode

# Run with default config
testimox-monitoring

# Run with custom config
testimox-monitoring --config ./my-monitoring.json

# Run with verbose output
testimox-monitoring --verbosity detailed

PowerShell

# Initialize monitoring service
Initialize-TestimoXService -ConfigPath './monitoring.json'

# Start monitoring
Invoke-TestimoXService -Mode Monitoring

# Check service status
Get-TestimoXService

As a Windows Service

# Check service status
Get-Service -Name "TestimoX.Monitoring"

# View service logs
Get-EventLog -LogName Application -Source "TestimoX.Monitoring" -Newest 20

Dashboard

When the dashboard is enabled, navigate to http://localhost:8080 (default) to view:

  • Overview -- aggregate health status across all targets and probes
  • Per-DC drill-down -- individual domain controller probe results and history
  • Probe timeline -- historical trend for each probe type
  • Alerts -- active and recent status change notifications

Branding

Premium and Enterprise editions support custom branding for the monitoring dashboard:

{
  "monitoring": {
    "dashboard": {
      "branding": {
        "title": "Contoso AD Health",
        "logo": "./assets/logo.png",
        "accent_color": "#1a5276"
      }
    }
  }
}

Next Steps