Oracle Database Monitoring at Fleet Scale
DB Realm Inc. (Internal)
Challenge
Monitoring an Oracle estate usually forces a bad trade. Agent-based tools need software installed on database servers, which security teams resist and change control slows down. Console-based tools cost more than the databases they watch. Most of them also read Diagnostics Pack views, which exposes the organization to a licensing claim that only surfaces during an audit, long after the usage was logged.
Solution
Built a monitoring agent that runs without an Oracle client, without an installed agent on the database server, and without touching a licensed view unless explicitly permitted. It emits both a human-readable HTML dashboard and a structured JSON payload, which it uploads to a central support platform over a token-authenticated ORDS endpoint. Agents also push their own configuration for versioned backup and drift detection, so the fleet reports its own consistency as well as its health.
Results
- ✓ Runs in Python thin mode, with no Oracle client
- ✓ Explicit licensing gate on Diagnostics Pack views
- ✓ Feeds a central platform across a live fleet
- ✓ Remote and agentless collection for Kubernetes and Autonomous DBs
Most Oracle monitoring products make an assumption that does not survive contact with a regulated environment: that you are allowed to install their agent, and that you have licensed the packs their queries read. This agent is written for environments where neither holds.
Licensing as a design constraint
Oracle’s Diagnostics Pack is separately licensed, and several of the most convenient monitoring views fall under it, v$sysmetric first among them. Querying them on an unlicensed database creates real exposure, and the usage is recorded whether or not anyone intended it.
The agent treats this as a hard gate. A configuration flag, allow_diagnostics_pack, defaults to false. While it is false, the pack-gated panel is skipped entirely and only licence-free metrics are collected. Turning it on is a deliberate, per-host decision made by someone who knows what that database is licensed for.
The same principle governs the audit module: it reads only unified_audit_trail and the enabled-policies view. It does not touch AWR or active session history, so it has no pack dependency.
What it collects
Tablespaces grouped per container, ASM disk groups, PDB open modes, APEX and ORDS versions per PDB, RMAN backup history, scheduler jobs from both the database and the OS, Data Guard lag, and host disk, CPU and memory.
Two deeper sections are opt-in and off by default:
- Performance: session and process headroom, shared pool free percentage, blocked and long-running sessions, redo switch rate, archive log rate, instance uptime
- Health and integrity: block corruption, datafiles needing recovery, archiver health, unusable indexes, invalid objects, invalid registry components, expired and locked accounts, PDB violations, stale statistics, sequences approaching their maximum
There are also drill-downs for expensive SQL, blocking chains and Health Monitor findings, where the HTML shows the top few and the JSON carries everything.
Deployment reality
It runs in Python thin mode, so no Oracle client is installed anywhere. It works on Windows and Linux. It also supports remote collection, for Kubernetes-hosted databases and Autonomous Databases where nothing can be installed on the host.
Feeding the platform
The agent is one half of a pair. Its JSON payload uploads to a token-authenticated ORDS endpoint on a central support platform, The single endpoint dispatches on report type: health reports go to one ingestion package, audit reports to another.
Two details make this work at fleet scale rather than host by host.
The first is configuration backup and drift detection. Each agent pushes its own effective configuration, with secrets redacted, for versioned storage. The platform can then show what changed and when.
The second is a capability matrix. Every report carries an enabled_features map derived from the agent’s effective configuration, not its file. The platform renders this as a per-host feature grid and flags drift, so a host running fewer checks than its peers stands out at once. Database-only features are forced off for hosts with no database configured, so an OS-only host never advertises capabilities it cannot have.
That last point closes a real failure mode: a configuration file written by an older agent version silently falls back to in-code defaults for every key it lacks, which can make a host under-report what it checks. The updater now reconciles configurations automatically on every upgrade: it adds missing sections with safe defaults, repairs empty ones, and never invents a report section whose absence is itself meaningful.
Unified audit
A daily unified-audit summary classifies events by severity, emails a dashboard, and uploads to the platform’s audit module, where threshold breaches raise alerts. The consumer side derives a display name for events where the database username is null, falling back to the OS user and host. An audit dashboard therefore never shows a blank actor on a failed login.