Create the Always On Availability Group

Before you begin

  • Create a cluster of the servers for which you want to create the AlwaysOn Availability group.
  • Ensure that the database servers in the cluster are user databases (not system databases) and are in the full recovery mode.
  • Ensure that a full backup has been performed on the server at least once.
  • Create a shared folder for all the servers that can be accessed by the SQL user.
  • Set up a scheduled transaction log backup job.

Procedure

  1. Log in to one of the SQL servers.
  2. Access the Availability Group Wizard window.
  3. Expand AlwaysOn High Availability.
  4. Right-click Availability Groups, and then select New Availability Group Wizard.
    The New Availability Group window appears, displaying the Introduction section.
  5. Select Next.
    The Specify Availability Group Name section appears.
  6. Enter a name for the group, and then select Next.
    The Select Databases section appears.
  7. Select the check boxes for the databases that you want to include in the group, and then select Next.
    The Specify Replicas section appears.
  8. Select Add Replica, add replicas for the servers, and then select Endpoints.
    Note:
    • You can set up automatic failover for a maximum of two replicas.
    • You can set up synchronous commit for a maximum of three replicas.
    The Endpoints subsection appears.
  9. In the Port Number column, provide an open port number for each server, and then select Listener.
    The Listener subsection appears.
  10. Provide values in the Listener DNS Name and Port boxes, add a static IP address, and then select Next.
    The Select Data Synchronization section appears.
  11. Select Full, and then provide the path of the shared folder, which will be used to store backup files while restoring data in the replicas at the initial stage.
  12. Select Next.
    The Validation section appears, displaying the results of the availability group validation.
  13. Select Next.
    The Summary section appears.
  14. Review the summary, and then select Finish.
    The AlwaysOn Availability group is created.