EASYHA SQL SERVER V1.0

Similar documents
SQL Server AlwaysOn setup on ObserveIT environment

SQL AlwaysOn - Skype for Business

DOWNLOAD PDF SQL SERVER 2012 STEP BY STEP

Implementation of Microsoft SQL Server using AlwaysOn for High Availability and Disaster Recovery without Shared Storage

EASYSECURITY SYMANTEC V1.0

Introduction Chapter 1. General Information Chapter 2. Servers Used... 9

Microsoft SQL AlwaysOn and High Availability

Are AGs A Good Fit For Your Database? Doug Purnell

Configuring ApplicationHA in VMware SRM 5.1 environment

EASYLAMP REDHAT V1.0 DOCUMENT OWNER: OUDHUIS, JONATHAN INGRAM MICRO CLOUD EUROPE

Installing SQL Server 2016 Cluster

Installing PI AF with SQL Server 2012 AlwaysOn Availability Group Feature. Version 1.0

Index. Peter A. Carter 2016 P.A. Carter, SQL Server AlwaysOn Revealed, DOI /

EASYLAMP UBUNTU V1.0 DOCUMENT OWNER: OUDHUIS, JONATHAN INGRAM MICRO CLOUD EUROPE

Tableau Server on Microsoft Azure:

Microsoft SQL AlwaysOn and High Availability

StarWind Virtual SAN Configuring HA Shared Storage for Scale-Out File Servers in Windows Server 2012R2

StarWind Virtual SAN SQL Server HADR using Availability Groups and Failover Cluster Instance

StarWind Virtual SAN AWS EC2 Deployment Guide

StarWind Virtual SAN Configuring HA SMB File Server in Windows Server 2016

Configuring AWS for Zerto Virtual Replication

NTP Software File Auditor for Windows Edition

Databases in Azure Practical Exercises

StarWind Virtual SAN Configuring HA Shared Storage for Scale-Out File Servers in Windows Server 2016

Installation Guide Worksoft Certify

Quick Start Guide For Ipswitch Failover v9.0.1

Installing DPM 2012 R2

StarWind Virtual SAN Installing and Configuring SQL Server 2017 Failover Cluster Instance on Windows Server 2016

Configure DHCP for Failover Step-by-Step.

Dell Storage Compellent Integration Tools for VMware

StarWind Virtual SAN Installing & Configuring a SQL Server 2012 Failover Cluster

StarWind Virtual SAN Compute and Storage Separated 2-Node Cluster. Creating Scale- Out File Server with Hyper-V.

Microsoft Windows Server Failover Clustering (WSFC) and SQL Server AlwaysOn Availability Groups on the AWS Cloud: Quick Start Reference Deployment

StarWind Virtual SAN Installing and Configuring SQL Server 2019 (TP) Failover Cluster Instance on Windows Server 2016

StarWind Virtual SAN. Installing and Configuring SQL Server 2014 Failover Cluster Instance on Windows Server 2012 R2. One Stop Virtualization Shop

DefendX Software Control-Audit for Hitachi Installation Guide

Dell EMC Avamar for SQL Server

Dell EMC Avamar for SQL Server

MX-Contact Instruction Sheet Setting up SQL Replication SQL 2005

Deploying a System Center 2012 R2 Configuration Manager Hierarchy

REDCENTRIC SQL SERVER PLUG-IN 8.3 USER GUIDE

NTP Software File Auditor for Hitachi

Setting up EntraPass Card Gateway with SQL Server 2008

Extend On-Premises Windows Server 2016 Active Directory to Azure VM Complete Lab (V1.1)

Dell EMC Ready Architectures for VDI

Installation. Installation Overview. Installation and Configuration Taskflows CHAPTER

Deploying HP SIM 6.x on MSCS clusters on Windows 2008 with SQL Server 2008 SP1 White Paper

SQL Server Availability Groups

StarWind Virtual SAN Compute and Storage Separated with Windows Server 2012 R2

Windows Clustering 101

Workshare Protect Server 3.9 on Microsoft Azure. Admin Guide

StarWind Virtual SAN Installation and Configuration of HyperConverged 2 Nodes with Hyper-V Cluster

Getting Started with VMware View View 3.1

StarWind Virtual SAN Compute and Storage Separated with Windows Server 2016

Dell Storage Integration Tools for VMware

StarWind Native SAN for Hyper-V:

Storage Manager 2018 R1. Installation Guide

StarWind Virtual SAN Hybrid Cloud for Azure

Installing SQL Server Developer Last updated 8/28/2010

StarWind Virtual SAN Installing and Configuring SQL Server 2012 Failover Cluster Instance on Windows Server 2012

29 March 2017 SECURITY SERVER INSTALLATION GUIDE

Ryan Adams Blog - Twitter Thanks to our Gold Sponsors

Quest VROOM Quick Setup Guide for Quest Rapid Recovery for Windows and Quest Foglight vapp Installers

Introduction. How Does it Work with Autodesk Vault? What is Microsoft Data Protection Manager (DPM)? autodesk vault

Virtual Appliance User s Guide

Maximizing SharePoint Availability Whitepaper v1.1 4/2018

Implementing Microsoft Azure Infrastructure Solutions

Sophos Enterprise Console advanced startup guide

Migration WordPress to Azure using Azure Site Recovery (ASR)

HR-Lite Database & Web Service Setup Guide

EXPRESSCLUSTER X 4.0. HA Cluster Configuration Guide for Microsoft Azure (Windows) April 17, st Edition

Reliable High-Speed Connection to Publication Database for Synchronization

StarWind Virtual SAN 2-Node Stretched Hyper-V Cluster on Windows Server 2016

The Balabit s Privileged Session Management 5 F5 Azure Reference Guide

PHD Virtual Backup Exporter. version 6.5 Users Guide. Document Release Date: August 26,

StarWind Virtual SAN Compute and Storage Separated 3-Node Setup with Hyper-V

Application Notes for Installing and Configuring Avaya Control Manager Enterprise Edition in a High Availability mode.

DOCUMENTATION. UVM Appliance Azure. Quick Start Guide

Installing SQL Server 2012 Cluster

Azure for On-Premises Administrators Practice Exercises

HC3 Move Powered by Double-Take Quick Start Guide

NTP Software Defendex (formerly known as NTP Software File Auditor) for NetApp

Using AWS Data Migration Service with RDS

Quest VROOM Quick Setup Guide for Quest Rapid Recovery for Windows and Quest Foglight vapp Installers

Silver Peak EC-V and Microsoft Azure Deployment Guide

Dell Storage Manager 2016 R3 Installation Guide

Install Part I - Virtual - Install and Power-on the SecureAuth IdP 9.0 Virtual Appliance

Floating on a Hybrid Cloud: SQL Server 2014 & Microsoft Azure Timothy P. McAliley Microsoft Premier Field Engineer SQL Server May 8, 2014

x10data Application Platform v7.1 Installation Guide

Infrastructure Provisioning with System Center Virtual Machine Manager

Installation Guide Worksoft Analyze

Microsoft Azure Windows Server Microsoft System Center

NE Infrastructure Provisioning with System Center Virtual Machine Manager

Demo Lab Guide 4Ward Cloud In-A- Box

User Manual. Active Directory Change Tracker

StarWind Native SAN Configuring HA File Server for SMB NAS

KYOCERA Net Admin Installation Guide

Remote Indexing Feature Guide

INSTALLATION GUIDE Spring 2017

StarWind Virtual SAN. Installing and Configuring a SQL Server 2014 Multi-Subnet Cluster on Windows Server 2012 R2

Transcription:

EASYHA SQL SERVER V1.0

CONTENTS 1 Introduction... 2 2 Install SQL 2016 in Azure... 3 3 Windows Failover Cluster Feature Installation... 7 4 Windows Failover Clustering Configuration... 9 4.1 Configure a file share witness... 15 5 Enable AlwaysOn... 18 6 Creating Availability Groups... 20 10/9/2017 EasyHA SQL Server 1

1 INTRODUCTION Microsoft Azure virtual machines (VMs) with SQL Server can help lower the cost of a high availability and disaster recovery (HADR) database solution. Most SQL Server HADR solutions are supported in Azure virtual machines, both as Azure-only and as hybrid solutions. In an Azure-only solution, the entire HADR system runs in Azure. In a hybrid configuration, part of the solution runs in Azure and the other part runs on-premises. The flexibility of the Azure environment enables you to move partially or completely to Azure to satisfy the budget and HADR requirements of your SQL Server database systems. This document will guide you through the steps of setting up a virtual machine with SQL Server Standard 2016 and the feature AlwaysOn enabled for a single database to a secondary server in Azure (see figure above). If you want more advanced replication features (multiple databases, multiple copies) the Enterprise edition of SQL is required. To work with SQL clustering, some technical background and knowledge about both SQL and clustering is needed. There are two prerequisites for the proper functioning of this script: A working site to site VPN to Azure Have routing between your on-premises network and the Azure network you ll deploy the SQL server to. Ensure proper implementation of these items before continuing. 10/9/2017 EasyHA SQL Server 2

2 INSTALL SQL 2016 IN AZURE On the Hub Menu, click [+], [Compute], and search for [SQL Database]. In the showing list, select [SQL Server 2016 SP1 Web on Windows Server 2016] and select [Create]: On the [Basics] blade, choose a [Name], [VM disk type], an [User name] to access the server, type a [Password] and [Confirm password], choose the right [Subscription] and use an existing [Resource group] or create a new one. Choose the closest [Location] to you. 10/9/2017 EasyHA SQL Server 3

On [Size] blade, choose an appropriate VM size. In this example we have chosen a very basic configuration to show the SQL Always On feature with a small database. For more advanced configurations, change the size accordingly: On the [Settings] blade, verify [Use managed disks] is set to Yes. The [Virtual Network] and [Subnet] fields are in accordance with the values set in the prerequisite. You do not need to set a public IP so click on the [Public IP Address] field and select the [None] option. Make sure that the [None] option is selected in the [Availability set] field and that diagnostics is Disabled. Then click [OK]. 10/9/2017 EasyHA SQL Server 4

On [SQL Server Settings], choose [SQL connectivity] and change the setting to Public (Internet), do not change the default [Port] for SQL Server. Enable [SQL Authentication] only if your application requires to. When enabled, it will use the same login you have created before. Do not make changes on the other fields, unless you want to change the schedule of [Automated patching]. On the [Summary] check the information and click [OK] 10/9/2017 EasyHA SQL Server 5

After its creation, click [Tags], then type [EasyAzure] on both fields [Key] [Value], then click [Save] and wait for its conclusion. Then select [Networking]. The internal IP address linked to this new machine will appear on the right blade. Write down the number for the next steps: ***Connect to the server, install the latest update, join the server to your Windows domain and configure a SQL Server service account with a domain user before continuing*** 10/9/2017 EasyHA SQL Server 6

3 WINDOWS FAILOVER CLUSTER FEATURE INSTALLATION Since AlwaysOn Availability Groups require a Windows Server Failover Cluster, we first need to add the Windows Failover Cluster Feature to all the machines running the SQL Server instances that we will configure as replicas. For the operating system, we will be using Windows Server 2016. To add the Failover Clustering feature: 1. Open the [Server Manager] console and select [Add roles and features]. This will launch the [Add Roles Features Wizard]. 2. Click [Next] until you reach the [Select Features] dialog box. Select the [Failover Clustering] checkbox. When prompted with the [Add features that are required for Failover Clustering] dialog box, click [Add Features]. Click [Next]. 10/9/2017 EasyHA SQL Server 7

10/9/2017 EasyHA SQL Server 8

4 WINDOWS FAILOVER CLUSTERING CONFIGURATION 1. Make sure you signed in with a domain account that has administrative privileges on both soon to be Cluster Nodes. Launch [Failover Cluster Manager] from within the [Server Manager] console. 2. Within [Failover Cluster Manager], click the [Validate Configuration] 3. In the [Validate a Configuration Wizard] dialog box, click [Next]. 10/9/2017 EasyHA SQL Server 9

4. In the [Select Servers or a Cluster] dialog box, add the server hostnames of the SQL Server instances that you want to configure as replicas in your Availability Group. Click [Next]. 5. In the [Testing Options] dialog box, make sure that the option [Run all tests] (recommended) is selected. Click [Next]. 10/9/2017 EasyHA SQL Server 10

6. In the [Confirmation] dialog box, click [Next]. 7. Wait for the [Validating] step to finish. It will take a few minutes: 10/9/2017 EasyHA SQL Server 11

8. On the [Summary] page, select the dialog box [Create the cluster now ], click [Finish] to create the Windows Failover Cluster: NOTE: The Failover Cluster Validation Wizard is expected to return several Warning messages, especially if you will not be using shared storage. As mentioned earlier, there is no need to use shared storage to create the Windows Server Failover Cluster. Just be aware of these Warning messages as we will configure a file share witness for our cluster quorum configuration. However, if you see any Error messages, you need to fix those first prior to creating the Windows Server Failover Cluster. 10/9/2017 EasyHA SQL Server 12

9. Click [Next]: 10. Fill in the name for the cluster: 10/9/2017 EasyHA SQL Server 13

11. Make sure the check box is selected; click [Next]: 12. In the [Summary] dialog box, verify that the configuration is successful and click [Finish]: 13. Validate it by clicking on the name of your cluster, then [Nodes]: Please configure your cluster according your own requirements to have an uneven number of voters, or follow the below steps to configure a file share witness. 10/9/2017 EasyHA SQL Server 14

4.1 CONFIGURE A FILE SHARE WITNESS In the cluster manager, right click the cluster name -> More Actions -> Configure Cluster Quorum Settings [Next] 10/9/2017 EasyHA SQL Server 15

Select [Advanced quorum configuration] and click [Next] Select [All Nodes]. [Next] Select the option [Configure a file share witness]. [Next] 10/9/2017 EasyHA SQL Server 16

Type a share name. It is important that the cluster computer account has full permissions on this share. [Next] [Next] [Finish] 10/9/2017 EasyHA SQL Server 17

5 ENABLE ALWAYSON Once the Windows Server Failover Cluster has been created, we can now proceed with enabling the AlwaysOn Availability Groups feature in SQL Server 2016. This needs to be done on all of the SQL Server instances that you will configure as replicas in your Availability Group. To enable: 1. Open [SQL Server 2016 Configuration Manager]. 2. Click [SQL Server Services] and double-click on [SQL Server (MSSQLSERVER)] to open the [Properties] dialog box. 10/9/2017 EasyHA SQL Server 18

3. In the [Properties] dialog box, select the [AlwaysOn High Availability] tab. Check the [Enable AlwaysOn Availability Groups] check box. This will prompt you to restart the SQL Server service. Click [OK]. (If not done so already, within the [Log On] tab, the user can be changed which runs the service to a domain user) 4. Restart the SQL Server service. 10/9/2017 EasyHA SQL Server 19

6 CREATING AVAILABILITY GROUPS Availability Groups can be created on existing databases or a new one in preparation for testing purposes (advised to start with). To create and configure a SQL Server 2016 AlwaysOn Availability Group, 1. Open SQL Server Management Studio. Connect to the SQL Server instance: 2. In [Object Explorer], expand the [AlwaysOn High Availability] folder. Right-click on the [Availability Groups] folder and select the [New Availability Group Wizard] 10/9/2017 EasyHA SQL Server 20

3. In the [Introduction] page, click [Next]. 4. In the [Specify Availability Group Name] page, enter the name of the Availability Group in the [Availability group name] field. Click [Next]: 10/9/2017 EasyHA SQL Server 21

5. In the [Select Databases] page, select the checkbox beside the database that you want to include in your Availability Group. The database has to be in Full recovery mode and have a full backup done prior to joining them in the Availability group. Click [Next]. 6. In the [Specify Replicas] page, under the Replicas tab, click the [Add Replicas] button and connect to the other SQL Server instance. Then click [Next]: Automatic Failover (Up to 2): Checked (if you want the database to become activated automatically on Azure) Synchronous Commit (Up to 3): Checked Readable Secondary: No For more information on the options, when to choose what option and why, visit this link. 10/9/2017 EasyHA SQL Server 22

7. In the [Endpoints] tab, verify that the port number value is 5022. Make sure this port is not blocked by the firewall by allowing it on both hosts. 8. ***OPTIONAL*** If you want to use the SQL database after it failed over to Azure, you should connect your application to a listener address. This listener is a shared name between the cluster nodes that is active on the primary node. So, if the on-premises server becomes inactive, the name of the configured SQL server doesn t change, the database is activated on the Azure server and the application continues operating as usual. In case you only want to replicate the database without the need to use it directly on Azure, you can skip this step. On the [Listener] tab, create the DNS name for the cluster including the IP-addresses associated with it, one for each subnet: 10/9/2017 EasyHA SQL Server 23

9. In the [Select Initial Data Synchronization] page, select the [Full] option. Provide a shared folder that is accessible by both nodes and that both the SQL Server service accounts have Write permissions to. Click [Next]. 10. In the [Validation] page, verify that all validation checks return successful results (if no listener has been created in step 8, a warning is displayed). Click [Next]. 10/9/2017 EasyHA SQL Server 24

11. In the [Summary] page, verify all configuration settings and click [Finish]. 12. In the [Results] page, verify that all tasks have been completed successfully and then check that the Availability Group was created on both servers: 10/9/2017 EasyHA SQL Server 25

Verify you can connect to the listener via SQL Server Management Studio: 10/9/2017 EasyHA SQL Server 26

A failover can be tested as follows. Navigate to the just created Availability Group, right click and select [Failover] 10/9/2017 EasyHA SQL Server 27

[Next] The secondary server is automatically selected. [Next] 10/9/2017 EasyHA SQL Server 28

Click [Connect] twice [Next] 10/9/2017 EasyHA SQL Server 29

[Finish] Wait for a successful failover and click [Close] The Secondary server became Primary. When applications are using the SQL listener, they should run operations as usual. Be aware though, that applications might require a very low latency and this setup is not useable. Then you can use the replication feature only to make sure your database is replicated off-premises in case it needs recovery. 10/9/2017 EasyHA SQL Server 30

Before failover: After failover: You have setup a basic Availability group which hosts a copy of your database in Azure. When needed, the database can be activated, and operations can continue. For more advanced features, the SQL Enterprise edition can be used to make more copies, make backups from the secondary node and to make the secondary node also read-only accessible for better performance. The information contained in EasyHA SQL Server is believed to be accurate. However Ingram Micro expressly disclaims any warranty, expressed or implied, concerning the accuracy, completeness or suitability of any information or services provided herein. The information, services, products and materials contained in the EasyHA SQL Server including without limitations text, graphics and links are provided on an as is basis with no warranty, express or implied. Users are to implement the steps described in the EasyHA SQL Server in a non-production environment before adopting the solution into the user s production environment. 10/9/2017 EasyHA SQL Server 31