Install and configure SQL AlwaysON AG with Listener on Azure

Configuring the Nodes - Security

On each node, perform the following

Local Administrators

net localgroup administrators domain.com\svc-acc /add

Before:
localadmin_before
After:
localadmin_after

SQL Security

Add the service account user to sysadmin role on SQL server.

USE MASTER
GO

CREATE LOGIN [domain.com\svc-acc] FROM WINDOWS;
GO

ALTER SERVER ROLE sysadmin ADD MEMBER [domain.com\svc-acc] ;  
GO

Before:
sql_security_before
After:
sql_security_after

SQL Service Accounts

Alter services so they use the service accounts you created. Launch and elevated Command Prompt and execute the following:

sc.exe config "MSSQLSERVER" obj= "its\svc-azrsqlstg-acc" password= "P@ssword"
sc.exe config "SQLSERVERAGENT" obj= "its\svc-azrsqlstg-acc" password= "P@ssword"

net stop MSSQLSERVER /y
net start SQLSERVERAGENT

Before:
sql_service_before
Execute:
sql_service_execute
After:
sql_service_after

The following needs to be performed on each node in the cluster, plus each additional node that gets added.

Leave a Reply

Your email address will not be published. Required fields are marked *

*
*