Activity: ReplicationSlotsyncShutdown
Waiting for slot sync worker to shut down
PostgreSQL wait event dossier
ClassActivity
Event
ReplicationSlotsyncShutdown
VersionsPG 17-18
Evidence2 source location(s)
Official description
Waiting for slot sync worker to shut down
| PG 13 | PG 14 | PG 15 | PG 16 | PG 17 | PG 18 |
|---|---|---|---|---|---|
| — | — | — | — | ✓ | ✓ |
Trigger mechanism
WAIT_EVENT_REPLICATION_SLOTSYNC_SHUTDOWN at src/backend/replication/logical/slotsync.c:1732 is the grep-verified reporting path. The public identity/resource is mapped at src/backend/utils/activity/wait_event_names.txt:66. The instrumented operation is: Waiting for slot sync worker to shut down. The ReplicationSlotsyncShutdown background path reports this event around its latch wait when its main loop has no immediate work. A signal, timeout, or new work clears the sleep and the process loops again.
Normal or trouble?
- Normal: This is normally expected idleness for the matching background process.
- Investigate: Investigate only when queued work or a shutdown/failover deadline is not advancing while the process remains here, or when the event appears on an unexpected backend type.
Diagnostic SQL
Sessions waiting on Activity/ReplicationSlotsyncShutdown
Current Activity cohort
Lock and relation context for these sessions
Response
- Match the row to backend_type.
- Inspect the process-specific backlog and last-progress timestamp.
- Fix the missing work signal or stalled upstream phase; do not kill a normally idle worker.
Source evidence
- PostgreSQL 18.6 · src/backend/replication/logical/slotsync.c:1732 —
WAIT_EVENT_REPLICATION_SLOTSYNC_SHUTDOWN - PostgreSQL 18.6 · src/backend/utils/activity/wait_event_names.txt:66 —
REPLICATION_SLOTSYNC_SHUTDOWN
Related controls and signals
- GUCs: None directly.
- Metrics: [metric:waiting_sessions] · [metric:wait_event_share]