Category: High Availability (HA)
-
DBA Scripts: Get Log Shipping Status
Log shipping secondary behind, or a 14420 or 14421 alert just fired? Run this on the monitor server to see the backup, copy and restore ages side by side and which job stopped.
Written by
-
SQL Server Replication Monitoring Scripts
This is the set I reach for when replication starts acting up. Latency creeping, agents stuck, or subscribers falling behind, these queries cut through the noise fast. I’ve used them in production environments for years. What’s Inside If you run transactional replication, keep these handy. They save time when things go sideways. For the full…
Written by
-
DBA Scripts: Get Replication Status
🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: High Availability A subscriber is showing stale data, or you need to know what this server replicates and to where before you change anything: run this on the Distributor and it lists every transactional and snapshot subscription with its status decoded, in one…
Written by
-
DBA Scripts: Get Replication Agent Status
🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: High Availability Publications Look Fine. Are the Agents Actually Keeping Up? Replication Status tells you what’s published and subscribed. It doesn’t tell you whether the jobs actually moving that data, the Log Reader Agent and the Distribution Agent, are keeping up, or whether…
Written by
-
DBA Scripts: Get Last Node Blip
🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: High Availability When Did This FCI Last Move, and Why On a Failover Cluster Instance (FCI), every node blip, planned or not, causes SQL Server to restart on whichever node picks it up. That restart resets sqlserver_start_time, which makes instance uptime itself a…
Written by
-
DBA Scripts: Get Mirroring Endpoint Health and Status
🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: High Availability Still Running Database Mirroring? Here’s What to Check Database Mirroring has been deprecated since SQL Server 2012, Always On Availability Groups are the supported replacement for any new deployment. But deprecated doesn’t mean gone: plenty of instances still run it, migrations…
Written by
-
DBA Scripts: Get AG Failover Readiness and Readable Secondary Usage
🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: High Availability Would a Failover Succeed Right Now, and Can Reads Reach the Secondary? A failover is coming, planned or not, and you need to know what it costs before anyone presses the button. Get-AgFailoverReadiness answers it per database, per replica: can it…
Written by
-
Understanding SQL Server AG Latency (AAG Latency Explained)
As a production SQL Server DBA, one of the fastest health checks I run on an Always On Availability Group is a latency check. AG latency is the delay between a transaction committing on the primary replica and that same transaction being hardened and redone on a secondary replica. If the secondary is behind, it…
Written by
-
Troubleshooting Database Mirroring Issues in SQL Server
Database Mirroring is deprecated, but you will still see it in many production environments. It was officially marked deprecated in SQL Server 2012 and has remained in that state for well over a decade. In my own career as a DBA, it has been “deprecated” the entire time, yet still widely deployed and fully supported.…
Written by
-
Creating SQL Logins on an Availability Group (AG) Environment
In an Availability Group, the databases fail over. Your SQL logins do not. For Windows domain logins, the SID is owned by AD, so you just create the login on each replica and it syncs up. For SQL logins, the SID is generated inside SQL Server. If the SID differs between replicas, the database user…
Written by
- RESOURCE_SEMAPHORE When SQL Server Is Nowhere Near Its Memory Cap
- Dynamic Data Masking: What a WHERE Clause Still Reveals
- DBA Scripts: Get Log Shipping Status
- SQL Server Row-Level Security: The Filter Does Not Stop Cross-Tenant Writes
- View the Definition of a Stored Procedure in SQL Server
- TempDB Is Full or Still Growing: Find What Is Using It, Right Now
- Backups & Recovery (17)
- DBA Scripts (152)
- High Availability (HA) (13)
- Installation & Configuration (49)
- Maintenance (25)
- Migration & Upgrades (14)
- Monitoring (9)
- Performance Tuning (37)
- Security (Encryption & Permissions) (21)
- Storage & Capacity (16)
- T-SQL Fundamentals (15)
- Troubleshooting (95)
- Wait Types (235)