Oracle DBA Starter Guide
A learning path for a junior Oracle DBA: what to run first, how to read the output and when to escalate.
1. Start here
2. Know your database
Instance, host and service
When to use it Before any other work, and whenever someone asks "which database is this?". Run th...
Processes and sessions limits
When to use it As part of the daily check, and first thing when users report that they cannot con...
Containers and PDBs
When to use it On any 12c or later database, to see whether you are in a container database and w...
3. Daily health check
Morning routine
Run these checks in this order at the start of the day. Each one links to a page of this guide. T...
Tablespace usage
When to use it Every day, and whenever an application fails with ORA-01653, ORA-01654 or ORA-0168...
Backups from last night
When to use it Every morning. A database without a recent good backup is the highest risk you can...
Invalid objects
When to use it Every day, and always after a deployment, a patch or an import. Run this Script: ...
Scheduler jobs running now
When to use it During the daily check, and when someone asks if a batch job is still running. Run...
4. Sessions and locks
Who is connected
When to use it When the number of sessions is high, when you need to know which application user ...
Finding blocking locks
When to use it When users say the application is frozen, a screen never returns, or a batch job s...
Killing a session safely
When to use it Only after you have identified the session, understood what it is doing, and recei...
5. Storage basics
Tablespaces and datafiles
When to use it When a tablespace is filling up and you need to see its files, sizes and whether t...
TEMP usage
When to use it When a query fails with ORA-01652 (unable to extend temp segment), or when you wan...
Redo logs
When to use it When the alert log shows "Checkpoint not complete", when commits are slow, or when...
Archive log generation
When to use it To learn the normal rhythm of a database, and when the archive destination or the ...
6. Users and security
Users, status and profiles
When to use it When a user cannot log in, when you are asked whether an account exists, or during...
Extracting user DDL and grants
When to use it When you need to recreate a user in another environment, document its access, or k...
Basic auditing
When to use it When you are asked who logged in, who failed to log in, or who changed an object. ...
7. Backup and recovery basics
Listing backups with RMAN
When to use it When you need to confirm from RMAN itself what backups exist, for example before m...
Archival errors
When to use it When the alert log shows an archiver error, sessions hang with ORA-00257, or the d...
Daily backup check: quick guide
The scripts search for the literal messages written by the backup job, Finalizado com successo (...
Daily backup check: full alias instructions
SCRIPT INSTALLATION 1. Copy the script to the server: # Create the directory if it does not exist...
8. Scheduler basics
9. First performance look
Before you start: licenses
Several performance features need extra licenses on Enterprise Edition. Using them without the li...
Finding the SQL_ID
When to use it When someone reports a slow screen or report and you need to find the statement be...
Seeing the execution plan
When to use it Once you have a SQL_ID and want to see how the database is running that statement....
SQL Monitor report
When to use it For a statement that is running right now for a long time, or ran recently, when y...
Memory: PGA per session
When to use it When the server is short of memory, when you see ORA-04036 (PGA limit exceeded), o...
When to escalate
Escalating early with good information is part of the job, not a failure. Use this page to decide...
10. When things break
A tablespace is full
When to use it An application fails with ORA-01653, ORA-01654, ORA-01688 or ORA-30036, or the dai...
The application is frozen
Use this playbook when several users report that screens do not respond. Work through it in order...
TNS-12520: cannot connect
When to use it New connections fail with TNS-12520 or ORA-12520 (listener could not find availabl...
Checkpoint not complete
When to use it The alert log repeats "Checkpoint not complete" or "cannot allocate new log", and ...
TEMP is full
When to use it Queries fail with ORA-01652 (unable to extend temp segment), usually reports or ba...
The database does not start
When to use it A STARTUP fails, most often right after a parameter change, with errors such as O...
11. Checklists and glossary
12. Linux basics for DBAs
Everyday Linux commands a DBA needs on the database server, plus the daily backup check.
Searching logs with grep
Everyday grep one-liners to find ERROR, ORA-, OutOfMemory and Java exceptions in a WildFly server...
Keeping long jobs alive with screen
Quick reference for creating, detaching, reattaching and closing screen sessions and windows. Use...
Disk full but nothing to delete: deleted files still open
lsof one-liners to list deleted-but-open files, sort them by size, total the space they hold per ...
Copying large files with rsync
Wrapper around rsync -av with named modes for a plain copy, resuming a stalled transfer, skipping...
13. Hands-on labs
Practical labs to train junior DBAs, run on lab VMs.