Share via

Fail to form database cluster

Hennessy Wong 26 Reputation points
Jun 15, 2021, 9:47 AM

Hi all,
I am trying to form an availability group with SQL standard edition.
At the last step, my secondary replica cannot join to the Database with connection error message.
105812-failover-cluster.png105727-secondary-node.png

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,207 questions
Windows Server Clustering
Windows Server Clustering
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.Clustering: The grouping of multiple servers in a way that allows them to appear to be a single unit to client computers on a network. Clustering is a means of increasing network capacity, providing live backup in case one of the servers fails, and improving data security.
1,017 questions
0 comments No comments
{count} votes

Accepted answer
  1. AmeliaGu-MSFT 13,986 Reputation points Microsoft Vendor
    Jun 16, 2021, 7:33 AM

    Hi HennessyWong-8921,
    Welcome to Microsoft Q&A.
    This error may because the connection endpoint has been deleted or has not been started, or the port traffic is blocked.
    By default, AlwaysOn configures the database mirroring endpoints to use port 5022. We can query sys.tcp_endpoints on each replica to confirm which port is being used in your environment:

    select name, state_desc, port from sys.tcp_endpoints where type_desc='DATABASE_MIRRORING'  
    go  
    

    If you find the endpoint does not exist, please create it:

    create endpoint [Hadr_endpoint]  
    state=started  
    as tcp (listener_port = 5022, listener_ip = all)  
    for database_mirroring (role = all, authentication = windows negotiate, encryption = required algorithm aes)  
    go  
    

    And please make sure the port is started.

    Then we can create a new Inbound Port Rule for port 5022 on the Primary and both Secondary servers.
    Please refer to Create Availability Group Fails With Error 35250 and Fix SQL Server AlwaysOn Error: 35250 Failed to Join the Availability Group for more detail.
    If you have any question, please feel free to let us know.

    Best Regards,
    Amelia


    If the answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


2 additional answers

Sort by: Most helpful
  1. Ronen Ariely 15,191 Reputation points
    Jun 15, 2021, 10:07 AM

    Good day,

    I am trying to form an availability group with SQL standard edition

    Since you are speaking about using standard edition, I assume that you speak about the "Always On Basic Availability Groups", which is supported from version 2016 and above on Standard Edition. This feature has multiple limitations which can lead to this error. Please check the list of limitations in the official documentation first:

    https://learn.microsoft.com/en-us/sql/database-engine/availability-groups/windows/basic-availability-groups-always-on-availability-groups?view=sql-server-ver15#limitations


  2. Hennessy Wong 26 Reputation points
    Jun 16, 2021, 2:56 AM

    More screen shots have been uploaded.

    106026-dashboard.png106027-critial-issue.png

    0 comments No comments

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.