Wednesday, December 2, 2026

Important Database Global Monitoring Metrics

Below is the baseline I would use for Oracle 19c production databases, especially RAC/Data Guard environments.

1. Severity model

SeverityMeaningResponse
InformationalTrend/capacity informationDashboard/trending
WarningDegradation or approaching limitInvestigate
CriticalHigh risk / significant degradationUrgent
Fatal / AvailabilityService unavailable or data-protection riskImmediate incident

For capacity metrics, a useful baseline is:

  • Warning: 80%
  • Critical: 90%
  • Emergency operational threshold: 95%

But don't blindly use 80/90/95 for CPU, latency, Data Guard lag, backup age, etc.


2. Database availability: mandatory

MetricSuggested WarningCritical
Database Instance Statusn/aDown
Database Statusn/aNot Open
Listener Statusn/aDown
Service Availabilityn/aDown
Instance connectionn/aUnable to connect
PDB open staten/aRequired PDB not READ WRITE
Invalid/unexpected instance restartn/aAlert
Database uptime/restartMonitorUnexpected restart

These should be 24×7 alerts.


3. Tablespace / capacity

MetricWarningCritical
Tablespace used %80%90%
Tablespace used %90%95% for selected large tablespaces
Tablespace free GBenvironment-specificenvironment-specific
TEMP usage80%90–95%
UNDO usage/pressure80%90%
Datafile autoextend failuren/aImmediate
Datafile maximum-size proximity80%90–95%
Tablespace growthabnormalrapid growth
Database total sizeTrendTrend

Important: don't monitor only percentage.

For a 20 TB tablespace:

90% used = 2 TB remaining

which may be completely safe.

For a 20 GB tablespace:

90% used = 2 GB remaining

which may be urgent.

Therefore ideally alert on both:

% free + GB free + growth rate + time to exhaustion


4. FRA and archive logs

This is one of the most important Oracle-specific categories.

MetricWarningCritical
FRA utilization80%90%
FRA utilization emergency95%
Archive destination usage80%90%
Archive destination statusERRORCritical
Archiver stuckn/aCritical
Archive generation rateBaseline deviationMajor deviation
Archive log destination fulln/aCritical
Log switches/hourTrend/baselineAbnormal rate

I'd make FRA ≥95% a page/on-call event, particularly for production.


5. Performance

Monitor both utilization and Oracle workload.

CPU

MetricWarningCritical
Host CPU utilization>80% sustained 15 min>90% sustained 10 min
DB CPUBaselineabnormal sustained
CPU run queueBaselinesustained contention

Don't create a production incident just because CPU hits 95% for 30 seconds.

For CPU, duration is critical.


6. Oracle wait events

Monitor:

User I/O

db file sequential read
db file scattered read
direct path read
direct path write
direct path read temp
direct path write temp

Commit

log file sync
log file parallel write

Concurrency

enq: TX - row lock contention
library cache lock
library cache pin
cursor: pin S wait on X

RAC

gc cr request
gc current request
gc buffer busy acquire
gc buffer busy release

Don't normally alert because one wait event exists.

Monitor:

wait latency
+
wait time %
+
frequency
+
baseline deviation


7. SQL performance

This is essential for databases such as your IBM QM/E3 workloads.

Monitor:

  • Top SQL by elapsed time
  • Top SQL by CPU
  • Top SQL by physical reads
  • Top SQL by buffer gets
  • Top SQL by executions
  • SQL response-time degradation
  • SQL plan changes
  • New plan hash value
  • SQL using SQL Plan Baseline
  • Parse calls
  • Hard parsing
  • Invalidations
  • Version count
  • Long-running SQL
  • Parallel SQL

For business-critical SQL, use baseline deviation, for example:

Normal response: 2 sec
Warning: >4 sec
Critical: >10 sec

rather than one universal SQL-response threshold.


8. Sessions and processes

MetricWarningCritical
Sessions / SESSIONS limit80%90%
Processes / PROCESSES limit80%90%
Active sessionsBaselineabnormal sustained
Long-running session>30 min*>60 min*
Blocking session>5 min>15 min
Maximum blocking time5–10 min15 min
Failed logins>baselinerepeated failures

* depends heavily on workload.

A 2-hour RMAN session isn't necessarily problematic.

A business application's OLTP SQL running 30 minutes probably is.


9. Locking/blocking

Mandatory:

  • Blocking sessions
  • Long blockers
  • Row lock contention
  • Deadlocks
  • DDL locks
  • TX enqueue contention

Suggested:

Warning  = blocker >5 minutes
Critical = blocker >15 minutes

For highly critical OLTP databases you could tighten this to:

Warning  = 2 min
Critical = 5 min


10. Memory

Monitor:

SGA

  • SGA utilization
  • Shared Pool
  • Buffer Cache
  • Large Pool
  • Java Pool if used
  • Shared Pool free memory
  • Library cache pressure
  • Resize operations

PGA

  • PGA allocated
  • PGA aggregate limit
  • PGA cache hit %
  • Workarea executions
  • One-pass executions
  • Multipass executions
  • TEMP spill

Useful threshold:

PGA_AGGREGATE_LIMIT
Warning  = 80%
Critical = 90%


11. Redo / log switches

Monitor:

  • Redo generated/minute
  • Redo generated/hour
  • Log switches/hour
  • Log switch duration
  • Checkpoint issues
  • log file sync
  • log file parallel write
  • checkpoint not complete
  • redo allocation/retry pressure

Rather than defining "10 switches/hour is bad", establish a baseline.

For example:

Normal        5–15 switches/hour
Warning       >30/hour sustained
Investigation >60/hour

Those are operational examples, not universal Oracle thresholds.


12. TEMP

Monitor:

  • TEMP utilization %
  • Free TEMP
  • Active TEMP consumers
  • TEMP usage per session
  • TEMP growth
  • Sort-to-disk behavior

Suggested:

Warning  = 80%
Critical = 90%

But again combine percentage with GB remaining.


13. UNDO

Monitor:

  • UNDO utilization
  • Undo tablespace remaining
  • Undo retention
  • ORA-01555
  • unexpired/expired undo
  • longest-running query versus retention

Any ORA-01555 should generate an event worth investigating.


14. RMAN backup: absolutely mandatory

For production:

MetricWarningCritical
Last DB backup age>24/48 hpolicy-dependent
Failed RMAN backupImmediateCritical
Archivelog backup failureImmediateCritical
Backup durationbaseline +30%+50%
Backup sizeabnormal deviationmajor deviation
Obsolete backup buildupMonitorstorage risk
Recovery catalog issueWarningCritical
Restore validationscheduledfailure critical

Most importantly:

Do not equate successful backup with recoverability.

Periodically perform:

RMAN RESTORE VALIDATE

and recovery testing.


15. Data Guard

For every Data Guard production configuration monitor:

  • Primary/standby status
  • Transport lag
  • Apply lag
  • Redo transport status
  • Redo apply status
  • Archive gap
  • MRP process
  • RFS
  • Destination errors
  • Data Guard broker status
  • Fast-Start Failover status if used
  • Standby connectivity
  • Protection mode
  • Switchover readiness

Example baseline:

MetricWarningCritical
Apply lag>5 min>15 min
Transport lag>2 min>5 min
Archive gapPresentSustained
MRP stoppedn/aCritical
Standby unavailablen/aCritical

For high-RPO systems, these values need to be much tighter.


16. RAC

For Oracle RAC monitor:

Cluster

  • CRS availability
  • Cluster node status
  • Database instance status
  • Database service status
  • VIP status
  • SCAN listener
  • Local listener

Interconnect

  • Interconnect availability
  • Interconnect throughput
  • Packet errors/drops
  • latency

Cache Fusion

Monitor:

gc cr request
gc current request
gc buffer busy
global cache average CR block request time
global cache average current block request time

Also look for workload imbalance between nodes.

Example:

Node 1 CPU = 90%
Node 2 CPU = 30%

may indicate poor service/workload distribution even though the RAC database itself is healthy.


17. ASM

For ASM databases:

MetricWarningCritical
Diskgroup usage80%90%
Disk offlinen/aCritical
Disk failuren/aCritical
ASM instance unavailablen/aCritical
Rebalance activityMonitorabnormal duration
Usable file MBMonitorCritical minimum

Be careful with ASM percentage alone because redundancy and USABLE_FILE_MB matter.


18. Storage/I/O

Since you're also working with Pure Storage and IBM Power/AIX, I'd correlate Oracle with infrastructure metrics.

Monitor:

  • Read latency
  • Write latency
  • IOPS
  • throughput MB/s
  • queue depth
  • storage utilization
  • I/O wait
  • ASM disk latency

As practical investigation triggers:

<5 ms       normally healthy for many modern all-flash workloads
5–10 ms     investigate sustained latency
>10–20 ms   potentially significant

But use the actual array/SAN baseline. Don't turn those example figures directly into universal alerts.


19. AIX/Linux host monitoring

Oracle Enterprise Manager also supports infrastructure metrics through its plug-ins. 

Monitor:

CPU

  • CPU %
  • load/run queue
  • physical CPU consumed
  • entitlement usage for AIX
  • capped/uncapped CPU behavior

For AIX specifically:

physc
%entc
app

are much more informative than looking only at %user.

Memory

  • physical memory
  • paging
  • swap
  • paging-space utilization
  • Oracle process memory

Filesystems

  • /
  • /tmp
  • /var
  • Oracle home
  • Grid home
  • archive filesystem
  • backup mounts
  • audit filesystem

Baseline:

Warning 80%
Critical 90%
Emergency 95%


20. Oracle alert log

I'd make this mandatory.

Monitor ORA errors including:

ORA-00600
ORA-00700
ORA-07445
ORA-04031
ORA-01555
ORA-01652
ORA-01653
ORA-19809
ORA-19815
ORA-00257
ORA-03113
ORA-03135
ORA-00060

Also:

  • instance termination
  • corrupt block
  • datafile errors
  • control file issues
  • archive failures
  • ASM errors

ORA-00600, ORA-07445, corruption or database availability errors should normally result in immediate escalation.


21. Data integrity

Monitor:

  • invalid objects
  • unusable indexes
  • corrupted blocks
  • offline datafiles
  • recovery-required files
  • invalid database components
  • DBA_REGISTRY status
  • failed materialized view refreshes where applicable

Critical examples:

block corruption > 0
datafile requires recovery
SYSTEM/SYSAUX problem


22. Security

Monitor:

  • Failed logins
  • Locked accounts
  • Expiring accounts
  • DBA account changes
  • privilege grants/revokes
  • SYS connections where required
  • audit failures
  • invalid credentials
  • repeated authentication failures



Do not disable monitoring merely because traditional auditing has been disabled. Instead, decide whether failed-login monitoring is required by security/SOX controls.


23. Jobs and Scheduler

Monitor:

DBMS_SCHEDULER job failure
DBMS_JOB failure
job running longer than expected
missed scheduled jobs
broken jobs

Pay particular attention to operational jobs:

  • Statistics gathering
  • backup
  • purge
  • application batch
  • ETL
  • materialized view refresh

24. Statistics/optimizer health

Monitor or report:

  • stale statistics
  • missing statistics
  • failed AutoTask
  • statistics gathering duration
  • SQL plan changes
  • invalid SQL objects
  • hard parsing
  • cursor proliferation



25. OEM itself

Don't forget monitoring the monitoring system.

Monitor:

  • OEM Agent status
  • Agent unreachable
  • Agent upload problem
  • Metric collection error
  • DBSNMP credentials
  • Preferred credentials
  • OMS status
  • Repository availability
  • Metric collection age

Otherwise you can get a dangerous situation:

Database healthy?  Unknown
       ↑
OEM agent actually stopped collecting


Enterprise baseline recommendations 

Instead of giving every metric the same priority, I would implement this as P1/P2/P3 monitoring:

P1: availability/data protection

Immediately alert:

  • Database down
  • RAC instance down unexpectedly
  • Listener/service down
  • Data Guard apply stopped
  • significant Data Guard lag
  • archive destination failure
  • FRA >95%
  • backup failure
  • tablespace unable to extend
  • ASM diskgroup critical
  • corruption
  • critical ORA errors
  • OEM monitoring unavailable

P2: performance/capacity

Alert after sustained violation:

  • CPU
  • memory
  • I/O latency
  • tablespace
  • TEMP
  • sessions/processes
  • blocking
  • database response time
  • RAC waits
  • archive/redo growth
  • SQL degradation

P3: proactive DBA health

Dashboard/daily review:

  • DB growth
  • tablespace growth rate
  • capacity forecast
  • stale stats
  • invalid objects
  • SQL plan change
  • top SQL changes
  • index health where justified
  • backup duration trend
  • redo generation trend
  • performance baseline drift

This is important because Oracle Enterprise Manager Cloud Control supports warning/critical threshold evaluation and consecutive-occurrence behavior. That lets you suppress transient spikes instead of generating incidents from every short threshold crossing. 

The standard I would build

For an estate like yours, I would create separate OEM Metric Templates:

ORACLE_PROD_STANDARD
ORACLE_NONPROD_STANDARD
ORACLE_RAC_PROD
ORACLE_DG_PRIMARY
ORACLE_DG_STANDBY
ORACLE_ASM
HOST_AIX_PROD


About the Author : Anurag Pandey | Database cloud Architect | Oracle | SQL Server | PostgreSQL | AI and Data Platform Enthusiast

Anurag Pandey is a Database Architect with expertise in Oracle, PostgreSQL, SQL Server, Linux, and enterprise database platforms and specializes in database architecture, performance tuning, high availability, disaster recovery, cloud modernization, and operational excellence. With extensive experience in enterprise-scale environments, Anurag is passionate about leveraging AI, automation, and modern data platforms to improve reliability, scalability, and business outcomes. He actively contributes to technical communities through knowledge sharing, architecture guidance, and thought leadership in database and data engineering domains.

Follow more articles at

Visit Blog

Wednesday, November 25, 2026

Oracle RAC vs RAC One Node

Oracle RAC One Node is best understood as Oracle RAC infrastructure with only one active database instance at a time, plus the ability to relocate that instance to another RAC node with minimal interruption.

1. RAC One Node architecture

A typical 2-node configuration looks like this:

                    Applications
                         |
                 SCAN / Connect String
                         |
              +----------+----------+
              |                             |
         Node 1                     Node 2
     +----------------+        +----------------+
     | Grid Infra     |        | Grid Infra     |
     | ASM            |          | ASM            |
     | DB Instance    |        |                |
     | DB1_1 ACTIVE   |        | Standby Node   |
     +-------+--------+        +-------+--------+
                 \                          /
                   \                      /
               +---------------------+
               |   Shared Storage      |
               | ASM Disk Groups      |
               | DATA / RECO / OCR   |
               +---------------------+

The critical point is:

Both servers are members of the RAC cluster, but normally only one RAC One Node database instance is running.

This is fundamentally different from traditional RAC, where multiple instances of the same database normally run simultaneously.


2. Main components

Oracle Grid Infrastructure

Both nodes run Oracle Grid Infrastructure, including:

  • Oracle Clusterware
  • ASM
  • CRS
  • SCAN
  • VIPs
  • Cluster resources

So the underlying infrastructure is still a proper RAC cluster.

Shared storage

Both nodes access the same database storage, normally through ASM:

             +-------------------+
             |   Shared Storage  |
             +-------------------+
                 /            \
                /               \
          +---------+       +---------+
          | Node 1  |       | Node 2  |
          | ASM     |       | ASM     |
          +---------+       +---------+

The database does not need to copy its datafiles from Node 1 to Node 2 when relocating.

Both nodes already have access to:

  • Datafiles
  • Control files
  • Online redo logs
  • SPFILE
  • FRA
  • ASM disk groups

3. Normal operation

Suppose you have:

Cluster: PROD-CLUSTER
Node 1: server01
Node 2: server02
Database: PROD

During normal operation:

Node 1                                 Node 2
------                                     ------
Clusterware                    Clusterware
ASM                                    ASM


PROD_1
  |
  +-- Active
  |
Application
connections

The database workload is handled by PROD_1 on Node 1.

Node 2 remains available as another possible location for the database.


4. What happens during relocation?

This is one of the biggest advantages of RAC One Node.

Suppose Node 1 needs:

  • OS patching
  • Hardware maintenance
  • Firmware upgrade
  • Grid Infrastructure maintenance
  • Planned server shutdown

Instead of stopping the application database for a long maintenance window, you can relocate the database.

Conceptually:

BEFORE
Node 1                                 Node 2
PROD_1 ACTIVE           No PROD instance

            Relocate
               --->

DURING RELOCATION

Node 1                 Node 2
PROD_1 ACTIVE           PROD_2 starts
   \                                 /
     \ _________________/
          temporary
          overlap


AFTER

            Node 1                     Node 2
No PROD instance        PROD_2 ACTIVE

Oracle calls this capability Online Database Relocation.

The temporary overlap is important. During a planned online relocation, another instance can temporarily start on the destination node to facilitate the transition.

That does not make it regular active-active RAC operation.


5. RAC vs RAC One Node

This distinction is extremely important.

FeatureRACRAC One Node
Cluster nodesMultipleMultiple
Active DB instancesMultipleNormally one
Shared storageYesYes
ASMCommonlyCommonly
ClusterwareYesYes
Active-active DBYesNo
Workload across nodesYesNormally one node
Instance relocationYesCore capability
Horizontal DB scalingYesLimited
Server maintenance flexibilityExcellentExcellent
Cache FusionNormal operationLimited significance with single active instance

Think of it like this:

RAC

Application
     |
 +---+---+
 |         |
DB1     DB2
 |            |
Node1   Node2
      /        /
 Shared DB

Both database instances actively service the same database.

RAC One Node

Application
     |
    DB1
     |
   Node1
     |
 Shared DB
     |
   Node2
 potential relocation target


6. What happens if the active node crashes?

Suppose the database is running on Node 1:

Node 1                      Node 2
PROD active                 Available
   X
Node failure

Clusterware detects the failure and can restart the database instance on the surviving node:

Node 1                      Node 2
FAILED                      PROD
                            Restarted
                              |
                            ACTIVE

There will still be an interruption because the instance has to be recovered/start on the surviving node.

Therefore:

RAC One Node provides high availability, but it isn't the same as active-active RAC where another database instance is already running and serving the database.


7. Planned vs unplanned event

There is an important architectural difference.

Planned relocation

For maintenance:

Node 1                     Node 2
Instance A                 Instance B
ACTIVE   ------->          STARTS
   &nbsp;                       /
    +---- transition ------+

This is designed to reduce application disruption.

Unplanned Node 1 failure

Node 1                     Node 2
Instance A
   |
   X
FAILED
                             |
                             v
                       Instance restart
                             |
                       Instance recovery
                             |
                           OPEN

The application experiences an outage while failover/recovery occurs.

Actual recovery time depends heavily on workload, redo volume, storage latency, Fast Application Notification/client configuration, and instance recovery settings.


8. RAC One Node vs Data Guard

As a Database Architect, this distinction is particularly important when designing HA/DR.

RAC One Node

Protects mainly against:

  • Server failure
  • OS problems
  • Planned server maintenance
  • Some hardware failures

But the nodes normally share the same storage/database.

Data Guard

Provides another database:

Primary Site
     |
   PROD
     |
     | Redo
     v
Standby Site
     |
  PROD_DR

Data Guard protects against much broader failure scenarios, especially when the standby is in a separate fault domain/site.

Therefore a strong architecture can be:

             PRIMARY DC
        RAC One Node Cluster
       +---------------------+
       |                     |
    Node 1                Node 2
        \                      /
          \                  /
           PROD Database
                |
                |
            Data Guard
                |
                v
                DR DC
        RAC One Node Cluster
       +---------------------+
       |                     |
    Node 3                Node 4
       \                     /
         \                 /
      PROD Standby

This separates two requirements:

  • RAC One Node = local HA / mobility
  • Data Guard = database/site-level DR

9. Why would you choose RAC One Node instead of RAC?

This is where RAC One Node can be attractive for an enterprise database estate.

Imagine a cluster with powerful servers:

Node 1
  PROD1
  PROD2
  PROD3

Node 2
  PROD4
  PROD5
  PROD6

Each database runs as a single active instance, but Clusterware can relocate databases between the nodes.

This provides:

Consolidation

Multiple databases can share the RAC cluster infrastructure.

Maintenance flexibility

Before maintenance:

Node 1                Node 2
PROD1   ------------> PROD1
PROD2   ------------> PROD2

Then perform maintenance on Node 1.

Workload mobility

You can redistribute databases between servers.

Reduced complexity compared with active-active RAC

Applications don't necessarily need the same scale-out model that true RAC is designed to provide.


10. One important misconception

People sometimes interpret RAC One Node as:

"Oracle database running on one standalone server with another cold standby."

That's not quite correct.

The architecture still uses Oracle RAC/Clusterware infrastructure.

The better mental model is:

A RAC-enabled database constrained to run primarily as a single active instance, with the capability to move between cluster nodes.


Architecture decision

Choose RAC One Node when:

  • You need local HA.
  • One server can comfortably support the entire database workload.
  • You want planned online relocation.
  • You have several databases to consolidate.
  • You don't need multiple active instances for scale-out.

Choose full RAC when:

  • A single server isn't enough.
  • Multiple instances need to process workload concurrently.
  • You need scale-out across cluster nodes.
  • Application/database workload justifies RAC complexity.

Add Data Guard when:

  • You need DC/site protection.
  • You need a geographically separated DR database.
  • Storage/cluster failure must also be protected against.

Normally treat RAC One Node as an HA/consolidation decision and Data Guard as a DR decision, rather than viewing one as a replacement for the other.

About the Author : Anurag Pandey | Database cloud Architect | Oracle | SQL Server | PostgreSQL | AI and Data Platform Enthusiast

Anurag Pandey is a Database Architect with expertise in Oracle, PostgreSQL, SQL Server, Linux, and enterprise database platforms and specializes in database architecture, performance tuning, high availability, disaster recovery, cloud modernization, and operational excellence. With extensive experience in enterprise-scale environments, Anurag is passionate about leveraging AI, automation, and modern data platforms to improve reliability, scalability, and business outcomes. He actively contributes to technical communities through knowledge sharing, architecture guidance, and thought leadership in database and data engineering domains.

Follow more articles at

Visit Blog

Saturday, November 14, 2026

PostgreSQL Process Architecture Diagram and Details


PostgreSQL Process Architecture Diagram

                           +------------------+
                           |    POSTMASTER    |
                           |   (Parent PID)   |
                           +---------+--------+
                                     |
       ----------------------------------------------------------------
       |            |            |            |            |            |
       v            v            v            v            v            v
+-------------+ +-----------+ +-----------+ +-----------+ +---------+ +---------+
| Background  | | WAL       | |Checkpointer| | Autovac  | | Archiver| | Startup |
| Writer      | | Writer    | |           | | Launcher | |         | | Process |
+-------------+ +-----------+ +-----------+ +-----------+ +---------+ +---------+
                                                        |
                                            ----------------------
                                            |         |          |
                                            v         v          v
                                      +----------+ +----------+ +----------+
                                      |Vacuum W1 | |Vacuum W2 | |Vacuum W3 |
                                      +----------+ +----------+ +----------+
                                        Client Connections
                                                |
       ----------------------------------------------------------------
       |                 |                    |                  |
       v                 v                    v                  v
+--------------+ +--------------+ +--------------+ +--------------+
| Backend PID  | | Backend PID  | | Backend PID  | | Backend PID  |
| User Session | | User Session | | User Session | | User Session |
+--------------+ +--------------+ +--------------+ +--------------+
Shared Memory:
--------------------------------------------------------
| Shared Buffers | WAL Buffers | Locks | Proc Array |
--------------------------------------------------------


How to See PostgreSQL Processes at OS Level

Find Postmaster (Parent Process)

ps -ef | grep postgres

Example:

postgres  1000     1  0 10:00 ? 00:00:00 postgres
postgres  1001  1000  0 10:00 ? 00:00:00 postgres: checkpointer
postgres  1002  1000  0 10:00 ? 00:00:00 postgres: background writer
postgres  1003  1000  0 10:00 ? 00:00:00 postgres: walwriter
postgres  1004  1000  0 10:00 ? 00:00:00 postgres: autovacuum launcher

Notice:

PID 1000 = Parent Process
PPID 1   = Started by OS

This is the Postmaster.


Better Process Tree

Linux

pstree -p | grep postgres

Example:

postgres(1000)
 ├─postgres(1001)
 ├─postgres(1002)
 ├─postgres(1003)
 ├─postgres(1004)
 ├─postgres(1200)
 ├─postgres(1201)
 └─postgres(1202)

Much easier to visualize.


1. Postmaster

Responsibility

  • Starts all PostgreSQL processes
  • Accepts client connections
  • Handles crash recovery
  • Monitors child processes

Check:

ps -fp <postmaster_pid>

Example:

ps -fp 1000


If Backend Crashes

Backend dies
      ↓
Postmaster detects
      ↓
May restart required processes

Postmaster acts like a supervisor process.


2. Backend Process

Every client connection gets a backend process.

Connect:

psql postgres

Run:

SELECT pg_backend_pid();

Example:

  pg_backend_pid
-----------------
      14567

At OS level:

ps -fp 14567

Output:

postgres: appuser mydb 10.0.0.10 idle


Find Active Queries

SELECT pid,
       usename,
       state,
       query
FROM pg_stat_activity;

Map PID to Linux:

top -Hp <pid>

or

ps -fp <pid>


3. WAL Writer

Responsibility

Writes WAL buffers to:

$PGDATA/pg_wal

Process appears as:

postgres: walwriter

Check:

ps -ef | grep walwriter

Example:

postgres 1003 1000 0 ? postgres: walwriter


Observe WAL Activity

Inside PostgreSQL:

SELECT *
FROM pg_stat_wal;

Important metrics:

wal_records
wal_fpi
wal_bytes


4. Checkpointer

Responsibility

Writes dirty pages from memory to data files.

Process:

postgres: checkpointer

View:

ps -ef | grep checkpointer


Monitor

SELECT *
FROM pg_stat_bgwriter;

Interesting columns:

checkpoints_timed
checkpoints_req
checkpoint_write_time
checkpoint_sync_time


5. Background Writer

Responsibility

Gradually writes dirty buffers before checkpoint.

Goal:

Reduce checkpoint spikes

Process:

postgres: background writer

Check:

ps -ef | grep "background writer"


Why Important

Without BGWriter:

Checkpoint writes millions of dirty pages

causing:

High I/O
Slow performance


6. Autovacuum Launcher

Responsibility

Monitors all databases.

Starts worker processes when necessary.

OS command:

ps -ef | grep autovacuum

Example:

postgres: autovacuum launcher


7. Autovacuum Workers

Process:

postgres: autovacuum worker

Check:

ps -ef | grep "autovacuum worker"

Example:

postgres: autovacuum worker mydb


Monitor Current Vacuum

SELECT *
FROM pg_stat_progress_vacuum;

Output:

pid
phase
heap_blks_total
heap_blks_scanned


8. Archiver Process

Only if:

archive_mode = on

Process:

postgres: archiver

Check:

ps -ef | grep archiver


Monitoring

SELECT *
FROM pg_stat_archiver;

Example:

archived_count
failed_count


9. Startup Process

Visible during:

Database startup
Crash recovery
Standby recovery

OS:

ps -ef | grep startup

Example:

postgres: startup recovering


During Recovery

Logs:

tail -f $PGDATA/log/postgresql.log

Example:

redo starts at ...
redo done at ...


10. WAL Sender

Primary Server Replication.

Process:

postgres: walsender

Check:

ps -ef | grep walsender


Monitoring

SELECT *
FROM pg_stat_replication;

Example:

application_name
client_addr
state
sync_state


11. WAL Receiver

Standby Server.

Process:

postgres: walreceiver

OS:

ps -ef | grep walreceiver


Monitoring

SELECT *
FROM pg_stat_wal_receiver;


Real Production Troubleshooting

Check Entire Process Architecture

ps -ef | grep postgres


Check Process Tree

pstree -p | grep postgres


Check CPU Consumer

top -p $(pgrep postgres | tr '\n' ',')


Match PostgreSQL PID with Query

SELECT pid,
       usename,
       state,
       wait_event,
       query
FROM pg_stat_activity;

Then:

ps -fp <pid>


Check Shared Memory

ipcs -m

Or:

cat /proc/<postmaster_pid>/status


Oracle vs PostgreSQL Process Mapping

PostgreSQLOracle
PostmasterPMON (roughly supervisor role)
Backend ProcessDedicated Server Process
WAL WriterLGWR
CheckpointerCKPT
Background WriterDBWR
Startup RecoverySMON
WAL SenderData Guard Transport
WAL ReceiverManaged Recovery Process
ArchiverARCn
AutovacuumNo direct equivalent

Interview Answer (2-Minute Version)

PostgreSQL uses a process-based architecture. The Postmaster is the parent process that starts and monitors all child processes. For each client connection, a dedicated backend process is created. Key background processes include WAL Writer (writes WAL records for durability), Checkpointer (flushes dirty pages to disk), Background Writer (reduces checkpoint I/O spikes), Autovacuum Launcher and Workers (clean dead tuples and freeze old rows), Archiver (archives WAL files), and WAL Sender/Receiver (streaming replication). At the OS level these can be viewed using commands such as:

ps -ef | grep postgres
pstree -p | grep postgres
top -H -p <pid>

and correlated with database views like:

pg_stat_activity
pg_stat_progress_vacuum
pg_stat_replication
pg_stat_bgwriter






About the Author : Anurag Pandey | Database cloud Architect | Oracle | SQL Server | PostgreSQL | AI and Data Platform Enthusiast

Anurag Pandey is a Database Architect with expertise in Oracle, PostgreSQL, SQL Server, Linux, and enterprise database platforms and specializes in database architecture, performance tuning, high availability, disaster recovery, cloud modernization, and operational excellence. With extensive experience in enterprise-scale environments, Anurag is passionate about leveraging AI, automation, and modern data platforms to improve reliability, scalability, and business outcomes. He actively contributes to technical communities through knowledge sharing, architecture guidance, and thought leadership in database and data engineering domains.

Follow more articles at

Visit Blog

Important Database Global Monitoring Metrics

Below is the baseline I would use for Oracle 19c production databases , especially RAC/Data Guard environments. 1. Severity model Severity M...