Sunday, February 9, 2025

How has the SQL Server Always On Availability Group (AG) synchronized the Security Objects Across Replicas (2012 - 2025)?- Part VI

6. SQL Server 2022 - Contained Availability Groups (CAGs)


Breakthrough Feature:
Contained Availability Groups (CAGs): Store logins, credentials, and linked servers within the AG itself.
Eliminates the need for manual login synchronization.

Steps:
Create a Contained AG

CREATE AVAILABILITY GROUP MyAG
WITH (CONTAINED = ON)
FOR DATABASE MyDB;

Create a Contained User

CREATE LOGIN [SQLUser] WITH PASSWORD = 'Password', CHECK_POLICY = OFF;

Advantages:
Logins, credentials, and permissions are now part of the AG.
No need to manually recreate logins on secondary replicas.

Limitations:
Works only for new AGs created with Contained = ON.

No comments:

Post a Comment

Cloud-Based PostgreSQL vs. On-Premises/Hybrid: A Comprehensive Guide to Modern Database Deployment Strategies

  Introduction: The Evolving Landscape of PostgreSQL Deployment In the rapidly accelerating world of data-driven applications, the choice of...