Giter Club home page Giter Club logo

always-on-template's Introduction

Create a SQL Server 2014 Always On Availability Group with PowerShell DSC Extension

This template will create a SQL Server 2014 Always On Availability Group using the PowerShell DSC Extension it creates the following resources:

  • A Virtual Network
  • Three Storage Accounts
  • One external and one internal load balancer
  • Two VMs configured as Domain Controllers for a new forest with a single domain
  • Three VMs in a Windows Server Cluster, two VMs run SQL Server 2014 with an availability group and the third is a File Share Witness for the Cluster
  • Two Availability Sets one for the AD VMs, the other for the SQL and Witness VMs, the second Availability Set is configured with three Update Domains and three Fault Domains

The external load balancer creates an RDP NAT rule to allow connectivity to the first VM created, in order to access other VMs in the deployment this VM should be used as a jumpbox.

A SQL Server always on listener is created using the internal load balancer.

Known Issues

This template is entirely serial due to some issues between the platform agent and the DSC extension which cause problems when multiple VM and\or extension resources are deployed concurrently. This issue will be fixed as soon as possible.

Notes

  • The default settings for storage are to deploy using premium storage, the AD VMs use a P10 Disk and the SQL VMs use two P30 disks each, these sizes can be changed by changing the relevant variables. In addition there is a P10 Disk used for each VMs OS Disk.

  • In default settings for compute require that you have at least 11 cores of free quota to deploy.

  • The images used to create this deployment are

    • AD - Latest Windows Server 2012 R2 Image
    • SQL Server - Latest SQL Server 2014 SP1 on Windows Server 2012 R2 Image
    • Witness - Latest Windows Server 2012 R2 Image
  • The image configuration is defined in variables - details below - but the scripts that configure this deployment have only been tested with these versions and may not work on other images.

Click the button below to deploy from the portal

Deploying from PowerShell

For details on how to install and configure Azure Powershell see [here].(https://azure.microsoft.com/en-us/documentation/articles/powershell-install-configure/)

Launch a PowerShell console

Ensure that you are in Resource Manager Mode

Switch-AzureMode AzureResourceManager

Change working folder to the folder containing this template

New-AzureResourceGroup -Name "<new resourcegroup name>" -Location "<new resourcegroup location>"  -TemplateParameterFile .\azuredeploy-parameters.json -TemplateFile .\azuredeploy.json

You will be prompted for the following parameters

  • newStorageAccountNamePrefix: - specify the prefix for the new storage account names
  • locationFromTemplate: - specify a valid location for the deployment
  • adminPassword: - the administrator password for the VMs and Domain
  • sqlServerServiceAccountPassword: the password for the account that SQL Server will run as
  • dnsPrefix: the DNS prefix for the public IP address used for RDP

Notable Variables

Name Description
virtualNetworkName Name of the Virtual Network
adPDCVMName The name of the Primary Domain Controller
adBDCVMName The name of the Backup\Second Domain Controller
sqlVMName The prefix for the SQL VM Names
sqlwVMName The name of the File Share Witness
spwebVMName The Prefix of the SharePoint Web Server VMs
rdpPort The public RDP port for first VM
windowsImagePublisher The name of the pulisher of the AD and Witness Image
windowsImageOffer The Offer Name for the Image used by AD and Witness VMs
windowsImageSKU The Image SKU for the AD and Witness Image
sqlImagePublisher The name of the pulisher of the SQL Image
sqlImageOffer The Offer Name for the Image used by SQL
sqlImageSKU The Image SKU for the SQL Image
windowsDiskSize The size of the VHD allocated for AD and Witness VMs Data Disk
sqlDiskSize The size of the VHD allocated for SQL VMs Data and Log Disks
domainName The name of the new AD Domain created

always-on-template's People

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.