Cannot create SQL Always on Availabilty Group

Disco Pymp 1 Reputation point
2021-07-07T16:14:47.137+00:00

TITLE: Microsoft SQL Server Management Studio

------------------------------

Create failed for Availability Group 'DSQLTESTAG'. (Microsoft.SqlServer.Management.HadrModel)

For help, click: https://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=16.100.46367.54+(SMO-master-A)&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+AvailabilityGroup&LinkId=20476

------------------------------

ADDITIONAL INFORMATION:

An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)

------------------------------

Failed to add a node to the possible owner list of a Windows Server Failover Clustering (WSFC) resource (Error code 5079). The WSFC service may not be running or may not be accessible in its current state, or the specified cluster resource or node handle is invalid. For information about this error code, see "System Error Codes" in the Windows Development documentation.
Failed to designate the local availability replica of availability group 'DSQLTESTAG' as the primary replica. The operation encountered SQL Server error 41017 and has been terminated. Check the preceding error and the SQL Server error log for more details about the error and corrective actions.
Failed to create availability group 'DSQLTESTAG'. The operation encountered SQL Server error 41160 and has been rolled back. Check the SQL Server error log for more details. When the cause of the error has been resolved, retry CREATE AVAILABILITY GROUP command. (Microsoft SQL Server, Error: 41017)

For help, click: https://learn.microsoft.com/sql/relational-databases/errors-events/mssqlserver-41017-database-engine-error

------------------------------

BUTTONS:

OK

------------------------------

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
14,153 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Disco Pymp 1 Reputation point
    2021-07-07T18:21:33.927+00:00

    Exact same issue as below. no resolve on that issue.

    https://social.msdn.microsoft.com/Forums/azure/en-US/87302753-1dd5-4782-a83e-ae5472a2727f/unable-to-create-ag-in-2014-developer-license?forum=sqlkjmanageability

    I also see this in the cluster log -

    [Verbose] 00001a08.00001f08::2021/07/07-17:10:00.959 DBG [RHS] s_RhsRpcCreateResType(SQL Server Availability Group, hadrres.dll)
    [Verbose] 00001a08.00001f08::2021/07/07-17:10:00.961 ERR [RHS] s_RhsRpcCreateResType: (126)' because of 'Error loading resource DLL hadrres.dll.'

    0 comments No comments

  2. Disco Pymp 1 Reputation point
    2021-07-07T19:02:10.447+00:00

    Oh .... SQL Version below -

    Microsoft SQL Server 2014 (SP3-CU4-GDR) (KB4583462) - 12.0.6433.1 (X64) Oct 31 2020 02:54:45 Copyright (c) Microsoft Corporation Developer Edition (64-bit) on Windows NT 6.3 <X64> (Build 17763: ) (Hypervisor)

    0 comments No comments

  3. CathyJi-MSFT 22,331 Reputation points Microsoft Vendor
    2021-07-08T03:43:10.77+00:00

    Hi @Disco Pymp ,

    Did the replicas that will add to SQL AG are just stand alone SQL server instance, not in SQL Failover cluster instance environment?

    Did you check the windows cluster states and the states of the replicas that you will be add in AG as below screenshot.
    112820-screenshot-2021-07-08-114415.jpg

    112805-screenshot-2021-07-08-113800.jpg

    Please share us more message from SQL server error log. And more information from Cluster log.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.