Skip to content
DBA Brain
Oracle MCP server

An Oracle MCP server that answers like a DBA

DBA Brain MCP gives Claude and other AI agents the tools a DBA reaches for on Oracle Database: is the instance up and usable, what is it running now, who is blocking whom, what does this table or package look like, how did it look at three in the morning, did the RMAN backup restore. A request names a server, never a password - the login comes from the encrypted store on your machine - and the tools that only read answer without a key.

What the agent can ask

Six questions an Oracle DBA answers every day

Is it up and usable?

db-status answers with a verdict - OK, WARNING or CRITICAL - at instance, database and schema depth, instead of rows the agent has to judge. list-objects says what exists - schemas - and its jobs read DBA_SCHEDULER_JOBS and the older DBA_JOBS.

What is it running now?

db-activity lists the sessions running now, the blocking - who holds the lock and who waits on it - the waits, and the top statements since their plans were cached.

What does this table or package look like?

table-info gives the columns, the indexes, the row count and the space taken; object-source the text of a procedure, function, package, type, view or trigger from ALL_SOURCE. The agent reads them before it writes a query.

Run this SELECT

run-sql runs one SELECT and always rolls back; run-sql-write keeps a change only with commit. Both run with the rights of the user your machine stores, so they are marked destructive: give the machine a user that can only read.

How did it look at 3 a.m.?

store-query reads DBA Brain's own store: every metric it collected from the instance - data-file space, sessions, waits, blocking, the alert log's critical errors - with the grade each one got, so the agent answers from history instead of guessing.

Did the RMAN backup restore?

The same store holds each RMAN backup piece with its SHA-256 and each scheduled restore drill - when it ran, how far it got, and whether it passed its checks. How the drills work.

Why it is safe to hand an agent

The agent names a server; your machine does the rest

No password in the context

A request names a server_id, and your machine fills the login from its encrypted store. A request carrying a password, a key or a token is refused, and every answer is redacted.

Changes ask first

A tool that changes something - run-sql-write, a backup - is marked destructive, needs a dbabrain key and asks for its own confirmation. The tools that only read answer without a key.

A record of every call

Your machine records each call - the tool, the server, who asked - in its own store, beside the metrics, backups and job runs the agent can read without collecting them again.

Set it up

Install, name your instances, add it to your agent

The MCP server runs on your machine and talks to the agent over stdin and stdout - nothing from DBA Brain goes on the network. claude.ai on the web or a phone reaches it through the connector instead (every step).

shell
pip install "dbabrain[oracle,mcp]"
dbabrain init
claude mcp add dbabrain --env DBABRAIN_HOME=D:/dbabrain -- dbabrain mcp serve

Between the second and the third line, your Oracle instances go into data/db_instances.json and their logins into the encrypted store: the MCP setup, and everything else DBA Brain does.

FAQ

Questions asked first

Does it install anything on the Oracle server?

No agent and no package. DBA Brain runs on a machine of its own and connects with the user you give it; the tools that read run plain queries against the data dictionary and the dynamic performance views.

Which Oracle versions?

From 12.1 the driver connects in thin mode, with nothing else installed; an older version takes the Oracle Client in thick mode, set per instance. An execution plan is not offered on Oracle: its EXPLAIN PLAN writes to a table, and the tools that read write nothing.

Does it work beyond Oracle?

The same tools answer for SQL Server (SQL Server MCP server), PostgreSQL (PostgreSQL MCP server) and MySQL, each with its own SQL. All 94 tools.

Can someone set it up for us?

Yes - setting up DBA Brain on your servers, and Oracle work in general, are among the DBA work we do: see what we do.