Installing a Domain Controller on Microsoft Azure Virtual Machine turned out to be quite a challenge and it was not even the primary task I was trying to achieve this weekend. I was trying to setup a Microsoft CRM VM on Azure and it all lead to 24 Hours of learning on Azure Services and Azure Powershell. I am used to setting up a separate Active Directory Server when installing CRM or SharePoint locally (Standard or Enterprise SharePoint installations don’t allow installing AD on the same machine anymore) – what I understood from the effort is that if you are new to Azure, the order of the following steps are really important.
- Setup a Virtual Network (VNet) under your Microsoft Azure Subscription.
- Select New > Network Services > Custom Create.
- Give your Virtual network a name and click Next.
- Leave the DNS Servers Empty for now – we will come back to it after our AD Forest and DNS Server are all setup.
- Click Next and leave Virtual Network Address Spaces to Default 10.0.0.0 subnet
- Create the first domain controller Virtual Machine – New > Compute > Virtual Machine > From Gallery.
- Select “Windows Server 2012 R2 Datacenter”, give your Virtual Machine a Name and specify a username / password
- In Virtual Machine Configuration, Select a new Cloud Service (if you are setting up a second domain domain controller, you will have to select the same Cloud Service)
- Select your virtual network that you setup in Step 1 in the Region / Affinity Group / Virtual Network.
- Select the default storage account (or the same storage account as the first DC machine if you are adding more than one DCs)
- Create an Availability Set for your first DC VM (You will have to add all subsequent DC VMs in the same Availability Groups)
- Click Next and check “Install the VM Agent” and Clock Complete.
- You can also setup more than one Domain Controllers by following additional information mentioned in Step 3.
- Setup Static Internal IP Addresses for each of your DC VMs. (You can use Azure Powershell Console on your local machine to setup the Static Internal IPs – you may have to install the Azure SDK on your local machine to get the Azure Powershell. The SDK also installs some great Visual Studio Tools for you if you have Visual Studio 2013 Update 3 or above)
- Attach a new Empty Hard Disk to each of your DC VMs. This disk will be used for saving the Active Directory Files, Logs etc.
- Go to the Azure Virtual Machines dashboard on Azure Portal and clock “Attach” in the bottom Ribbon options – Select “Attach an Empty” disk and create a new empty disk – specify name and size of the disk (say 10 GB).
- Repeat this step for each of your DC VMs
- Login to the DC VM and Setup the new attached disk
- Go to Server Manager > Storage > Disks and select the new attached disk.
- Right Click and Create a New Volume on the disk.
- Select all default options and complete the wizard.
- A new NTFS Volume will be created on the new disk.
- Go to your Virtual Network (VNet) created in Step 1
- Select the Virtual Network and Select Configure
- Under DNS Servers enter the server name and Static IP Address of your DC Server
- If you are planning to setup multiple DCs, then enter all the server names and static IPs that you have setup in Step 5.
- Login to your Domain Controller VM and install the Active Directory using the Roles and Features Wizard.
- Go to Server Manager > Manage > Add Roles and Features > Active Directory Services.
- Complete the Wizard and the Installation
- After your installation is complete, the server will ask you to configure your feature and if you want to promote this active directory server as domain controller.
- Complete the Configuration on the Primary Server.
- The system will ask for a server restart.
- In case if you are installing multiple DCs, you will have to join all other DC machines to the primary domain first by logging in to the VM – then repeat the same steps of installing and configuring the Active Directory and promoting the server as a Domain Controller
- You will have to specify the same domain name for secondary controllers and also select the replication from primary server option during the domain controller configuration. Apart from that the configuration is the same as primary server.
- Restart the machines and your domain Controller should be up and running with multiple redundant DCs (in case of multiple DCs).
PS C:\> Get-AzureVM -ServiceName AleemVNet2DC -Name AleemVNet2DC | Set-AzureStaticVNetIP -IPAddress 10.0.0.4 | Update-AzureVM
The following article http://azure.microsoft.com/en-us/documentation/articles/active-directory-new-forest-virtual-machine/ on Azure website was extremely helpful but since I am new to Azure and still figuring out the Powershell commands and the order order of all the steps mentioned above. In the end it all worked out and I have an AD Forest on an Azure Virtual Network with two replicated Domain Controllers under a single Azure Cloud Service and an Availability Set.
Aleem,
I am trying to setup a Dynamics CRM 2013 in a Azure VM. My requirement is, I need to be able to connect to it using Visual Studio 2012 (CRM SDK). I got it up and running but VS2012 cant connect to it since url for org services are different than url of the application. You can find more details in below dynamics forum. Any help is appreciated. Thanks, Prasad
https://community.dynamics.com/crm/f/117/p/155705/364840.aspx#364840
[…] social media world has been waiting for news about the future of Google+ for some time now. Many professionals expected an update at this years [… Click https://zhoutest.wordpress.com/
Hi, Just wondering can we Install DHCP role, service Azure running DC. Would it work same way like on premises DHCP I’m talking about DC ‘s running on 2012 r2? thanks
@atul – DHCP role isn’t supported in Azure. You can set static IP addresses but this is done on the network interface from within Azure.
I will be sure to take a note of your blog and could revisit at some point.
Best of service is chemical for cleaning black money
Machine for cleaning black money
Activation powder
Mercury powder
Ssd chemical solution
Ssd solution
Solution powder
Chemical for cleaning Black dollar
Call us on +923200808563.
Visit our website at http://www.universalchem.com.co
WoW, Thanks for sharing! If you want to experience the best online shopping in Pakistan, then must explore bababoota.com (Best Online Shopping Website In Pakistan) they believe in delivering excellent products.
Wow! Are you looking for the best BPO services in Pakistan? BpoXperts is the right choice for you.
Premium Gift Boxes best quality products are available now for online shopping in Karachi, Lahore, Islamabad, and other cities of Pakistan.
Wow! Are you looking for the best jobs in dubai
arab updates