The Windows Azure HPC Scheduler

These instructions will help you use the Windows Azure HPC Schduler to deploy a parallel computing cluster of four nodes (eight cores) as a Windows Azure service. You will install two Microsoft SDKs to your local Windows installation, open the Windows Azure Management Portal, and execute a Powershell script to deploy the cluster service.

MSDPE Logo nCoreDesign

This work was sponsored by the Microsoft Developer and Platform Evangelism Team and nCore Design.


We'll begin by configuring your local Windows installation with the Windows Azure SDK and the Windows Azure HPC Scheduler SDK and acquainting you with the Windows Azure Management Portal. Follow the instructions below to prepare your Windows installation.

Windows Azure SDK version 1.6

The Windows Azure SDK gives developers the necessary tools to interface local applications with Windows Azure services. The full SDK for Microsoft .NET is required to use the tools presented in this tutorial.

  1. Go to the Windows Azure Developer Downloads site and click the "install" button to download the full install of the Windows Azure SDK for .NET:


  2. Execute the downloaded file. You will be prompted three times to allow the operation. Click Allow, Allow, Yes to begin the installation.

  3. The Web Platform Installer may also prompt you to select the authentication mode for SQL Server Express. If this happens, choose Mixed Mode Authentication and set a password that you will remember. The SDK will take a few minutes to download and install.

  4. Click Finish and Exit to complete the installation and exit Web Platform Installer.

Windows Azure HPC Scheduler SDK version 1.6

The Windows Azure HPC Scheduler will help you to launch and manage parallel HPC applications on a Windows Azure service. Its main jobs are to make it easy to deploy and use a parallel computing cluster as a Windows Azure service and to manage the HPC jobs you execute on the cluster.

  1. Download the Windows Azure HPC Scheduler SDK 64-bit installer from the Microsoft Download Center:


  2. Execute the downloaded file. You will be prompted to allow the installation. Install the SDK in the default location.

The Windows Azure Management Portal

Windows Azure Management Portal is the seat of power for your Windows Azure subscriptions. From the portal, you can perform service deployment and management tasks and monitor the overall health of your deployments and accounts.

  1. Microsoft Silverlight is required to use the portal. Go to to install Silverlight in your browser.

  2. Go to to log on to the Windows Azure Management Portal. Be sure to use the same Windows Live ID and password that you used to create your Windows Azure subscription.


    Don't forget the dot '.' between "windows" and "azure" in the above URL. If you do, you will be taken to the Windows Azure Homepage, not the Windows Azure Management Portal.

  3. We'll be referring to the portal throughout this part of the tutorial, so stay logged in and keep the browser window open.

Deploy Windows Azure HPC Scheduler via Powershell

Deploying the Windows Azure HPC Scheduler involves creating Windows Azure components:

  • A Hosted Service containing six role instances:
    • One HeadNode instance to schedule, manage, and coordinate the parallel deployment,

    • Four ComputeNode instances to provide computational resources,

    • And one FrontEnd instance to provide web-based job submission and monitoring.

  • A Storage Account to hold state information for the cluster and provide a persistent shared storage location to all role instances,
  • And finally, a SQL Azure Database for maintaining scheduler configuration and state information.

Azure Deployment Diagram

All these components can be created easily with Microsoft Visual Studio Professional or via a Powershell script. We will use the Powershell approach because it has fewer prerequisites and is better suited to our needs in this tutorial.

  1. Download the PowerShell script package to your Windows installation and extract the zip file to create the WAHSPowershellDeployment folder.

  2. Double-click on Setup.cmd. Click Allow when you are prompted to allow Setup.cmd to make changes to your computer and you will be presented with a Powershell prompt in the WAHSPowershellDeployment\Code folder. We will refer to this window throughout this part of the tutorial.

  3. Execute the following command in the Powershell window:
  4. Enter azuretutorial.csdef when you are prompted for InputCSDef and azuretutorial.cscfg when you are prompted for InputCSCfg:

    Supply values for the following parameters:
    InputCSDef: azuretutorial.csdef
    InputCSCfg: azuretutorial.cscfg
    We'll learn more about these two files later on.
  5. Enter your Subscription ID when you are prompted for SubscriptionID. To locate your Subscription ID, go to the Windows Azure Management Portal and click on Hosted Services, Storage Accounts & CDN, Hosted Services, and find the subscription you want to use. Your Subscription ID is in the properties pane on the right:


    Copy the Subscription ID by highlighting it with your mouse and pressing Ctrl+C. Return to the Powershell Prompt and paste it by right-clicking and selecting Paste. Press Enter to continue.

  6. Enter 0 when you are prompted for your Windows Azure management certificate to generate a new self-signed certificate, or, if you installed a certificate earlier, type the number of the certificate you would like to use.

  7. If you generated a new certificate you will need to install it. In the Management Portal, click on Hosted Services, Storage Accounts & CDN, Management Certificates, and find the subscription you wish to use. Click on Add Certificate.



    Certificates and their use in Windows Azure is a detailed topic. See Overview of Certificates in Windows Azure to learn more.

  8. Check the Powershell window to find the location of the newly-generated self-signed certificate:


  9. In the Management Portal, browse to the certificate file and click OK. After a few seconds, your new certificate will appear on the list of management certificates. Return to the Powershell console and press Enter to continue.

  10. Enter 0 to create a new hosted service. Specify a name for the new hosted service and wait for the new hosted service to be created.

    The hosted service name must be less than 15 characters long

    The script will not check the length of your hosted service name, so be careful to not use more than 15 characters. If your hosted service name is too long, the script will fail later on.

  11. Enter Y when you are prompted to create a new certificate for password encryption and SSL. Wait a few seconds for the new certificate to be created.

  12. Enter 0 when you are prompted to select a storage account. Specify a name for your new storage account and wait for the new storage account to be created.

  13. Enter 0 when you are prompted to select a SQL Azure server. Enter a name for the SQL Azure server administrator (e.g. admin) and a password for the administrator account. The password must contain at least three of the following four classes:

    • Uppercase alphabetical (e.g. ABCDEFG...)
    • Lowercase alphabetical (e.g. abcdefg...)
    • Numeric (e.g. 123456789)
    • Non-alphanumeric (e.g. !@#$%.;[])
  14. Enter 0 when you are prompted to select a database. Specify the name of your database, and again enter the new administrator name and password. Wait while your database is initialized.

  15. The script will now begin the deployment process by uploading files to a Windows Azure storage container and creating role instances. This may take up to an hour to complete, so be patient. In the meantime, let's learn more about how we define the deployment topology.

    There are two files that work together to define our cluster: a service definition file with a .csdef extension and a service configuration file with a .cscfg extension. Earlier, we specified these files as azuretutorial.csdef and azuretutorial.cscfg. The service definition file defines the Windows Azure roles (e.g. HeadNode, ComputeNode, etc.) that our service will use. Here is a copy of azuretutorial.csdef:

       1 <?xml version="1.0" encoding="utf-8"?>
       2 <ServiceDefinition name="TestService" xmlns="">
       3   <WebRole name="FrontEnd" vmsize="Small">
       4     <Sites>
       5       <Site name="HPC">
       6         <VirtualApplication name="Portal" />
       7         <Bindings>
       8           <Binding name="HPCWebServiceHttps" endpointName="Microsoft.Hpc.Azure.Endpoint.HPCWebServiceHttps"/>
       9         </Bindings>
      10       </Site>
      11     </Sites>
      12     <Endpoints>
      13     </Endpoints>
      14     <Imports>
      15       <Import moduleName="Diagnostics" />
      16       <Import moduleName="RemoteAccess" />
      17       <Import moduleName="HpcWebFrontEnd" />
      18     </Imports>
      19     <ConfigurationSettings>
      20     </ConfigurationSettings>
      21     <LocalResources>
      22       <LocalStorage name="WFELocalStorage" cleanOnRoleRecycle="false" />
      23     </LocalResources>
      24     <Startup>
      25     </Startup>
      26   </WebRole>
      27   <WorkerRole name="HeadNode" vmsize="Medium">
      28     <Imports>
      29       <Import moduleName="Diagnostics" />
      30       <Import moduleName="RemoteAccess" />
      31       <Import moduleName="RemoteForwarder" />
      32       <Import moduleName="HpcHeadNode" />
      33     </Imports>
      34     <ConfigurationSettings>
      35     </ConfigurationSettings>
      36     <Endpoints>
      37     </Endpoints>
      38   </WorkerRole>
      39   <WorkerRole name="ComputeNode" vmsize="Medium">
      40     <Imports>
      41       <Import moduleName="Diagnostics" />
      42       <Import moduleName="RemoteAccess" />
      43       <Import moduleName="HpcComputeNode" />
      44     </Imports>
      45     <ConfigurationSettings>
      46     </ConfigurationSettings>
      47   </WorkerRole>
      48 </ServiceDefinition>

    As you can see, we've defined a small HpcWebFrontend role named "FrontEnd", a medium HpcHeadNode role named "HeadNode", and a medium HpcComputeNode role name "ComputeNode". The size of the node corresponds directly to the Windows Azure Virtual Machine Size and ranges from "extra small" to "extra large". Notice that the service configuration file does not say how many instances of each role we will create. Our cluster's configuration parameters are defined in azuretutorial.cscfg:

       1 <?xml version="1.0" encoding="utf-8"?>
       2 <ServiceConfiguration serviceName="TestService" xmlns="" osFamily="2" osVersion="*">
       3   <Role name="FrontEnd">
       4     <Instances count="1" />
       5     <ConfigurationSettings>
       6       <Setting name="Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString" value="UseDevelopmentStorage=true" />
       7     </ConfigurationSettings>
       8   </Role>
       9   <Role name="HeadNode">
      10     <Instances count="1" />
      11     <ConfigurationSettings>
      12       <Setting name="Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString" value="UseDevelopmentStorage=true" />
      13     </ConfigurationSettings>
      14   </Role>
      15   <Role name="ComputeNode">
      16     <Instances count="4" />
      17     <ConfigurationSettings>
      18       <Setting name="Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString" value="UseDevelopmentStorage=true" />
      19     </ConfigurationSettings>
      20   </Role>
      21 </ServiceConfiguration>

    Here we've configured one instance of the FrontEnd role, one instance of the HeadNode role, and four instances of the ComputeNode role. The Powershell script parses the two configuration files and creates Windows Azure Nodegroups to correspond to each role. If in future you wish to change the topology of your cluster, simply edit these two files accordingly and re-run the Powershell script.

  16. Your Powershell console should look something like this when the deployment is complete:


    Go to the Management Portal and click on Hosted Services, Storage Accounts & CDN. Select your subscription and find the Windows Azure HPC Scheduler Service to see all the node instances in your new compute cluster:


Additional Resources

You can view the original blog posting on this topic by Wenming Ye on the MSDN blog.

The official Windows Azure Training Course is an excellent resource for learning to develop applications and services for Windows Azure. Topics covered there include:

Most of these training modules require Microsoft Visual Studio Professional or higher. Visual Studio Express versions are not supported.

The Windows Azure HPC Scheduler can also be deployed via Microsoft Visual Studio 2010 Professional. See Getting Started with Application Deployment with the Windows Azure HPC Scheduler to learn more.