<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.technet.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>HPC, Virtualization and Random Thoughts</title><link>http://blogs.technet.com/b/gmarchetti/</link><description /><dc:language>en-US</dc:language><generator>Telligent Evolution Platform Developer Build (Build: 5.6.50428.7875)</generator><item><title>Using CloudBlitz to Submit Jobs</title><link>http://blogs.technet.com/b/gmarchetti/archive/2013/05/16/using-cloudblitz-to-submit-jobs.aspx</link><pubDate>Thu, 16 May 2013 21:22:00 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3573234</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3573234</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2013/05/16/using-cloudblitz-to-submit-jobs.aspx#comments</comments><description>&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;In the second post about Cloudblitz (&lt;a href="http://cloudblitz.codeplex.com"&gt;http://cloudblitz.codeplex.com&lt;/a&gt;) we'll examine how to use it to submit jobs to&amp;nbsp;a deployed Azure cluster.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;Keep in mind that in Microsoft's HPC scheduler implementation, jobs are just containers. They contain one or more tasks to be executed and have properties associated to them (e.g. credentials, priority).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;Such a container can be created empty, then filled with tasks and finally submitted for execution. If you have a look at the Create-InstallJob.ps1 script that comes with Cloudblitz, you'll see an example of that.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;Let us suppose that you want to&amp;nbsp;write a simple job submission script:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;1.&amp;nbsp;Import the Cloudblitz.Powershell module and get the hpc&amp;nbsp;object types:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: courier new,courier; font-size: small;"&gt;Import-MyModule -Name "CloudBlitz.Powershell" -Path $cmdletsPath&lt;br /&gt;$hpcTypesPath = [System.IO.Path]::GetDirectoryName($cmdletsPath) + "\HpcSchedulerManagement.dll"&lt;br /&gt;Add-Type -Path $hpcTypesPath -ErrorAction Stop&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: arial,helvetica,sans-serif; font-size: small;"&gt;2. Provide the credentials for the jobs to be submitted&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: courier new,courier; font-size: small;"&gt;# Fill in hpc scheduler credentials&lt;br /&gt;&amp;nbsp;$hpcCredentials = New-Object CloudBlitz.Powershell.Cmdlets.HpcSchedulerCredentials&lt;br /&gt;&amp;nbsp;$hpcCredentials.ClusterName = $ClusterName&lt;br /&gt;&amp;nbsp;$hpcCredentials.AdminLogin = $AdminLogin&lt;br /&gt;&amp;nbsp;$hpcCredentials.AdminPassword = $AdminPassword&lt;br /&gt;&amp;nbsp;$hpcCredentials.CertificateThumbprint = $mgmtcert.Thumbprint&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: arial,helvetica,sans-serif; font-size: small;"&gt;Note that you&amp;nbsp;will need&amp;nbsp;the thumbprint of the certificate associated with the service at deployment. That is required because the powershell commandlets use&amp;nbsp;the hpc scheduler&amp;nbsp;REST API to communicate with the service.&amp;nbsp;All the parameters can be passed on the command line&amp;nbsp;or retrieved from the ConfigurationVariables.ps1 file that you edited before deployment.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: arial,helvetica,sans-serif; font-size: small;"&gt;3. Create an empty job container&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: courier new,courier; font-size: small;"&gt;# Create the job on the scheduler&lt;br /&gt;&amp;nbsp;$Job = New-Object HpcSchedulerManagement.DataContracts.SchedulerJob&lt;br /&gt;&amp;nbsp;$Job.FailOnTaskFailure = $True&lt;br /&gt;&amp;nbsp;$Job.Name = "Job"+$(get-random 1000000)&lt;br /&gt;&amp;nbsp;$Job.Id = Add-SchedulerJob -Credentials $hpcCredentials -Job $Job -ErrorAction Stop&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: arial,helvetica,sans-serif; font-size: small;"&gt;The first line creates an empty container, then we set some properties (e.g. random name) and finally we create the job on the hpc scheduler and retrieve its id.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: arial,helvetica,sans-serif; font-size: small;"&gt;4. Add tasks into the job container&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: courier new,courier; font-size: small;"&gt;# Create the task&lt;br /&gt;&amp;nbsp;$Task = New-Object HpcSchedulerManagement.DataContracts.SchedulerTask&lt;br /&gt;&amp;nbsp;$Task.Name = "Task"+$(Get-Random 1000000)&lt;br /&gt;&amp;nbsp;$Task.CommandLine = $CommandLine&lt;br /&gt;&amp;nbsp;$Task.Id = Add-SchedulerTask -Credentials $hpcCredentials -JobId $Job.Id -Task $Task&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: arial,helvetica,sans-serif; font-size: small;"&gt;As with the job, we create an empty object, set its properties, then add it to the job container whose id we retrieved before. Note that one of those properties is $Task.CommandLine, which takes a string. The string is an arbitrary command to be executed on the remote nodes. If you want to start a MPI job, it will look like&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: courier new,courier; font-size: small;"&gt;mpiexec &amp;lt;mpi parameters&amp;gt; &amp;lt;your mpi&amp;gt;.exe &amp;lt;app parameters&amp;gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;5. Submit the job for execution&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;# Submit the job&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;&amp;nbsp; Write-Host "Submitting the job"&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;&amp;nbsp; Submit-SchedulerJob -Credentials $hpcCredentials -JobId $Job.Id&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;# Wait for the job to complete&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;&amp;nbsp; Write-Host "Waiting for job $($Job.Id) to complete"&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;&amp;nbsp; $finalState = Wait-SchedulerJob -Credentials $hpcCredentials -JobId $Job.Id&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;&amp;nbsp;&amp;nbsp;Write-Host "Job $finalState"&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;Note that you need not wait for the job to complete. Those lines just show a way to retrieve and display the final job state. Normally, you will submit, then query for status later with something like:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: courier new,courier; font-size: small;"&gt;Get-schedulerjob -Credentials $hpcCredentials -JobId $JobId &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;That line will retrieve the job object and also display all its properties (not just those set in these samples).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;You can retrieve the whole list of jobs in the scheduler with:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #000000; font-family: courier new,courier; font-size: small;"&gt;Get-schedulerjobList -Credentials $hpcCredentials &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;The job properties are those supported by&amp;nbsp;Microsoft's HPC scheduler (&lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.hpc.scheduler.ischedulerjob_properties(v=vs.85).aspx"&gt;http://msdn.microsoft.com/en-us/library/microsoft.hpc.scheduler.ischedulerjob_properties(v=vs.85).aspx)&lt;/a&gt;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;Let's see an example of those, retrieved using Get-SchedulerJob:&lt;/span&gt;&lt;span style="color: #f5f5f5; font-family: Lucida Console; font-size: xx-small;"&gt;&lt;span style="color: #f5f5f5; font-family: Lucida Console; font-size: xx-small;"&gt;&lt;span style="color: #f5f5f5; font-family: Lucida Console; font-size: xx-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;d&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 8&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;Name&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : Job641676&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;UserName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : topguy&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;Project&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;RuntimeSeconds&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MinCores&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 1&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MaxCores&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 1&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MinSockets&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 1&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MaxSockets&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 1&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MinNodes&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 1&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MaxNodes&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 1&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;UnitType&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : Core&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;RequestedNodes&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;IsExclusive&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : False&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;RunUntilCanceled&amp;nbsp;&amp;nbsp;&amp;nbsp; : False&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;NodeGroups&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;FailOnTaskFailure&amp;nbsp;&amp;nbsp; : True&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;AutoCalculateMax&amp;nbsp;&amp;nbsp;&amp;nbsp; : True&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;AutoCalculateMin&amp;nbsp;&amp;nbsp;&amp;nbsp; : True&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;Preemptable&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : True&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MinMemory&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MaxMemory&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MinCoresPerNode&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;MaxCoresPerNode&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;SoftwareLicense&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;OrderBy&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;ClientSource&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : AzureRestServiceAgent&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;Progress&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 100&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;ProgressMessage&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;TargetResourceCount : 0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;ExpandedPriority&amp;nbsp;&amp;nbsp;&amp;nbsp; : 2000&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;ServiceName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;NotifyOnStart&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : False&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;NotifyOnCompletion&amp;nbsp; : False&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;EmailAddress&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;Priority&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : Normal&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;Password&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;JobTemplate&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : Default&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;JobType&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;RequeueCount&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;AutoRequeueCount&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;RequestCancel&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;Owner&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : topguy&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;SubmitTime&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 5/15/2013 11:20:47 PM&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;CreateTime&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 5/15/2013 11:20:46 PM&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;StartTime&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 5/15/2013 11:20:48 PM&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;EndTime&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 5/15/2013 11:20:50 PM&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;State&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : Finished&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;HoldUntil&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;HasRuntime&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : False&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;CanGrow&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : True&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;CanShrink&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : True&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;PreviousState&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : Running&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;ChangeTime&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : 5/15/2013 11:20:50 PM&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;ExcludedNodes&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: courier new,courier; font-size: small;"&gt;AllocatedNodes&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; :&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: arial,helvetica,sans-serif; font-size: small;"&gt;You will typically want&amp;nbsp;to set at job submission&amp;nbsp;MinCores and MaxCores (min. and max n. of cores required, default is 1). Note that properties are inherited by the tasks, unless overridden by those set at the task level (&lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.hpc.scheduler.ischedulertask_properties(v=vs.85).aspx"&gt;http://msdn.microsoft.com/en-us/library/microsoft.hpc.scheduler.ischedulertask_properties(v=vs.85).aspx)&lt;/a&gt;. For MPI jobs the&amp;nbsp;number of cores is fixed&amp;nbsp;at submission, so MinCores=MaxCores.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3573234" width="1" height="1"&gt;</description></item><item><title>Cloudblitz: A Tool to Deploy HPC Clusters in Azure</title><link>http://blogs.technet.com/b/gmarchetti/archive/2013/05/13/cloudblitz-a-tool-to-deploy-hpc-clusters-in-azure.aspx</link><pubDate>Mon, 13 May 2013 18:31:00 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3572395</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3572395</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2013/05/13/cloudblitz-a-tool-to-deploy-hpc-clusters-in-azure.aspx#comments</comments><description>&lt;p&gt;I'm happy to announce the availability of Cloudblitz, a tool (framework) to deploy HPC clusters in Azure programmatically via Powershell, then submit&amp;nbsp;jobs to them&amp;nbsp;via Powershell as well.&lt;/p&gt;
&lt;p&gt;You can find it at &lt;a href="http://cloudblitz.codeplex.com"&gt;http://cloudblitz.codeplex.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The tool builds on the HPC scheduler for Azure and the Powershell commandlets for Azure to solve a common problem, i.e. provide a scriptable way to create and interact with an Azure PaaS cluster. I refer you to the Codeplex page for the complete description and documentation. In this blog post, I'll cover how to build it and use it.&lt;/p&gt;
&lt;p&gt;1. Make sure that you download and install all the dependencies listed on the codeplex page.&lt;/p&gt;
&lt;p&gt;2. Download and extract the source code in its own directory.&lt;/p&gt;
&lt;p&gt;3. Open a Visual Studio 2012 command prompt as administrator (dear old cmd.exe)&lt;/p&gt;
&lt;p&gt;4. Go to the "BuildScripts" directory and run &lt;em&gt;BuildCloudBlitz.&lt;/em&gt;&lt;em&gt;cmd.&lt;/em&gt; This will build the required modules and copy the results in a "Packages" directory.&lt;/p&gt;
&lt;p&gt;5. Open a Windows Azure Powershell prompt as administrator. Go to the CloudBlitz.ClusterTemplate directory&lt;/p&gt;
&lt;p&gt;6. Edit the ServiceDefinition.csdef file (it is just an XML file). In particular note:&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&amp;lt;WorkerRole name="ComputeNode" vmsize="Small"&amp;gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;...&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&amp;lt;WebRole name="HeadNode" vmsize="Small"&amp;gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Choose your VM size and type it in. In general, a small head node is sufficient (the head node does NOT run SQL, rather it uses SQL Azure,&amp;nbsp;which&amp;nbsp;reduces its memory requirements). If you're planning to run thousands of tasks at a time, go for a large instance.&lt;/p&gt;
&lt;p&gt;7. Go to the CloudBlitz.Powershell\Scripts directory&lt;/p&gt;
&lt;p&gt;8. Edit the ConfigurationVariables.ps1 file. In particular note:&lt;/p&gt;
&lt;p&gt;&lt;em&gt;$subscriptionName = "&amp;lt;your subscription name&amp;gt;"&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$subscriptionId = "&amp;lt;your subscription id&amp;gt;"&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$administratorName = "&amp;lt;admin name for the hpc cluster&amp;gt;"&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$systemPassword = "&amp;lt;admin password for hpc cluster&amp;gt;"&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$certificateFileNameRoot="&amp;lt;name of certificate&amp;gt;"&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$deploymentName="&amp;lt;name of service&amp;gt;"&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$deployLocation="&amp;lt;data center location&amp;gt;"&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$HeadNodeInstanceCount = 1&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$ComputeNodeInstanceCount = &amp;lt;n. of desired compute nodes&amp;gt;&lt;/em&gt;&lt;br /&gt;&lt;em&gt;$removePreviousDeploymentAndService = $true&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;9. Run &lt;em&gt;InstallAndExportCertificate.&lt;/em&gt;ps1 This will create a .cer and a .pfx self-signed certificate file, install it in the local user certificate store.&lt;/p&gt;
&lt;p&gt;10. Via the Azure portal, upload the .cer file as a management certificate.&lt;/p&gt;
&lt;p&gt;11. Run the &lt;em&gt;DeployDeployerRole.ps1&lt;/em&gt; script. It will upload the packages, create an azure worker role that deploys a hpc cluster as per configuration, then remove the deployer role.&amp;nbsp;Such a temporary role is necessary to avoid any firewall and connectivity issues. Most people will have ports 80 and 443 open for http and https. The&amp;nbsp;Azure HPC scheduler&amp;nbsp;deployment also requires a connection to SQL Azure on port 1433, which is normally closed. By letting the temporary role&amp;nbsp;manage the process, such connections are all internal to Azure.&lt;/p&gt;
&lt;p&gt;You can now connect to your cluster.cloudapp.net via RDP and start submitting jobs in the "traditional" way via the job manager or the command line.&lt;/p&gt;
&lt;p&gt;Alternatively, you can use&amp;nbsp;the set of powershell commandlets we developed&amp;nbsp;from your workstation. They will be the subject of the next blog post :-)&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3572395" width="1" height="1"&gt;</description></item><item><title>Endpoints, firewalls and other annoyances</title><link>http://blogs.technet.com/b/gmarchetti/archive/2012/01/05/endpoints-firewalls-and-other-annoyances.aspx</link><pubDate>Thu, 05 Jan 2012 22:22:49 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3474154</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3474154</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2012/01/05/endpoints-firewalls-and-other-annoyances.aspx#comments</comments><description>&lt;p&gt;When you deploy a HPC cluster on Azure, you typically want to run some application in it besides those provided in the azure samples. Those applications may require their own ports to be opened on the internal network and endpoints to be established for both internal and external communication. There is no hpc cluster manager gui in a pure azure implementation, so you'll have to perform such configuration manually.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1. Enabling endpoints&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Endpoints must be configured prior to deployment, in the Azure service definition file. For instance, if you want to allow file sharing between nodes, you'll need SMB endpoints.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;span style="font-family: Courier; font-size: 12pt"&gt;&amp;lt;Endpoints&amp;gt;&lt;br /&gt; &amp;lt;InternalEndpoint name=&amp;quot;SMB&amp;quot; protocol=&amp;quot;tcp&amp;quot; port=&amp;quot;445&amp;quot; /&amp;gt;&lt;br /&gt; &amp;lt;InternalEndpoint name=&amp;quot;Netbios&amp;quot; protocol=&amp;quot;tcp&amp;quot; port=&amp;quot;139&amp;quot; /&amp;gt;&lt;br /&gt;&amp;lt;/Endpoints&amp;gt;&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Note that the default configuration for azure hpc samples enables port 445 but not 139. That can be corrected via Visual Studio or by manually editing the .csdef file.&lt;/p&gt;
&lt;p&gt;&lt;img height="263" width="712" style="margin: 5px" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-57-03-metablogapi/4186.Windows-XP-Professional.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;If you define a public endpoint too (as in the picture), remember that it will be subject to the azure load balancers and no &amp;quot;sticky&amp;quot; sessions are supported.&lt;/p&gt;
&lt;p&gt;After deployment, you'll be able to share files and directories as usual. If you use a directory on an azure drive mounted as per my previous post, you will have a form of shared permanent storage for computation inputs and results that will persist between deployments.&lt;/p&gt;
&lt;p&gt; &lt;br /&gt;&lt;strong&gt;2. Opening ports on the nodes&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Establishing endpoints may not be sufficient. You will also need to open the relevant ports on the o/s firewalls of the nodes in question. For instance, the command line below will open ports 55000-55500:&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:Courier"&gt;clusrun /all netsh advfirewall firewall add rule name=&amp;quot;myapp&amp;quot; dir=in protocol=tcp localport=55000-55500 action=allow&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;You may also need to register an exception with the windows firewall for the executables that you plan to run and any other executables that they may invoke in turn:&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:Courier"&gt;clusrun /all hpcfwutil register myapp.exe &amp;quot;d:\Program Files\myapp\myapp.exe&amp;quot;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;At this point you can submit jobs via the portal or the command line, e.g.&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:Courier"&gt;job submit /numcores:16 /stdout:\\headnode1\share\myapp.out /stderr:\\headnode1\share\myapp.err mpiexec myapp.exe -&amp;lt;parameters&amp;gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;The command line above submits an mpi job requiring 16 cores to run myapp.exe (assuming it is installed on the nodes), redirects outputs and errors to files on a share on the headnode.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;3. Observations&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Note that in the azure hpc sample deployment, the headnode is always called&lt;span style="font-family:Courier"&gt; headnode1&lt;/span&gt; and the compute nodes &lt;span style="font-family:Courier"&gt;computenode1, 2, 3,&lt;/span&gt; etc... This has no relationship with the actual host names, which are assigned randomly by the azure fabric controller at deployment and can change. Also, computenode1 is not necessarily the first instance of the computenode role listed on the azure portal.&lt;/p&gt;
&lt;p&gt;&lt;img height="306" style="margin: 5px" width="435" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-57-03-metablogapi/6560.Management-Portal-_1320_-Windows-Azure-Platform.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;A list of aliases is maintained automatically in %WINDIR%\system32\drivers\etc\hosts&lt;/p&gt;
&lt;p&gt;I have noticed however that for all mpi jobs I have submitted, mpi rank 0 was always on computenode1. That may be a sheer coincidence, as there is no reason for it to be there that I can think of. I'd be curious to know whether you find the same situation or not.&lt;/p&gt;
&lt;p&gt;This may be useful anyway, because certain applications may require a connection to rank 0 for their GUI, in order to display the status of the running computation.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p style="color:#008;text-align:right;"&gt;&lt;small&gt;&lt;em&gt;Powered by&lt;/em&gt; &lt;a href="http://www.qumana.com/"&gt;Qumana&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3474154" width="1" height="1"&gt;</description><category domain="http://blogs.technet.com/b/gmarchetti/archive/tags/HPC/">HPC</category><category domain="http://blogs.technet.com/b/gmarchetti/archive/tags/Azure/">Azure</category></item><item><title>Getting data and applications to / from Azure</title><link>http://blogs.technet.com/b/gmarchetti/archive/2011/12/13/getting-data-and-applications-to-from-azure.aspx</link><pubDate>Tue, 13 Dec 2011 18:08:11 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3470638</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3470638</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2011/12/13/getting-data-and-applications-to-from-azure.aspx#comments</comments><description>&lt;p&gt;&lt;font size="3"&gt;After &lt;a href="http://blogs.msdn.com/b/hpctrekker/archive/2011/12/06/deploying-an-hpc-cluster-using-just-powershell-part-i.aspx"&gt;Wenming’s&lt;/a&gt; post on deploying an azure hpc cluster with powershell, I have been looking for an easy way to transfer applications &amp;amp; data to / from such cluster.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;I have found that in HPC SP3 the hpcpack command includes the option to upload and mount a VHD drive on azure nodes. The command is also available with the free client utilities. That is very useful because:&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;- You can put whatever you like in the vhd file, including the executable that you need to run.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;- It is stored in blob storage, so it is permanent. If you need to delete the cluster deployment in order to save money, the data in the vhd drive will stay.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;- The vhd drive can be snapshotted and the snapshots mounted read-only on multiple nodes.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;- You can download the vhd back to your PC when you’re done and mount it.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;Here’s a summary of the process:&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;1. On your PC, create and attach a &lt;em&gt;fixed-size &lt;/em&gt;vhd drive with the storage management tools (GUI or diskpart).&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-57-03-metablogapi/1200.image_5F00_207FC044.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-57-03-metablogapi/1307.image_5F00_thumb_5F00_26C696D2.png" width="496" height="297" /&gt;&lt;/a&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;2. Copy your files to the drive.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;3. Again with storage manager gui or diskpart, detach the vhd.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;4. Use hpcpack (or a gui tool like &lt;a href="http://www.cloudberrylab.com/free-microsoft-azure-explorer.aspx"&gt;cloudberry explorer&lt;/a&gt;) to upload the vhd file to blob storage&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;- &lt;em&gt;hpcpack upload &amp;lt;file&amp;gt;.vhd /account:&amp;lt;storage account name&amp;gt; /key:&amp;lt;storage key&amp;gt; /container:&amp;lt;container name&amp;gt; /description:&amp;lt;description string&amp;gt;&lt;/em&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;5. Connect via rdp to the headnode in azure (or any other node where you want to mount the drive).&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;6. To mount read-write on one node, run&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;- &lt;em&gt;hpcpack mount &amp;lt;file&amp;gt;.vhd /account:&amp;lt;storage account name&amp;gt; /key:&amp;lt;storage key&amp;gt; /container:&amp;lt;container name&amp;gt;&lt;/em&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;7. To mount read-only, add the /snapshot parameter. You can also run the command on specific nodes via job manager or clusrun.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;Once the drive is mounted, you can share it out via the GUI or with net share. The smb endpoints and firewall exceptions must be configured on all nodes for that to work. &lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;When you’re done, you can use the same gui tool or hpcpack to download the vhd file back to your pc. The download does not erase the file from blob storage.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;- &lt;em&gt;hpcpack download &amp;lt;file&amp;gt;.vhd /account:&amp;lt;storage account name&amp;gt; /key:&amp;lt;storage key&amp;gt; /container:&amp;lt;container name&amp;gt;&lt;/em&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;Mount the vhd drive on your pc and retrieve your results.&lt;/font&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3470638" width="1" height="1"&gt;</description></item><item><title>SQL Server in Windows Azure</title><link>http://blogs.technet.com/b/gmarchetti/archive/2011/09/09/sql-server-in-windows-azure.aspx</link><pubDate>Sat, 10 Sep 2011 06:08:36 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3452281</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3452281</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2011/09/09/sql-server-in-windows-azure.aspx#comments</comments><description>&lt;p&gt;&lt;font size="2"&gt;It is certainly possible to run SQL Server 2008 R2 in Azure virtual machines, but keep in mind that they are not persistent between deployments, hence you want to use them for testing only and be aware of potential data loss. &lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;In order to mitigate that risk you may want to set sql up in such a way that logs and data files are stored on Azure drives mounted by the VM – but that’s a topic for another blog post &lt;img style="border-bottom-style: none; border-left-style: none; border-top-style: none; border-right-style: none" class="wlEmoticon wlEmoticon-smile" alt="Smile" src="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-57-03-metablogapi/4846.wlEmoticon_2D00_smile_5F00_194F7A63.png" /&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;Azure VMs must be uploaded in a sysprepped state (see &lt;a href="http://blogs.technet.com/b/gmarchetti/archive/2011/03/12/put-a-vm-on-azure.aspx"&gt;previous post&lt;/a&gt;) for their deployment to succeed. Fortunately in SQL 2008R2 there is a way to “package” the application so that it can be installed after the virtual machine deployment. The trick is to automate the completion of such installation. &lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;Here’s an outline of the process to follow:&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;1. Build a Sever 2008 R2 virtual machine in hyper-v&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;2. On that virtual machine, prepare a SQL Server 2008 R2 image for deployment with sysprep&lt;/font&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;font size="2"&gt;a. copy the installation media on a local directory (e.g. c:\sqlinstall)&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;font size="2"&gt;b. prepare the image as described here: &lt;/font&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ee210664.aspx"&gt;&lt;font size="2"&gt;http://msdn.microsoft.com/en-us/library/ee210664.aspx&lt;/font&gt;&lt;/a&gt;&lt;/p&gt;    &lt;p&gt;&lt;font size="2"&gt;c. Capture the sql server setup configuration file configurationfile.ini&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;&lt;font size="2"&gt;3. Edit the configuration file to instruct sql setup to complete the installation as required. Keywords are:&lt;/font&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;font size="2"&gt;a. ACTION=&amp;quot;CompleteImage&amp;quot;&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;font size="2"&gt;b. QUIET=&amp;quot;True&amp;quot;&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;font size="2"&gt;c. IACCEPTSQLSERVERLICENSETERMS=&amp;quot;TRUE&amp;quot;&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;font size="2"&gt;d. SECURITYMODE=&amp;quot;SQL&amp;quot;&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;font size="2"&gt;e. SAPWD=&amp;quot;&amp;lt;insert your sa password&amp;gt;&amp;quot;&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;&lt;font size="2"&gt;Remember that no active directory exists on Azure, so&amp;#160; you will need to use SQL authentication and run the sql services under local credentials, e.g. “NT AUTHORITY\NETWORK SERVICE”. If you plan to connect to sql server, make sure that tcpip is enabled and the relevant port (1433 by default) is open on the windows firewall.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;4. Save the configuration file with a new name, e.g. c:\sqlcompleteconfig.ini&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;5. Install the Windows Azure components&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;6. Create a %WINDIR%\Setup\Scripts\SetupComplete.cmd file. This file is executed once after windows setup completes. It can be used to perform additional unattended setup tasks, including installing applications. It runs under the system authority context. The file should contain the commands to complete the sql installation, such as:&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2" face="Courier New"&gt;“C:\Program Files\Microsoft SQL Server\100\Setup Bootstrap\SQLServer2008R2\ setup.exe&amp;quot; &lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2" face="Courier New"&gt;/CONFIGURATIONFILE=&amp;quot;C:\SQLCOMPLETECONFIG.INI&amp;quot; &lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2" face="Courier New"&gt;/installmediapath=&amp;quot;c:\sqlinstall\x64\setup”&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;7. Sysprep the VM and upload it to Azure as instructed in my &lt;a href="http://blogs.technet.com/b/gmarchetti/archive/2011/03/12/put-a-vm-on-azure.aspx"&gt;previous post&lt;/a&gt;.&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="2"&gt;Remember to configure the appropriate ports &amp;amp; endpoints for the VM when creating the package to upload. Enjoy SQL running on Azure &lt;img style="border-bottom-style: none; border-left-style: none; border-top-style: none; border-right-style: none" class="wlEmoticon wlEmoticon-smile" alt="Smile" src="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-57-03-metablogapi/4846.wlEmoticon_2D00_smile_5F00_194F7A63.png" /&gt;&lt;/font&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3452281" width="1" height="1"&gt;</description></item><item><title>Azure Connect - a vpn between Azure and your machines</title><link>http://blogs.technet.com/b/gmarchetti/archive/2011/04/18/azure-connect-a-vpn-between-azure-and-your-machines.aspx</link><pubDate>Tue, 19 Apr 2011 04:18:37 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3422631</guid><dc:creator>gmarchetti</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3422631</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2011/04/18/azure-connect-a-vpn-between-azure-and-your-machines.aspx#comments</comments><description>&lt;p&gt;Azure Connect is a service that lets you establish a vpn tunnel (for want of a better word) between a virtual machine running in Azure and another running on premises. The connection is point-to-point, meaning that you will need to configure it on every machine involved. Nonetheless, it is a valuable tool when you need to access resources within your network from Azure and viceversa.&lt;/p&gt;
&lt;p&gt;To set up Azure connect, you will need:&lt;/p&gt;
&lt;p&gt;1. &lt;strong&gt;An activation token. &lt;/strong&gt;Open the management portal. If you are on the Connect beta program, you'll see a &amp;quot;connect&amp;quot; icon on the main ribbon. Click on it and then on your subscription name. Select &amp;quot;Get Activation Token&amp;quot; in the top ribbon. Your token will be displayed. Copy it and save it.&lt;/p&gt;
&lt;p&gt;&lt;img height="250" style="margin: 5px" width="387" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/1680.Management-Portal-_1320_-Windows-Azure-Platform.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;2. &lt;strong&gt;A local endpoint&lt;/strong&gt;, i.e. a communication service. To install it on the local machine, click on &amp;quot;Install Local Endpoint&amp;quot; in the top ribbon, copy the link provided (note that it contains the token) and use it to open another browser tab. When asked, click &amp;quot;run&amp;quot; to download and install the endpoint. This is a service running as LocalSystem; it uses the HTTPS protocol, so make sure that TCP port 443 outbound is open.&lt;/p&gt;
&lt;p&gt;3. &lt;strong&gt;An endpoint group. &lt;/strong&gt;This is made of local endpoints and azure roles (including VMs) amongst which connectivity is authorized. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Local machines&lt;/strong&gt; will register with Azure Connect after you install the endpoint. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;For Azure roles&lt;/strong&gt;, you need to modify in Visual Studio:&lt;/p&gt;
&lt;p&gt;- &lt;em&gt;The configuration file .cscf&lt;/em&gt;g and include the following line under &amp;quot;Settings&amp;quot;&lt;/p&gt;
&lt;p&gt;&amp;lt;Setting name=&amp;quot;Microsoft.WindowsAzure.Plugins.Connect.ActivationToken&amp;quot; value=&amp;quot;_token_&amp;quot; /&amp;gt;&lt;/p&gt;
&lt;p&gt;where _token_ is the activation token string that you copied in step 1.&lt;/p&gt;
&lt;p&gt;- &lt;em&gt;The service definition file .csdef&lt;/em&gt; and include the following line under &amp;quot;Imports&amp;quot;&lt;/p&gt;
&lt;p&gt;&amp;lt;Import moduleName=&amp;quot;Connect&amp;quot; /&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;img height="249" style="margin: 5px" width="593" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/6761.Windows-XP-Professional.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img height="187" style="margin: 5px" width="623" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/3718.Windows-XP-Professional.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;The same can be done via the GUI. Right-click on the role name, select properties and then &amp;quot;Virtual Network&amp;quot;. Select &amp;quot;Activate Windows Azure Connect&amp;quot;, then paste the token in the relevant field.&lt;/p&gt;
&lt;p&gt;&lt;img height="200" style="margin: 5px" width="684" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/4375.Windows-XP-Professional.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;When you publish the project to Azure with Visual Studio, Azure Connect will be activated for those roles. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Virtual Machines&lt;/strong&gt; are the exception: you have complete control of what the VM contains, no endpoint agent will be installed for you. You must install it in the base image for the vm role before uploading it to Azure. You can obtain the package at &lt;/p&gt;
&lt;p&gt;&lt;em&gt;http://waconnect.blob.core.windows.net/client/latest/x64/wacendpointpackagefull.exe&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;This is not the same URL that you get by clicking &amp;quot;install local endpoint&amp;quot;. Also make sure that IPv6 is enabled in your template (it is by default).&lt;/p&gt;
&lt;p&gt;You must enable Azure Connect in the configuration files as before for the VM role as well. Installing the endpoint package in the template is not sufficient. If you have a running VM where you forgot to install the agent, you can still log into it and perform the installation manually. Alas, this change won't be persisted to the stored template.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Firewall&lt;/strong&gt; ports on the local machines and on Azure roles (except VMs) will be configured automatically during the endpoint installation. If you enforce firewall policies, please make sure to:&lt;/p&gt;
&lt;p&gt;- allow TCP 443 outbound.&lt;/p&gt;
&lt;p&gt;- allow IPv6 protocol, ICMPv6 type 133 and 134 messages (router solicitation and advertisement).&lt;/p&gt;
&lt;p&gt;In the end, you will see a list of the activated machines and roles in your management portal.&lt;/p&gt;
&lt;p&gt;&lt;img height="123" style="margin: 5px" width="765" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/5732.Management-Portal-_1320_-Windows-Azure-Platform.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;You can then create a group and specify which local machines and Azure roles are allowed to connect.&lt;/p&gt;
&lt;p&gt;&lt;img height="450" width="665" style="margin: 5px" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/8080.Management-Portal-_1320_-Windows-Azure-Platform.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;The most common use of Azure virtual networks is domain connectivity. To join an azure role to a corporate domain, you must install a local endpoint on a domain controller that is also a DNS server, then include both role and DC in the same endpoint group (other servers can be included too). In the configuration for the role, you must set specific parameters to enable the domain join. You'll find them in the settings for the role.&lt;/p&gt;
&lt;p&gt;&lt;img height="227" style="margin: 5px" width="648" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/0284.Windows-XP-Professional.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p style="color:#008;text-align:right;"&gt;&lt;small&gt;&lt;em&gt;Powered by&lt;/em&gt; &lt;a href="http://www.qumana.com/"&gt;Qumana&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3422631" width="1" height="1"&gt;</description><category domain="http://blogs.technet.com/b/gmarchetti/archive/tags/Azure/">Azure</category></item><item><title>Azure billing clarification</title><link>http://blogs.technet.com/b/gmarchetti/archive/2011/03/14/azure-billing-clarification.aspx</link><pubDate>Tue, 15 Mar 2011 04:00:33 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3412798</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3412798</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2011/03/14/azure-billing-clarification.aspx#comments</comments><description>&lt;p&gt;A quick clarification: Azure allocates resources to your role as long as it is deployed, whether it is running or not. Billing starts when the deployment is complete and finishes when it is deleted. Roles that are deployed will be billed for the deployed hours, whether they are running or not. &lt;/p&gt;
&lt;p&gt;In summary, if you are not using a role, remove it!&lt;/p&gt;
&lt;p style="color:#008;text-align:right;"&gt;&lt;small&gt;&lt;em&gt;Powered by&lt;/em&gt; &lt;a href="http://www.qumana.com/"&gt;Qumana&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3412798" width="1" height="1"&gt;</description><category domain="http://blogs.technet.com/b/gmarchetti/archive/tags/Azure/">Azure</category></item><item><title>Put a VM on Azure</title><link>http://blogs.technet.com/b/gmarchetti/archive/2011/03/12/put-a-vm-on-azure.aspx</link><pubDate>Sat, 12 Mar 2011 09:57:17 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3412242</guid><dc:creator>gmarchetti</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3412242</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2011/03/12/put-a-vm-on-azure.aspx#comments</comments><description>&lt;p&gt;I have summarized here all the steps you need to take in order to deploy an Azure VM. &lt;/p&gt;
&lt;p&gt;&lt;span style="font-size:16pt"&gt;&lt;strong&gt;Step 1: Get your certificates&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;I assume that you have an active Azure subscription and you have installed visual studio 2010, the azure sdk and tools and activated the VM role. You will need a management certificate for your subscription to deploy services and 1 or more service certificates to communicate with those securely. To generate a x509 certificate for use with the management API:&lt;/p&gt;
&lt;p&gt;1. Open the IIS manager, click on your server.&lt;/p&gt;
&lt;p&gt;2. Select &amp;quot;Server Certificates&amp;quot; in the main panel.&lt;/p&gt;
&lt;p&gt;3. Click &amp;quot;Create Self-Signed Certificate&amp;quot; in the actions panel&lt;/p&gt;
&lt;p&gt;&lt;img height="471" style="margin: 5px" width="631" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/6242.rd.microsoftlab.net.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;4. Give the certificate a friendly name.&lt;/p&gt;
&lt;p&gt;5. Close IIS manager and run certmgr.msc&lt;/p&gt;
&lt;p&gt;6. Find your certificate in &amp;quot;Trusted Root Certification Authorities&amp;quot;&lt;/p&gt;
&lt;p&gt;7. Right-Click on it, select All Tasks / Export&lt;/p&gt;
&lt;p&gt;&lt;img height="446" style="margin: 5px" width="637" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/6064.Windows-XP-Professional.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;8. Do not export the private key, choose the DER format, give it a name.&lt;/p&gt;
&lt;p&gt;9. Navigate to the Windows Azure management portal.&lt;/p&gt;
&lt;p&gt;10. Select Hosted Services / Management Certificates / Add a Certificate&lt;/p&gt;
&lt;p&gt;11. Browse to the management certificate file and upload it.&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size:16pt"&gt;&lt;strong&gt;Step 2: Prepare the VM&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;I assume that you are familiar with Hyper-V and how to build a virtual machine on a hyper-v host.&lt;/p&gt;
&lt;ol&gt;
    &lt;li&gt;Create a virtual machine on hyper-v. Note that the maximum size of virtual hard disk you specify  will determine what size of Azure VM you will be able to choose. An extra-small machine will mount a vhd up to 15 GB, small one up to 35 and medium or more up to 65 GB. This is just the size of the system VHD. You will still receive local storage, mounted as a separate volume.&lt;/li&gt;
    &lt;li&gt;Install Windows Server 2008 R2 on the VHD. It is the only supported o/s as of writing.&lt;/li&gt;
    &lt;li&gt;Install the Azure integration components in the VM. They are contained in the wavmroleic.iso file, which is typically located in c:\progam files\windows azure sdk\&amp;lt;version&amp;gt;\iso. You need to mount that file on the VM and then run the automatic installation process. This provisions the device drivers and management services required by the Azure hypervisor and fabric controller. Note that the setup process asks you for a local administrator password and reboots the VM. The password is encrypted and stored in c:\unattend.xml for future unattended deployment.&lt;/li&gt;
    &lt;li&gt;Install and configure any application, role or update as you normally would.&lt;/li&gt;
    &lt;li&gt;Configure the windows firewall within the VM to open the ports that your application requires. It is recommended that you use fixed local ports.&lt;/li&gt;
    &lt;li&gt;Open and administrator command prompt and run c:\windows\system32\sysprep\sysprep.exe&lt;/li&gt;
    &lt;li&gt;Select &amp;quot;OOBE&amp;quot;, Generalize and Shutdown&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;img height="252" style="margin: 5px" width="345" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/7282.rd.microsoftlab.net.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;This process removes any system-specific data (including the name and SID) from the image, in preparation for re-deployment on Azure. If your application is dependent on those data, you will have to take appropriate measures at startup on Azure (e.g. run a setup script for your application). The VHD is now ready to be uploaded. It is recommended to make a copy of it to keep as a template.&lt;/p&gt;
&lt;p&gt;Note that any deployment to Azure starts from this vhd. No status is saved to local disk if the Azure VMs is recycled for any reason.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;span style="font-size:16pt"&gt;Step 3: Upload the VM to Azure&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;For this you will need a command-line utility provided with the Azure SDK.&lt;/p&gt;
&lt;ol&gt;
    &lt;li&gt;Open a windows azure command prompt as administrator.&lt;/li&gt;
    &lt;li&gt;Type &lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
    &lt;p&gt;&lt;span style="font-family: Courier; font-size: 10pt"&gt;csupload Add-VMImage -Connection &amp;quot;SubscriptionId=&amp;lt;YOUR-SUBSCRIPTION-ID&amp;gt;; CertificateThumbprint=&amp;lt;YOUR-CERTIFICATE-THUMBPRINT&amp;gt;&amp;quot; -Description &amp;quot;&amp;lt;IMAGE DESCRIPTION&amp;gt;&amp;quot; -LiteralPath &amp;quot;&amp;lt;PATH-TO-VHD-FILE&amp;gt;&amp;quot; -Name &amp;lt;IMAGENAME&amp;gt;.vhd -Location &amp;lt;HOSTED-SERVICE-LOCATION&amp;gt; -SkipVerify&lt;/span&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
    &lt;p&gt;The subscription ID can be retrieved from the Azure portal and the certificate thumbprint refers to the management certificate you created and uploaded before. The thumbprint can be retrieved from the portal as well. The description is an arbitrary string, the literal path is the full absolute path on the local disk where you stored your vhd. The image name is the name of the file once stored in Azure and the location is one of those available in the Azure portal. Note that the location must be specific, e.g. &amp;quot;North Central US&amp;quot;. A region is not accepted (e.g. Anywhere US). SkipVerify will save you some time.&lt;/p&gt;
    &lt;p&gt;This command will create a blob in configuration storage and load your vhd file in it for future use, but not create a service or start a VM for you. In the Azure portal the stored virtual machine templates can be found under &amp;quot;VM Images&amp;quot;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img height="181" width="849" style="margin: 5px" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/7558.rd.microsoftlab.net.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;span style="font-size:16pt"&gt;Step 4: Prepare the service model&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Azure requires a service definition and a service configuration file before deploying any role. These are .xml files that are packaged and uploaded to the fabric controller for interpretation. You can generate one for the VM using Visual Studio 2010.&lt;/p&gt;
&lt;p&gt;1. Open Visual Studio 2010 and create a new Windows Azure project.&lt;/p&gt;
&lt;p&gt;2. Do NOT add any role to the project from the project setup wizard. &lt;/p&gt;
&lt;p&gt;3. In the solution explorer panel, right click on the project name and select New Virtual Machine Role. Note that a service may be made of several roles, including multiple VMs.&lt;/p&gt;
&lt;p&gt;&lt;img height="274" style="margin: 5px" width="438" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/5582.rd.microsoftlab.net.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;4. In the VHD configuration dialog, specify your Azure account credentials and which of the stored virtual machine templates you'd like to use.&lt;/p&gt;
&lt;p&gt;&lt;img height="218" style="margin: 5px" width="574" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/8308.rd.microsoftlab.net.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;5. In the Configuration panel specify how many instances you'd like and what type. Remember the size constraints on the system VHDs.&lt;/p&gt;
&lt;p&gt;&lt;img height="218" style="margin: 5px" width="574" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/1440.rd.microsoftlab.net_2D00_1.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;6. In Endpoints, specify which ports and protocol must be open for your applications within the virtual machine (they should match those configured before).&lt;/p&gt;
&lt;p&gt;&lt;img height="173" style="margin: 5px" width="704" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/3678.rd.microsoftlab.net_2D00_1.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;7. Note that RDP connections are configured elsewhere.&lt;/p&gt;
&lt;p&gt;8. Once the VM role configuration is done, right-click on the project name and select Publish. You have an option to create the service configuration package only, to be uploaded later via the portal, or to actually deploy the project. I am assuming that you have not got a service defined yet. It is advisable to configure RDP connections for debugging purposes at least during staging.&lt;/p&gt;
&lt;p&gt;&lt;img height="408" style="margin: 5px" width="727" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/4188.rd.microsoftlab.net_2D00_1.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;9. Select Enable connections, then specify a service certificate. This will contain a private key used to encrypt your credentials. If you have none, you can create one from this interface. If you do create a new certificate, click View, Details and Copy to File to export it. Make sure to include the private key. &lt;/p&gt;
&lt;p&gt;&lt;img height="512" style="margin: 5px" width="412" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/6320.rd.microsoftlab.net_2D00_1.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;10. Specify a user name and password to connect to this virtual machine. Change the account expiration date as necessary (but set it before the certifcate expires).&lt;/p&gt;
&lt;p&gt;11. Select &amp;quot;Create Service Package Only&amp;quot; and save the package file. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;span style="font-size:16pt"&gt;Step 5. Create the service in Azure&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;1. In the Azure Management Portal, select Hosted Services / New Service&lt;/p&gt;
&lt;p&gt;2. Populate the form, specifying a name for your service and deployment options. Note that the location you select must be the same specified at upload time for the virtual machine you want to use. Select the configuration package and file that you saved before. Add the certificate that you exported before for RDP.&lt;/p&gt;
&lt;p&gt;&lt;img height="610" style="margin: 5px" width="533" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/2100.rd.microsoftlab.net_2D00_1.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;3. Click OK to deploy. Start your deployed machines.&lt;/p&gt;
&lt;p&gt;&lt;img height="248" width="451" style="margin: 5px" alt="" src="http://blogs.technet.com/cfs-file.ashx/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-57-03-metablogapi/0083.rd.microsoftlab.net_2D00_1.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;span style="font-size:16pt"&gt;Step 6: Connect and enjoy.&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;From the machine where you generated the RDP certificate, connect to your virtual machines and test. Simply select the virtual machine in the Azure portal and click &amp;quot;connect&amp;quot;. A RDP file will be generated for you to save and open. Once debugging is finished, it is recommended to disable RDP connections for production.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p style="color:#008;text-align:right;"&gt;&lt;small&gt;&lt;em&gt;Powered by&lt;/em&gt; &lt;a href="http://www.qumana.com/"&gt;Qumana&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3412242" width="1" height="1"&gt;</description><category domain="http://blogs.technet.com/b/gmarchetti/archive/tags/Azure/">Azure</category></item><item><title>The Hyper-V Cloud - no clusters?</title><link>http://blogs.technet.com/b/gmarchetti/archive/2010/11/24/the-hyper-v-cloud-no-clusters.aspx</link><pubDate>Thu, 25 Nov 2010 02:19:02 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3371118</guid><dc:creator>gmarchetti</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3371118</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2010/11/24/the-hyper-v-cloud-no-clusters.aspx#comments</comments><description>&lt;p&gt;Microsoft has recently published a set of guides to build your own private cloud solution using Hyper-V, System Center Virtual Machine Manager and its Self-Service Portal 2.0&lt;/p&gt;
&lt;p&gt;They cover planning, deployment and operations. You can find them &lt;a href="http://www.microsoft.com/virtualization/en/us/private-cloud-get-started.aspx"&gt;here.&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Note however that the guides assume a deployment on stand-alone servers. There is no discussion of clustering for high availability.&lt;/p&gt;
&lt;p&gt;I'd like to add a few observations derived from experience of running a private cloud implementation that includes clusters too.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Storage&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;It seems obvious, but local storage is not relevant for clusters. SCVMM will explicitly place virtual machines ONLY on cluster volumes (dedicated or shared). You can still manually create virtual machines on directly-attached disks, but it just complicates things, as they are not easily distinguishable from highly available ones in VMM. It makes sense to purchase systems with a hardware-mirrored boot volume only, plus whatever dedicated storage adapter is appropriate to your workload.&lt;/p&gt;
&lt;p&gt;Clusters tend to drive high consolidation ratios to the storage, for the simple fact that it is shared amongst several nodes. The number of sustained IOps often becomes more relevant than the maximum theoretical bandwidth, as during VM operations you may often find that a lot of relatively small I/Os are performed with a random access pattern. Fibre channel may fit such a profile better than iSCSI. Ideally, you'll profile the load before consolidation, but in a private cloud / infrastructure-on-demand environment you may not have the luxury.&lt;/p&gt;
&lt;p&gt;You'll be well advised to consult the storage vendor's planning guide beforehand.&lt;/p&gt;
&lt;p&gt;Storage vendors often publish the IOps and bandwidth ratings of their arrays. For instance, for the &lt;a href="http://h18000.www1.hp.com/products/quickspecs/13551_div/13551_div.html"&gt;HP P2000 G3&lt;/a&gt;, you will find that 10 Gb/s iSCSI (with dedicated adapters) and 8 Gb/s FC are comparable in bandwidth utilization for large-block sequential reads and writes. However, FC still sustains 20% more IOps than iSCSI with a random 60/40 mix of read-write operations of 8KB blocks.&lt;/p&gt;
&lt;p&gt;Interestingly, 6Gb SAS is equal or slightly better than FC in HP's measurements, which used 4 directly-attached servers (no fabric) for testing. Results may vary when a fabric is involved.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Servers&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Blade servers have grown in popularity and are often recommended for private cloud solution, thanks to their good price / performance ratio, density and flexibility. However, in a highly available implementation due consideration must be given to:&lt;/p&gt;
&lt;p&gt;- Connectivity: Microsoft recommends &lt;em&gt;at least&lt;/em&gt; 4 network ports + 1 storage port (2 better) for each node in a hyper-v cluster. Blade connectivity may limit your options.&lt;/p&gt;
&lt;p&gt;- I/O performance:  i/o bandwidth and operations per second depend on the midplane capabilities. Chassis capable of full redundancy with non-blocking backplanes and 10 Gb/s per lane are available - at a price (e.g. HP &lt;a href="http://h20000.www2.hp.com/bc/docs/support/SupportManual/c00810839/c00810839.pdf"&gt;c7000&lt;/a&gt;). Cheap solutions typically involve some element of oversubscription or no redundancy.&lt;/p&gt;
&lt;p&gt;- Reliability of the shared components. For instance, in a study published on the &lt;a href="http://portal.acm.org/citation.cfm?id=1660947"&gt;IBM Systems Journal&lt;/a&gt;, the lowest mean time to failure (MTTF) belonged to the chassis switch modules, followed by the blade base board. An equivalent external Cisco switch lasts about twice longer between failures, according to published specifications. Even so, according to the same study, a blade availability can reach 99.99% and it is possible to build a 99.999% available infrastructure with blades by having at least 1 &amp;quot;hot-standby&amp;quot; in the chassis, in addition to using redundant components where possible.&lt;/p&gt;
&lt;p&gt;High-end servers (e.g. &lt;a href="http://www-03.ibm.com/systems/x/hardware/enterprise/"&gt;IBM x3850&lt;/a&gt;) are also interesting virtualization platforms, because of hardware becoming more affordable and Windows Datacenter unlimited virtualization rights. They drive high consolidation and operating efficiency, mainly thanks to capacity up to 1TB RAM, 64 cores. They enhance the availability of the basic platform by providing features not commonly found elsewhere, like:&lt;/p&gt;
&lt;p&gt;- &lt;a href="http://en.wikipedia.org/wiki/Chipkill"&gt;ChipKill&lt;/a&gt; or SDDC memory with hot add / replace.&lt;/p&gt;
&lt;p&gt;- Hot-add / remove of i/o adapters.&lt;/p&gt;
&lt;p&gt;- Hot-add CPUs.&lt;/p&gt;
&lt;p&gt;Particular attention must be given to the memory configuration of the servers, especially with the recent NUMA chipsets from Intel and AMD:&lt;/p&gt;
&lt;p&gt;- Populate processor local memory banks with equal amounts of RAM.&lt;/p&gt;
&lt;p&gt;- Populate memory controllers with equal capacity.&lt;/p&gt;
&lt;p&gt;- Populate all memory channels for each controller evenly to exploit the maximum memory bandwidth.&lt;/p&gt;
&lt;p&gt;- Use dual-rank DIMMs.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Network&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Whilst hyper-v will work with any supported network adapters, it is important to notice that certain features will be available only with the appropriate combination of chipsets.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://en.wikipedia.org/wiki/VMQ"&gt;VMQs&lt;/a&gt; (hardware-managed network queues for VMs) are highly recommended for best performance and consolidation ratios, but they require support for interrupt coalescing (in R2), the latest Intel Pro or Broadcom chipsets, appropriate drivers and some registry hacking, as explained &lt;a href="http://technet.microsoft.com/en-us/library/gg162696(WS.10).aspx"&gt;here&lt;/a&gt; and &lt;a href="http://technet.microsoft.com/en-us/library/gg162696(WS.10).aspx#BKMK_Tuning"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;VM Chimney (TCP offload for VMs) has proven unreliable due to driver issues in my experience. I'd rather have VMQs.&lt;/p&gt;
&lt;p&gt;Note that if you enable IPSec or any filter driver on a particular connection (e.g. Windows firewall), that connection may not be offloaded.&lt;/p&gt;
&lt;p&gt;Microsoft does NOT support network teaming with Hyper-V. Teaming is supported by the OEMs. VMQs and teaming may be mutually exclusive, depending on vendor.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Operating System Editions&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;In order to build fail-over clusters, you will need enterprise or datacenter editions. Note that &lt;a href="http://www.microsoft.com/hyper-v-server/en/us/overview.aspx"&gt;Hyper-V Server R2&lt;/a&gt; is also capable of clustering and similar in many respects to enterprise edition. The smaller footprint of Hyper-V Server R2 implies the need to patch it less often than a full edition, hence it is ideal to minimize planned downtime.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;It is possible and legal to purchase datacenter edition (for the unlimited licensing) but deploy Hyper-V Server R2 (for the reduced footprint)&lt;/em&gt;, &lt;em&gt;transferring the licenses.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Cluster Size&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;There are several considerations to determine the number of nodes and machine per node in a cluster:&lt;/p&gt;
&lt;p&gt;- The officially supported maximum is 64 VMs per node in a hyper-v R2 cluster (increasing to 384 in SP1).&lt;/p&gt;
&lt;p&gt;- The officially supported max virtual / physical core ratio is 8:1.&lt;/p&gt;
&lt;p&gt;- Large clusters are more likely to incur in the WMI issues mentioned in my &lt;a href="http://blogs.technet.com/b/gmarchetti/archive/2010/11/19/patches-and-kb-articles-for-hyper-v-r2.aspx"&gt;previous post&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;- It is fine to have the CPU capacity, how about the i/o? How many iops per node can you sustain with your adapter / SAN combination?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Cluster Shared Volumes&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Assuming that you want live migration to minimize planned downtime and optimize allocation of resources, you will need CSVs. A common question is how many machines to deploy on each CSVand how many CSVs to have per cluster. The answer to that depends on several &lt;a href="http://itinfras.blogspot.com/2010/07/factors-that-influence-how-many-cluster.html"&gt;factors&lt;/a&gt;. In my experience, the most troublesome one is the data you need to back up and how long you can tolerate reduced performance during the backup.&lt;/p&gt;
&lt;p&gt;Each time you perform a CSV backup, the server hosting the VM to back up requires ownership of the whole CSV volume to snapshot. I/O to the volume is redirected over the network for all VMs hosted on that volume, with consequent performance impact. The time you can tolerate that, multiplied by the backup throughput will give you the max amount of data to put on that CSV. Divide that by the average size of a VHD and you'll have a rough estimate of how many VMs will fit.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Rules of Thumb&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I claim no scientific basis for the following rules, other than my empirical observations. Here they go, in no particular order:&lt;/p&gt;
&lt;p&gt;1. Keep the number of nodes in a cluster small (2-4) to avoid annoying SCVMM bugs.&lt;/p&gt;
&lt;p&gt;2. Assume a random 60/40 i/o pattern if you don't know in advance what your VM workload will be. It is quite common, in my experience.&lt;/p&gt;
&lt;p&gt;3. Plan for at least 1 management network, 1 for heartbeat, 1 for live migration, 1 dedicated to VMs and 1 dedicated storage adapter. For higher consolidation ratios and availability, plan on 2 storage adapters with MPIO.&lt;/p&gt;
&lt;p&gt;4. Use separate VLANs for management and VMs to isolate traffic and for ease of administration. Consider 10GbE for the shared VM networks in order to minimize the number of adapters and cables.&lt;/p&gt;
&lt;p&gt;5. The quality of VSS (snapshot) and VDS (disk) providers varies greatly with the OEM. Be sure to test them. A snapshot should NOT take longer than 10 seconds or it will fail.&lt;/p&gt;
&lt;p&gt;6. If you don't know how long you can tolerate redirected i/o, 30 minutes is a useful maximum. I have seen CSVs crash in several occasions (again, depending on OEM) after that.&lt;/p&gt;
&lt;p&gt;7. Fail-over clusters do NOT take into account connectivity to the VMs. In other words, if you are sharing the VM network with the host o/s and for some reason that connection fails, the cluster may fail over to another node its own IP addresses on that network but not the VMs attached to it.&lt;/p&gt;
&lt;p&gt;8. A few large servers are easier to manage than many small blades, if you implement appropriate procedures to minimize downtime and have a support contract when things go wrong to fix them quickly :-) They may also be more cost-effective, if you drive consolidation and take advantage of power optimization technology.&lt;/p&gt;
&lt;p&gt;9. Use group policies to control patching with WSUS or similar. Do NOT use the default &amp;quot;download and install at 3am&amp;quot; option on all cluster nodes, or they will all reboot at the same time.&lt;/p&gt;
&lt;p&gt;10. If you don't know your storage vendor's iops ratings, use these ballpark figures on &lt;a href="http://en.wikipedia.org/wiki/IOPS"&gt;wikipedia&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;11. On your hosts, make sure that the antivirus excludes .vhd, .vsv, .avhd files and vmms.exe, vmwp.exe. If you are running hyper-v server only, do you need an antivirus on the host? This is not a rhetorical question by the way; I am interested in opinions.&lt;/p&gt;
&lt;p&gt;12. If you don't know the size of your CSVs in advance, 2 TB works on all MBR and GPT disks. Most backup and restore utilities, snapshot providers etc... can handle 2 TB. It is also a tolerable size should you ever need to run chkdsk or defrag on the volume (few, large vhd files should not cause much trouble or take much time to fix in that respect).&lt;/p&gt;
&lt;p&gt;13. Both fail-over and PRO have no idea of virtual applications, i.e. applications that require a set of interconnected virtual machines. They may move them on different nodes. A way around it is to script the appropriate migration sequence with Powershell.&lt;/p&gt;
&lt;p style="color:#008;text-align:right;"&gt;&lt;small&gt;&lt;em&gt;Powered by&lt;/em&gt; &lt;a href="http://www.qumana.com/"&gt;Qumana&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3371118" width="1" height="1"&gt;</description><category domain="http://blogs.technet.com/b/gmarchetti/archive/tags/Virtualization/">Virtualization</category><category domain="http://blogs.technet.com/b/gmarchetti/archive/tags/Dynamic+Datacenter/">Dynamic Datacenter</category></item><item><title>Patches and KB articles for Hyper-v R2</title><link>http://blogs.technet.com/b/gmarchetti/archive/2010/11/19/patches-and-kb-articles-for-hyper-v-r2.aspx</link><pubDate>Sat, 20 Nov 2010 01:25:21 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3369983</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.technet.com/b/gmarchetti/rsscomments.aspx?WeblogPostID=3369983</wfw:commentRss><comments>http://blogs.technet.com/b/gmarchetti/archive/2010/11/19/patches-and-kb-articles-for-hyper-v-r2.aspx#comments</comments><description>&lt;p&gt;I'd like to share with you some tips to mitigate a few frustrating intermittent problems with hyper-v and system center.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;1. Data Protection Manager 2010&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;BEFORE installing DPM agents on systems running Hyper-V R2, you must install hotfixes&amp;nbsp;&lt;b&gt;&lt;b&gt;KB975921&lt;/b&gt;&amp;nbsp;and KB975354&lt;/b&gt;. Note that if you had a beta or rc version of dpm, upgrading the dpm server will NOT upgrade the agents and you will not be prompted to do so. You will only see "inconsistent replicas".&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The first KB refers to a situation where the volume snapshot provider for your clustered volume crashes and does not return a "completed" signal. Alas, the volume is not returned to its original state, the cluster resource fails and all its virtual machines with it. You may be lucky and never encounter this problem; alas the quality of snapshot providers varies widely so I suggest you install the patch anyway.&lt;/p&gt;
&lt;p&gt;The second KB refers to a common scenario where you want to backup virtual machines running on different nodes of a cluster at the same time. If the machines sit on the same cluster volume, ownership of the volume must be transferred to the node requesting the snapshot at that point. Alas this transfer may happen before the post-snapshot steps of a virtual machine backup are complete, so the replica is inconsistent. If at all possible, I suggest to build the DPM protection groups and time the backups in such a way that frequent transfers of volumes are avoided.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;2. Virtual Machine Manager and Operations Manager&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;VMM and OM agents rely on WMI heavily. When you consolidate dozens of virtual machines on a cluster and want to take advantage of the PRO functionality (hence run both agents on all nodes), the WMI service is heavily loaded and may crash. It restarts without too much fuss and no data is lost, but anything depending on it fails. In your VMM console you may notice that all machines on a node seem to fail at the same time, or that the connection to the VMM agent running on that node times out. Operations manager will also issue critical alerts. Live migrations and deployments may be interrupted. To mitigate the problem, you must install &lt;b&gt;KB974930 and KB981314&lt;/b&gt;. &lt;/p&gt;
&lt;p&gt;The first KB addresses a memory leak of the Win32_Service WMI class. The second KB addresses timeouts in WMI queries about a failover cluster object. &lt;/p&gt;
&lt;p&gt;You may also want to increase the number of concurrent connections and the timeout period for the Windows Remote Management service (winRM). To do so, you could run this script on all nodes of the cluster:&lt;/p&gt;
&lt;p&gt;&lt;i&gt;winrm set winrm/config/Service @{MaxConcurrentOperationsPerUser="400"}&lt;/i&gt;&lt;/p&gt;
&lt;p&gt;&lt;i&gt;winrm set winrm/config @{MaxTimeoutms = "1800000"}&lt;/i&gt;&lt;/p&gt;
&lt;p&gt;&lt;i&gt;net stop vmmagent&lt;/i&gt;&lt;/p&gt;
&lt;p&gt;&lt;i&gt;net stop winrm&lt;/i&gt;&lt;/p&gt;
&lt;p&gt;&lt;i&gt;net start winrm&lt;/i&gt;&lt;/p&gt;
&lt;p&gt;&lt;i&gt;net start vmmagent&lt;/i&gt;&lt;/p&gt;
&lt;p&gt;The script increases the number of concurrent WM operations to 400 (the default is 200) and sets the default timeout to 30 minutes (it should be plenty). Note that this is just the default timeout - operations may specify their own.&lt;/p&gt;
&lt;p&gt;For those values to be taken into consideration, the script then restarts the vmmagent and winrm services.&lt;/p&gt;
&lt;p&gt;In my experience applying these fixes reduces the frequency and duration of such timeouts, but does not eliminate them completely. You may have to tweak the numbers over time to improve the situation further.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3369983" width="1" height="1"&gt;</description></item></channel></rss>