We regularly need fresh labs with Windows Azure Pack and after having used the PowerShell Deployment Toolkit for deploying System Center 2012 R2 and Windows Azure Pack in a production environment, I felt quite confident to use PDT again for my new lab. So what could go wrong?
I took a variable.xml file from a previous installation and modified the variables in it to reflect the VMs I had already created via my Windows Azure Pack portal. Yes you are reading this correctly, I was building a Windows Azure Pack lab right from my own WAP tenant portal. I had to go easy on the memory and cpu resources so I was not able to make everything redundant. For the purpose of this lab it was fine.

Because I wanted to focus on Usage and CloudCruiser, I needed at least Operations Manager, Virtual Machine Manager, Service Provider Foundation and Windows Azure Pack. I added Service Management Automation to get some work done on SMA later. All I needed to do was use the correct user accounts, groups and passwords to get things going.

In fact all System Center 2012 R2 components deployed like a charm except Windows Azure Pack. That was strange because the PDT Validation step ran without any errors. I had learnt from previous engagements that rerunning the installer.ps1 can often help to correct installation steps that have gone wrong in a previous run. So I tried again and again but no luck. I kept on getting the error message Failed to install Windows Azure Pack 2013 Admin API Server and consequently all dependent components would fail as well.

The first thing to look at was of course the PDT Installer log. A great tool to look at your live logs is the Configuration Manager Trace Log Tool and I opened the installer.log which is located in %USERPROFILE%\Appdata\Installer as well as a PDT installation log for each server involved. Unfortunately the installer log provided no details about why the installation of Windows Azure Pack 2013 Admin API Server had failed.

A good place to start looking is the specific event logs for Windows Azure Pack and in our case the MgtmtSvc-AdminAPI Operational log. Event 12 was logged a number of times which pointed to a SQL Server connection problem.
I was using an AD account for installing all System Center components. This account HYPERVNU\SVC_Installer was also a member of the GRP_SQL_Admins which had full rights to the database server.

The next step was taking a closer look at the unattended installation script for deploying this Admin API component which can also be derived from the installer.log. I already knew that Windows Azure Pack is able to use Integrated Security for communication with the SQL Server database. When you configure the database manually, the default is database authentication, but PDT uses Windows Authentication during its automated installation, which of course is a good choice. Do not forget to set the database in SQL Server and Windows Authentication mode. Although we can create and register the databases using an AD account, Windows Azure Pack creates local SQL Server accounts for internal use.

Looking at the unattended installation script, we can see (in red) which SQL Server instance, which authentication method and which principal is used.

Command: powershell.exe -command ” If (!(Get-Module -Name MgmtSvcConfig)) {Import-Module -Name MgmtSvcConfig}; If (!((Get-MgmtSvcFeature -Name AdminAPI).Configured)) {Initialize-MgmtSvcFeature -Name AdminAPI -Passphrase ‘********’ -EnableCeip No -Server ‘HVLAB-SQL02.hyper-v.nu\INST1’ -Verbose}; If (!((Get-MgmtSvcFeature -Name Monitoring).Configured)) {Initialize-MgmtSvcFeature -Name Monitoring -Passphrase ‘********’ -EnableCeip No -Server ‘HVLAB-SQL02.hyper-v.nu\INST1’ -Verbose}; If (!((Get-MgmtSvcFeature -Name WebAppGallery).Configured)) {Initialize-MgmtSvcFeature -Name WebAppGallery -Passphrase ‘********’ -EnableCeip No -Server ‘HVLAB-SQL02.hyper-v.nu\INST1’ -Verbose}; If (!((Get-MgmtSvcFeature -Name UsageCollector).Configured)) {Initialize-MgmtSvcFeature -Name UsageCollector -Passphrase ‘********’ -EnableCeip No -Server ‘HVLAB-SQL02.hyper-v.nu\INST1’ -Verbose}; If (!((Get-MgmtSvcFeature -Name UsageService).Configured)) {Initialize-MgmtSvcFeature -Name UsageService -Passphrase ‘********’ -EnableCeip No -Server ‘HVLAB-SQL02.hyper-v.nu\INST1’ -Verbose}; If ((Get-MgmtSvcFeature -Name AdminAPI).Configured -and (Get-MgmtSvcFeature -Name Monitoring).Configured -and (Get-MgmtSvcFeature -Name WebAppGallery).Configured -and (Get-MgmtSvcFeature -Name UsageCollector).Configured -and (Get-MgmtSvcFeature -Name UsageService).Configured) { $ManagementConnectionString = ‘Data Source=HVLAB-SQL02.hyper-v.nu\INST1’
+ [char]59 + ‘Initial Catalog=Microsoft.MgmtSvc.Store’ + [char]59 + ‘Integrated Security=True’; Add-MgmtSvcAdminUser -Principal ‘HYPERVNU\GRP_WAP_Admins’
-ConnectionString $ManagementConnectionString; ‘Done’ | Out-File ‘C:\Temp\WindowsAzurePack2013AdminAPIServer.role’; }; ”
So the next thing was to try a manual Database Server Setup by navigating to https://localhost:30101/ on one of the server running Windows Azure Pack. I entered the SQL Server name, changed the Authentication Type to Windows Authentication and filled out the Passphrase.

This was my problem! I had used the same password for both the InstallerServiceAccountPassword and the ConfigStorePassphrase. All I needed to do was create a new variable ConfigStorePassphrase and set the password including a non-alphanumeric character.

All I needed to do was execute the PDT installer again. It was now able to connect to the SQL Server, create the database and configure Windows Azure Pack. It was also able to complete the remaining integration between WAP and SPF. That is the cool thing about PDT, it does not only install the bare components, it also configures component, uses the correct accounts, groups and authentication methods and above all it installs all relevant integrations between the System Center components. In our case:
-
Operations Manager – Virtual Machine Manager Integration
-
Virtual Machine Manager – Operations Manager Integration
-
Service Provider Foundation – Service Management Automation Integration
-
Service Provider Foundation – Virtual Machine Manager Integration
-
Windows Azure Pack 2013 – Service Provider Foundation Integration









