<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
  version="2.0">
  <channel>
    <title>Jennelle on TechNet</title>
    <atom:link
      href="https://docs.microsoft.com/archive/blogs/jennellecrothers/feed.xml"
      rel="self"
      type="application/rss+xml" />
    <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/feed.xml</link>
    <description />
    <lastBuildDate>Wed, 17 Apr 2019 03:33:37 GMT</lastBuildDate>
    <language>en-US</language>
    <sy:updatePeriod>hourly</sy:updatePeriod>
    <sy:updateFrequency>1</sy:updateFrequency>
    <item>
      <title>Nano Server Management</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/nano-server-management</link>
      <pubDate>Tue, 30 Aug 2016 15:13:02 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/08/30/nano-server-management/</guid>
      <description><![CDATA[Where has the time gone? I looked up from my computer and the summer is nearly over! One of the...]]></description>
      <content:encoded><![CDATA[<p>Where has the time gone? I looked up from my computer and the summer is nearly over! One of the things I&#8217;ve been tinkering with as of late with some of my &#8220;infrastructure as code&#8221; projects is Nano Server. Not only is Nano Server gearing up to be a great Hyper-V host and a cool place to start dabbling in containers, it&#8217;s also great server to use when testing deployment scripts because it&#8217;s small and deploys quickly. When all I want to do is spin up and tear down to test my templates, I love being able to use a Windows server with a smaller footprint.</p>
<p>With Nano server being &#8220;headless&#8221;, it only supports remote administration, so this has also lead me to check out all the newish ways we can manage servers remotely. You&#8217;ll need to take a few steps so you can remotely manage a Nano server deployed in Azure.</p>
<ol>
<li><strong>Open NSG on Azure for the Nano Server</strong> &#8211; If you created a VM from the Azure Portal and accept all the defaults (which include an NSG), that NSG doesn’t open the ports for WinRM by default.  It only opens RDP.  The OS firewall is open to accept WinRM and PowerShell, but the NSG blocks it.  You need to edit the NSG to include TCP ports 5985 (http) and/or 5986 (https) for remote management.</li>
<li> <strong>Add Nano External IP Address as a Trusted Host</strong> &#8211; Since you&#8217;ll be connecting to your VM remotely over the public internet, you&#8217;ll need to add that IP address to your trusted host list on your workstation. You can do that via PowerShell or via CMD (just pick one).
<ol>
<li>
<pre>winrm set winrm/config/client @{ TrustedHosts=&quot;13.88.11.166&quot; }</pre>
</li>
<li>
<pre>Set-Item WSMan:\localhost\Client\TrustedHosts &quot;13.88.11.166&quot;</pre>
</li>
</ol>
</li>
</ol>
<p>At this point you should be able to remotely connect to your Nano Server using PowerShell. On your workstation, run (replacing the IP address and username as appropriate):</p>
<pre>$ip = &quot;13.88.11.166&quot;
 $user = &quot;$ip\sysadmin&quot;
 Enter-PSSession -ComputerName $ip -Credential $user</pre>
<p>You&#8217;ll be prompted for your password and then you&#8217;ll be given a remote PowerShell prompt to your Nano VM. But what if you want MORE than just a PowerShell prompt? What if you want access to event logs? Or some basic performance information? Or dare say, use &#8220;Computer Manager&#8221;??</p>
<p>You can use Server Manager tools from workstation or you can use the Azure Server Management Tools (and Gateway).</p>
<p>While your remotely connect to the server you want to manage, you may need to make a few other small changes, particularly if your servers aren&#8217;t domain joined or are on a different subnet than the machine you are connecting from. I recommend checking out this troubleshooting guide &#8211; <a href="https://blogs.technet.microsoft.com/servermanagement/2016/07/20/troubleshooting-problems-with-server-management-tools/">https://blogs.technet.microsoft.com/servermanagement/2016/07/20/troubleshooting-problems-with-server-management-tools/</a></p>
<p>If you specify in Microsoft Azure the local administrator account to connect to the managed server, you have to configure this registry key on the managed server:<br />
REG ADD HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v LocalAccountTokenFilterPolicy /t REG_DWORD /d 1</p>
<p>If you are connecting from a different subnet:<br />
NETSH advfirewall firewall add rule name=”WinRM5985″ protocol=TCP dir=in localport=5985 action=allow</p>
<p>If you want to use Computer Manager and other common Server Manager tools:<br />
Set-NetFirewallRule -DisplayGroup &#8216;Remote Event Log Management&#8217; -Enabled True -PassThru |<br />
select DisplayName, Enabled</p>
<p>Happy Remoting!</p><br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/820/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/820/" /></a> <img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&#038;blog=101098484&#038;post=820&#038;subd=techbunnyblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
    </item>
    <item>
      <title>Deconstructing JSON: Super Secrets</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/deconstructing-json-super-secrets</link>
      <pubDate>Thu, 21 Jul 2016 09:06:56 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/07/21/deconstructing-json-super-secrets/</guid>
      <description><![CDATA[&#8220;Psst… Hey buddy, want to keep your plain text password in your source...]]></description>
      <content:encoded><![CDATA[<p><em>&#8220;Psst… Hey buddy, want to keep your plain text password in your source control?&#8221;</em></p>
<p>Hopefully, you answer is &#8220;No&#8221;, but if you&#8217;d been following along with this JSON/ARM template series of posts, you will have noticed that I&#8217;ve defaulted to deployments with straight up, plain text, username/passwords in my template examples. So before we go any further, lets secure this up a bit!</p>
<p><strong>Goal:</strong> Deploy a Windows Nano VM using an ARM template in GitHub without having to put the Admin username or password anywhere in plain text.</p>
<p>To do this, we&#8217;ll need a place to hide the secrets. In this case, we&#8217;ll use Azure Key Vault. With Key Vault, you create a resource group and vault (using PowerShell or an ARM template) and then load up some secrets or keys. You can hide basic passwords or load certificates.</p>
<p>I&#8217;m going to create my Key Vault using PowerShell. I&#8217;m purposely creating my vault in its own Resource Group. You can create the Key Vault in the same Resource Group as the rest of your deployment, but then if you delete the whole group for during testing, you&#8217;ll have to recreate the vault each time.</p>
<ol>
<li>Log into Azure</li>
<li>Get your Subscription details, copy the GUID of the subscription you want to use for the key vault into the $VSSubID variable.</li>
<li>Customize the variables for the Resource Group name, Vault name and deployment region.</li>
<li>Once the vault is created, customize the &#8220;SuperSecretPassword&#8221; and &#8220;FancyAdminName&#8221; to your liking and add those secrets to the vault.</li>
</ol>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">Login-AzureRmAccount
<span style="color:#658b00;">Get-AzureRmSubscription</span>
<span style="color:#00688b;">$VSSubID</span> = {subcription_guid}  
<span style="color:#658b00;">Set-AzureRmContext</span> -SubscriptionID <span style="color:#00688b;">$VSSubID</span>

<span style="color:#00688b;">$RGName</span> = <span style="color:#cd5555;">&quot;KeyVaultRG&quot;</span>
<span style="color:#00688b;">$VaultName</span> = <span style="color:#cd5555;">&quot;MyVaultName&quot;</span>
<span style="color:#00688b;">$Location</span> = <span style="color:#cd5555;">&quot;West US&quot;</span>

<span style="color:#658b00;">New-AzureRmResourceGroup</span> -Name <span style="color:#00688b;">$RGName</span> -Location <span style="color:#00688b;">$Location</span>

<span style="color:#658b00;">New-AzureRmKeyVault</span> -VaultName <span style="color:#00688b;">$VaultName</span> -ResourceGroupName <span style="color:#00688b;">$RGName</span> -Location <span style="color:#00688b;">$Location</span>

<span style="color:#658b00;">Set-AzureRmKeyVaultAccessPolicy</span> -VaultName <span style="color:#00688b;">$VaultName</span> -EnabledForTemplateDeployment -ResourceGroupName <span style="color:#00688b;">$RGName</span>

<span style="color:#00688b;">$secretvalue</span> = <span style="color:#658b00;">ConvertTo-SecureString</span> <span style="color:#cd5555;">&#39;SuperSecretPassword&#39;</span> -AsPlainText -Force
<span style="color:#00688b;">$secret</span> = <span style="color:#658b00;">Set-AzureKeyVaultSecret</span> -VaultName <span style="color:#00688b;">$VaultName</span> -Name <span style="color:#cd5555;">&#39;ServerAdminPassword&#39;</span> -SecretValue <span style="color:#00688b;">$secretvalue</span>

<span style="color:#00688b;">$secretvalue</span> = <span style="color:#658b00;">ConvertTo-SecureString</span> <span style="color:#cd5555;">&#39;FancyAdminName&#39;</span> -AsPlainText -Force
<span style="color:#00688b;">$secret</span> = <span style="color:#658b00;">Set-AzureKeyVaultSecret</span> -VaultName <span style="color:#00688b;">$VaultName</span> -Name <span style="color:#cd5555;">&#39;ServerAdminName&#39;</span> -SecretValue <span style="color:#00688b;">$secretvalue</span>
</pre>
</div>
<p>Now that my vault is crated, I&#8217;ll need to edit my ARM template to grab the secrets from the Key Vault when my VM is deployed. Make the change to your <strong>parameters.json</strong> file, not your deployment template. This way you can use the same template deployment with different subscriptions and vaults easily. Instead of using the basic string type for your adminUsername and adminPassword, reference the secrets you added to the vault.</p>
<p><!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;"><span style="color:#cd5555;">&quot;adminUsername&quot;</span><span style="color:#a61717;background-color:#e3d2d2;">:</span> {
      <span style="color:#8b008b;font-weight:bold;">&quot;reference&quot;</span>: {
      <span style="color:#8b008b;font-weight:bold;">&quot;keyVault&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;/subscriptions/{guid}/resourceGroups/KeyVaultRG/providers/Microsoft.KeyVault/vaults/ImperfectKeyVault&quot;</span>
      }, 
      <span style="color:#8b008b;font-weight:bold;">&quot;secretName&quot;</span>: <span style="color:#cd5555;">&quot;ServerAdminName&quot;</span> 
       } 
    }<span style="color:#a61717;background-color:#e3d2d2;">,</span>
   <span style="color:#cd5555;">&quot;adminPassword&quot;</span><span style="color:#a61717;background-color:#e3d2d2;">:</span> {
      <span style="color:#8b008b;font-weight:bold;">&quot;reference&quot;</span>: {
      <span style="color:#8b008b;font-weight:bold;">&quot;keyVault&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;/subscriptions/{guid}/resourceGroups/KeyVaultRG/providers/Microsoft.KeyVault/vaults/ImperfectKeyVault&quot;</span>
      }, 
      <span style="color:#8b008b;font-weight:bold;">&quot;secretName&quot;</span>: <span style="color:#cd5555;">&quot;ServerAdminPassword&quot;</span> 
       } 
    }

</pre>
</div>
<p>Now, when you run your deployment, the admin username and password will be pulled from the vault and passed to your VM during creation. If you go to log in that server directly, you&#8217;ll need to provide the plain text versions of those secrets just like usual.  It&#8217;s worth noting that not anyone can pull keys out of your vault.  By default only the subscription admin will be able to access the contents of the vault, but you can add additional permissions to a vault to allow for other users and automation tools to access the same secrets.</p>
<p>You can find the example of this template in my <a href="https://github.com/techbunny/Templates/tree/master/one_nanovm_using_keyvault">GitHub repo</a>.</p>
<p>Learn more about Azure Key Vault at <a href="https://azure.microsoft.com/en-us/documentation/articles/key-vault-get-started/">https://azure.microsoft.com/en-us/documentation/articles/key-vault-get-started/</a></p>
<p>&nbsp;</p><br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/817/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/817/" /></a> <img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&#038;blog=101098484&#038;post=817&#038;subd=techbunnyblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
    </item>
    <item>
      <title>Getting Started with Azure Automation</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/getting-started-with-azure-automation</link>
      <pubDate>Tue, 19 Jul 2016 07:55:40 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/07/19/getting-started-with-azure-automation/</guid>
      <description><![CDATA[As a regular use of an MSDN account with Azure credits, I often find myself running out of credit...]]></description>
      <content:encoded><![CDATA[<p>As a regular use of an MSDN account with Azure credits, I often find myself running out of credit before I expect and it&rsquo;s often my own fault. It&rsquo;s really easy to spin up a server or start experimenting with a service and forget to turn it off or delete it when done. If only a selection of my VMs would turn on during the day and off during the night&hellip;. Enter Azure Automation.<p>&nbsp;</p><p>I looked at Azure Automation when it first came onto the scene, but admittedly struggled with getting it going. The certificate management related to the credentials was challenging, my PowerShell was less than stellar&hellip; and I just got frustrated and moved on to something else.</p><p>&nbsp;</p><p>But after watching my subscription accidentally drain down to nothing 2 weeks before it reset, I had to revisit Azure Automation. The credential management is much easier now and the PowerShell required to start and stop VMs is minimal.</p><p>You&rsquo;ll need two scripts&hellip; one to start and one to stop the desired VMs. You set a schedule for each one and sit back and relax. I&rsquo;ve also been using GitHub a lot for source control and you can tie Azure Automation into that as well.</p><p>My scripts list out each VM I want on the nightly shut down schedule, because I didn&rsquo;t want to have every VM in my subscription shut down automatically, in case I do have a need to keep something running for more than 24 hours. You may want to customize your scripts differently.</p><p>To get started, I recommend following the tutorial in the Azure documentation for &ldquo;<a href="https://azure.microsoft.com/en-us/documentation/articles/automation-first-runbook-textual-powershell/">My First Runbook</a>&rdquo; . It walks you through all the steps of getting your automation account going as well as giving some sample scripts.</p><p>If you like to see the basic scripts I&rsquo;m using for a few of my VMs, you can find them in my <a href="https://github.com/techbunny/AzureAutomation">GitHub repo</a>.</p><p>Automate Away!!</p><br><a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/815/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/815/"></a><img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&amp;blog=101098484&amp;post=815&amp;subd=techbunnyblog&amp;ref=&amp;feed=1" width="1" height="1"></p>
]]></content:encoded>
    </item>
    <item>
      <title>Happy Bastille Day!</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/happy-bastille-day</link>
      <pubDate>Thu, 14 Jul 2016 09:00:00 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/07/14/happy-bastille-day/</guid>
      <description><![CDATA[Bastille Day is the name given in English-speaking countries to the French National Day, which is...]]></description>
      <content:encoded><![CDATA[<div style="font-family:Calibri;font-size:11pt;margin:0;">Bastille Day is the name given in English-speaking countries to the French National Day, which is celebrated on July 14th each year. The French National Day commemorates the beginning of the French Revolution with the storming of the Bastille on July 14, 1789.<div style="font-family:Calibri;font-size:11pt;margin:0;"></div><div style="font-family:Calibri;font-size:11pt;margin:0;">Now, 227 years later, Systems Administrators everywhere might remember this day as the day support ended for Windows Server 2003 in 2015.&nbsp; The successor to Windows 2000 Server it included features from Windows XP that were well loved by IT Pros and consumers alike, leading to it&rsquo;s wide-spread adoption.</div><div style="font-family:Calibri;font-size:11pt;margin:0;"></div><div style="font-family:Calibri;font-size:11pt;margin:0;">Released on April 24, 2003, Windows Server 2003 was very security minded for the time, reducing the attack surface by limiting the number of features installed by default. It also included several compatibility modes to allow older applications to run with more stability and continued to support Window NT 4.0 networking. Improvements were also made to ease the transition from the NT 4.0 directory to Active Directory.</div><div style="font-family:Calibri;font-size:11pt;margin:0;"></div><div style="font-family:Calibri;font-size:11pt;margin:0;">Windows Server 2003 was also the first operating system released by Microsoft after the announcement of its Trustworthy Computing initiative, and as a result, contains a number of changes to security defaults and practices. Some of the cutting edge features of the time included Internet Information Services (IIS) v6.0, the &ldquo;Manage Your Server&rdquo; administrative tool to help with server configuration and improvements to Active Directory and Group Policy administration.</div><div style="font-family:Calibri;font-size:11pt;margin:0;"></div><div style="font-family:Calibri;font-size:11pt;margin:0;">Here are some other great milestones and inventions that we saw in 2003:</div><ul style="direction:ltr;margin-bottom:0;margin-left:.375in;margin-top:0;">
<li style="margin-bottom:0;margin-top:0;vertical-align:middle;"><span style="font-family:Calibri;font-size:11pt;">iTunes Music Store also opens in April 2003.</span></li>
<li style="margin-bottom:0;margin-top:0;vertical-align:middle;"><span style="font-family:Calibri;font-size:11pt;">FluMist by MedImmune released as an alternative to the flu shot.</span></li>
<li style="margin-bottom:0;margin-top:0;vertical-align:middle;"><span style="font-family:Calibri;font-size:11pt;">The Intelligent Oven (</span><a href="http://www.tmio.com/"><span style="font-family:Calibri;font-size:11pt;">www.tmio.com</span></a><span style="font-family:Calibri;font-size:11pt;">) keeps your food refrigerated until the programmed cooking time. Can be remotely controlled via the Internet or by telephone. </span></li>
<li style="margin-bottom:0;margin-top:0;vertical-align:middle;"><span style="font-family:Calibri;font-size:11pt;">Because the CD-ROM was the primary storage medium in the early 2000s, the CD-ROM shredder came onto the scene in 2003.</span></li>
<li style="margin-bottom:0;margin-top:0;vertical-align:middle;"><span style="font-family:Calibri;font-size:11pt;">Java Logs (</span><a href="http://www.pinemountainbrands.com/products/pine-mountain-java-log-4-hour-firelogs"><span style="font-family:Calibri;font-size:11pt;">http://www.pinemountainbrands.com/products/pine-mountain-java-log-4-hour-firelogs</span></a><span style="font-family:Calibri;font-size:11pt;">) &ndash; for those of you who love the open fire but feel bad about burning wood. </span></li>
</ul><div style="font-family:Calibri;font-size:11pt;margin:0;"><span style="font-size:11pt;">If you are still running Windows Server 2003 in your datacenter (a solid year after support has ended), you might want to check out </span><a style="font-size:11pt;" href="http://www.microsoftvirtualacademy.com/product-training/windows-server">some current training</a><span style="font-size:11pt;"> on Microsoft&rsquo;s latest server offerings. Enjoy!</span></div><br><a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/9/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/9/"></a><img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&amp;blog=101098484&amp;post=9&amp;subd=techbunnyblog&amp;ref=&amp;feed=1" width="1" height="1"></div>
]]></content:encoded>
    </item>
    <item>
      <title>Deconstructing JSON: Counting On</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/deconstructing-json-counting-on</link>
      <pubDate>Fri, 17 Jun 2016 14:11:32 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/06/17/deconstructing-json-counting-on/</guid>
      <description><![CDATA[So here I am, in JSON-land, working on my deployment for VMs. But so far, I&#8217;ve only deployed...]]></description>
      <content:encoded><![CDATA[<p>So here I am, in JSON-land, working on my deployment for VMs. But so far, I&#8217;ve only deployed one VM in my network. But one VM is boring. I want to be able to rack and stack more than one machine at a time! :-)  Enter the copy object and the copyIndex function!  You can read the <a href="https://azure.microsoft.com/en-us/documentation/articles/resource-group-create-multiple/">official documentation</a> about it, but let see how this works within my existing template. Things to note:</p>
<ul>
<li>You can only reference the copyIndex function in RESOURCES. Don&#8217;t try to build variables with them, you&#8217;ll just be sad.</li>
<li>You can&#8217;t use a copy loop in a nested resource (this blog series hasn&#8217;t encountered this yet).</li>
<li>You can&#8217;t use them to loop items that are defined as properties within a resource, like multiple data disks.</li>
</ul>
<p>So in my example, let&#8217;s extend the template to deploy 3 VMs in the same subnet and put them all in the same NSG (network security group). First, you must declare in the parameters that you&#8217;d like count something:</p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">   <span style="color:#cd5555;">&quot;count&quot;</span><span style="color:#a61717;background-color:#e3d2d2;">:</span> { 
      <span style="color:#8b008b;font-weight:bold;">&quot;type&quot;</span>: <span style="color:#cd5555;">&quot;int&quot;</span>, 
      <span style="color:#8b008b;font-weight:bold;">&quot;defaultValue&quot;</span>: <span style="color:#b452cd;">3</span> 
    }<span style="color:#a61717;background-color:#e3d2d2;">,</span>
</pre>
</div>
<p>Now, whenever you want to reference the &#8220;current iteration&#8221; of the loop elsewhere in your template, you&#8217;ll use copyIndex(). Another thing to note &#8211; computers like to count starting at zero, humans like to count starting at 1. If we stick with <strong>copyIndex(),</strong> we&#8217;ll get VMs numbered 0, 1, 2. If you&#8217;d like them to be numbered 1, 2, 3 use <strong>copyIndex(1),</strong> which will offset the numbering by 1.</p>
<p>Since this template is going to create 3 VMs, we will need to make sure to account for other resources that VMs have a one to one relationship with and be sure to loop those as well. The only items that we are required to loop are the network interfaces and the public IP addresses (which have individual DNS names).  We don&#8217;t have to loop things like the storage account (which can be used by multiple VMs) or the network, since we only need one in this case.</p>
<p>In the resource for the publicIPAddresses, you&#8217;ll see the reference to the copyIndex() in the name, and in the DNS domain label. In each case, the incremented number will be tacked on at the end of each. Then finally, you&#8217;ll see the specific reference to looping this resource added, with the name of <strong>&#8220;pubipcopy&#8221;</strong>, pulling the count from the parameter you set early.<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">     {
      <span style="color:#8b008b;font-weight:bold;">&quot;type&quot;</span>: <span style="color:#cd5555;">&quot;Microsoft.Network/publicIPAddresses&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;apiVersion&quot;</span>: <span style="color:#cd5555;">&quot;2015-06-15&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;[concat(parameters(&#39;publicIPAddressName&#39;), parameters(&#39;dnsNameForPublicIP&#39;),copyIndex())]&quot;</span>, 
      <span style="color:#8b008b;font-weight:bold;">&quot;location&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;location&#39;)]&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;publicIPAllocationMethod&quot;</span>: <span style="color:#cd5555;">&quot;[variables(&#39;publicIPAddressType&#39;)]&quot;</span>,
        <span style="color:#8b008b;font-weight:bold;">&quot;idleTimeoutInMinutes&quot;</span>: <span style="color:#b452cd;">4</span>,
        <span style="color:#8b008b;font-weight:bold;">&quot;dnsSettings&quot;</span>: {
          <span style="color:#8b008b;font-weight:bold;">&quot;domainNameLabel&quot;</span>: <span style="color:#cd5555;">&quot;[concat(parameters(&#39;dnsNameForPublicIP&#39;),copyIndex())]&quot;</span>
        }
      },
       <span style="color:#8b008b;font-weight:bold;">&quot;copy&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;pubipcopy&quot;</span>,
        <span style="color:#8b008b;font-weight:bold;">&quot;count&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;count&#39;)]&quot;</span>
      }
     }<span style="color:#a61717;background-color:#e3d2d2;">,</span>
</pre>
</div>
<p>One of the reasons you need to name each resource copy object is so they can be used in places where dependencies are required.</p>
<p>For the network interface, you&#8217;ll see I&#8217;ve made similar references to the copyIndex() in the name. Also a network interface is dependent on the existence of a public IP address, so you&#8217;ll see &#8220;pubipcopy&#8221; referenced under &#8220;dependsOn&#8221; as well as in the IP configuration properties.<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">   {
      <span style="color:#8b008b;font-weight:bold;">&quot;apiVersion&quot;</span>: <span style="color:#cd5555;">&quot;2015-06-15&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;type&quot;</span>: <span style="color:#cd5555;">&quot;Microsoft.Network/networkInterfaces&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;[concat(parameters(&#39;nicName&#39;), copyIndex())]&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;location&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;location&#39;)]&quot;</span>,
    
      <span style="color:#8b008b;font-weight:bold;">&quot;dependsOn&quot;</span>: [
        <span style="color:#cd5555;">&quot;pubipcopy&quot;</span>,
        <span style="color:#cd5555;">&quot;[concat(&#39;Microsoft.Network/virtualNetworks/&#39;, parameters(&#39;vnetName&#39;))]&quot;</span>,
        <span style="color:#cd5555;">&quot;[resourceId(&#39;Microsoft.Network/networkSecurityGroups&#39;, parameters(&#39;networkSecurityGroupName&#39;))]&quot;</span>
      ],
      <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;ipConfigurations&quot;</span>: [
          {
            <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;ipconfig1&quot;</span>,
            <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
             <span style="color:#8b008b;font-weight:bold;">&quot;privateIPAllocationMethod&quot;</span>: <span style="color:#cd5555;">&quot;Dynamic&quot;</span>,
             <span style="color:#8b008b;font-weight:bold;">&quot;publicIPAddress&quot;</span>: {
                <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;[resourceId(&#39;Microsoft.Network/publicIPAddresses&#39;, concat(parameters(&#39;publicIPAddressName&#39;),parameters(&#39;dnsNameForPublicIP&#39;),copyIndex()))]&quot;</span>
              },
              <span style="color:#8b008b;font-weight:bold;">&quot;subnet&quot;</span>: {
                <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;[variables(&#39;subnetRef&#39;)]&quot;</span>
              }
              }
          }
        ],
       <span style="color:#8b008b;font-weight:bold;">&quot;dnsSettings&quot;</span>: {
         <span style="color:#8b008b;font-weight:bold;">&quot;dnsServers&quot;</span>: []
       },
       <span style="color:#8b008b;font-weight:bold;">&quot;enableIPForwarding&quot;</span>: <span style="color:#8b008b;font-weight:bold;">false</span>,
       <span style="color:#8b008b;font-weight:bold;">&quot;networkSecurityGroup&quot;</span>: {
               <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;[resourceId(&#39;Microsoft.Network/networkSecurityGroups&#39;, parameters(&#39;networkSecurityGroupName&#39;))]&quot;</span>
            }
      },
       <span style="color:#8b008b;font-weight:bold;">&quot;copy&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;niccopy&quot;</span>,
        <span style="color:#8b008b;font-weight:bold;">&quot;count&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;count&#39;)]&quot;</span>
      }
    }<span style="color:#a61717;background-color:#e3d2d2;">,</span>
</pre>
</div>
<p>This all comes together when you get to the VM resource where it refers to the NIC in the network profile and using the copyIndex() when creating the VM name, computer name and OS disk.<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">    {
      <span style="color:#8b008b;font-weight:bold;">&quot;apiVersion&quot;</span>: <span style="color:#cd5555;">&quot;2015-06-15&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;type&quot;</span>: <span style="color:#cd5555;">&quot;Microsoft.Compute/virtualMachines&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;[concat(&#39;NanoVM-&#39;, copyIndex())]&quot;</span>, 
      <span style="color:#8b008b;font-weight:bold;">&quot;location&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;location&#39;)]&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;copy&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;vmcopy&quot;</span>,
        <span style="color:#8b008b;font-weight:bold;">&quot;count&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;count&#39;)]&quot;</span>
        },
      <span style="color:#8b008b;font-weight:bold;">&quot;dependsOn&quot;</span>: [
        
        <span style="color:#cd5555;">&quot;[concat(&#39;Microsoft.Storage/storageAccounts/&#39;, parameters(&#39;newStorageAccountName&#39;))]&quot;</span>,
        <span style="color:#cd5555;">&quot;niccopy&quot;</span>
      ],
      <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;hardwareProfile&quot;</span>: {
          <span style="color:#8b008b;font-weight:bold;">&quot;vmSize&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;vmSize&#39;)]&quot;</span>
        },
        <span style="color:#8b008b;font-weight:bold;">&quot;osProfile&quot;</span>: {
          <span style="color:#8b008b;font-weight:bold;">&quot;computerName&quot;</span>: <span style="color:#cd5555;">&quot;[concat(&#39;NanoVM-&#39;, copyIndex())]&quot;</span>,
          <span style="color:#8b008b;font-weight:bold;">&quot;adminUsername&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;adminUsername&#39;)]&quot;</span>,
          <span style="color:#8b008b;font-weight:bold;">&quot;adminPassword&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;adminPassword&#39;)]&quot;</span>
        },
        <span style="color:#8b008b;font-weight:bold;">&quot;storageProfile&quot;</span>: {
          <span style="color:#8b008b;font-weight:bold;">&quot;imageReference&quot;</span>: {
            <span style="color:#8b008b;font-weight:bold;">&quot;publisher&quot;</span>: <span style="color:#cd5555;">&quot;[variables(&#39;imagePublisher&#39;)]&quot;</span>,
            <span style="color:#8b008b;font-weight:bold;">&quot;offer&quot;</span>: <span style="color:#cd5555;">&quot;[variables(&#39;imageOffer&#39;)]&quot;</span>,
            <span style="color:#8b008b;font-weight:bold;">&quot;sku&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;windowsOSVersion&#39;)]&quot;</span>,
            <span style="color:#8b008b;font-weight:bold;">&quot;version&quot;</span>: <span style="color:#cd5555;">&quot;latest&quot;</span>
          },
          <span style="color:#8b008b;font-weight:bold;">&quot;osDisk&quot;</span>: {
            <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;[concat(&#39;osdisk_&#39;, concat(&#39;NanoVM-&#39;, copyIndex()))]&quot;</span> ,
            <span style="color:#8b008b;font-weight:bold;">&quot;vhd&quot;</span>: {
              <span style="color:#8b008b;font-weight:bold;">&quot;uri&quot;</span>: <span style="color:#cd5555;">&quot;[concat(&#39;http://&#39;,parameters(&#39;newStorageAccountName&#39;),&#39;.blob.core.windows.net/&#39;,variables(&#39;vmStorageAccountContainerName&#39;),&#39;/NanoVM-&#39;,copyIndex(),uniqueString(resourceGroup().id),&#39;-osdisk.vhd&#39;)]&quot;</span>
            },
            <span style="color:#8b008b;font-weight:bold;">&quot;caching&quot;</span>: <span style="color:#cd5555;">&quot;ReadWrite&quot;</span>,
            <span style="color:#8b008b;font-weight:bold;">&quot;createOption&quot;</span>: <span style="color:#cd5555;">&quot;FromImage&quot;</span>
          }
          },
            
          <span style="color:#8b008b;font-weight:bold;">&quot;networkProfile&quot;</span>: {
          <span style="color:#8b008b;font-weight:bold;">&quot;networkInterfaces&quot;</span>: [             
        {
              <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;[resourceId(&#39;Microsoft.Network/networkInterfaces&#39;,concat(parameters(&#39;nicName&#39;), copyIndex()))]&quot;</span>
            }
          ]
        },
          <span style="color:#8b008b;font-weight:bold;">&quot;diagnosticsProfile&quot;</span>: {
          <span style="color:#8b008b;font-weight:bold;">&quot;bootDiagnostics&quot;</span>: {
             <span style="color:#8b008b;font-weight:bold;">&quot;enabled&quot;</span>: <span style="color:#cd5555;">&quot;true&quot;</span>,
             <span style="color:#8b008b;font-weight:bold;">&quot;storageUri&quot;</span>: <span style="color:#cd5555;">&quot;[concat(&#39;https://&#39;,parameters(&#39;newStorageAccountName&#39;),&#39;.blob.core.windows.net&#39;)]&quot;</span>
          }
        }
        }

      }
</pre>
</div>
<p>You can find my full template here: <a href="https://github.com/techbunny/Templates/tree/master/multiple_nano_server">https://github.com/techbunny/Templates/tree/master/multiple_nano_server</a></p><br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/811/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/811/" /></a> <img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&#038;blog=101098484&#038;post=811&#038;subd=techbunnyblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
    </item>
    <item>
      <title>ARM Templates: What Error?!?</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/arm-templates-what-error</link>
      <pubDate>Thu, 09 Jun 2016 10:28:13 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/06/09/arm-templates-what-error/</guid>
      <description><![CDATA[There is more than one way to deploy an ARM template once you&#8217;ve created or edited on to your...]]></description>
      <content:encoded><![CDATA[<p>There is more than one way to deploy an ARM template once you&#8217;ve created or edited on to your liking. The first way is to copy the code into a blank template deployment in the Azure portal. This has a few benefits, primarily that it gives you the option to edit any parameters in the template to your liking before deployment and saves you from having to write a separate &#8220;azuredeploy.parameters.json&#8221; file.</p>
<p>However the deployment blade in the portal doesn&#8217;t really give you much in the way of error messages when the template fails. Often, you are give something along the lines of &#8220;error exists on line 1: position 10,374&#8221; or some such information. But your template is clearly more than one line in length and I have no intention of counting out thousands of characters to find the error location. The full text of the message may or may not be helpful depending on what point in the deployment the error occurred.</p>
<p>This is where deploying the template via PowerShell shines. As much as the red text is heartbreaking, it will give you the proper line number and position count to line up with your code. Also included is some often useable error text to point you on your way.</p>
<p>This single line of PowerShell will deploy a template that is hosted online (like in GitHub) and the -Verbose switch will report on the status of each of your resources as they start and complete deployment.<br />
<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;"><span style="color:#658b00;">New-AzureRmResourceGroupDeployment</span> -ResourceGroupName <span style="color:#cd5555;">&quot;&lt;YourResourceGroupName&gt;&quot;</span> -TemplateURI <span style="color:#00688b;">$templateFileURI</span> -TemplateParameterURI <span style="color:#00688b;">$parameterFileURI</span> -Verbose
</pre>
</div>
<p>If that doesn&#8217;t solve your problem or point you in the right direction, it&#8217;s time to dig deeper in the Azure Audit Logs from within the portal. They are chronological, so after a few clicks, you can drill down into the details of the most recent error. You can also access those logs via PowerShell:<br />
<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;"><span style="color:#658b00;">Get-AzureRmLog</span> -Status Failed -ResourceGroup <span style="color:#cd5555;">&quot;YourResourceGroupName&quot;</span> -DetailedOutput
</pre>
</div>
<p>You can also access these logs by digging down into the deployment in the portal. Just to &#8220;Audit Logs&#8221; and you&#8217;ll find all the activity in your subscriptions. Looked for the ones related to failed deployments or validations of deployments and as you drill into the details you&#8217;ll find what&#8217;s going wrong. Usually it&#8217;s an incorrect location of a parameters file, maybe a storage account name that&#8217;s already in use, or a missing resource group.</p>
<p>Happy Hunting!</p><br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/808/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/808/" /></a> <img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&#038;blog=101098484&#038;post=808&#038;subd=techbunnyblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
    </item>
    <item>
      <title>How Microsoft IT does the Cloud</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/how-microsoft-it-does-the-cloud</link>
      <pubDate>Tue, 07 Jun 2016 14:01:14 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/06/07/how-microsoft-it-does-the-cloud/</guid>
      <description><![CDATA[One of the things that is fascinating about working at Microsoft is watching how we function...]]></description>
      <content:encoded><![CDATA[<p>One of the things that is fascinating about working at Microsoft is watching how we function internally as our own &ldquo;customer&rdquo;.  This is very apparent when it comes to integrating with cloud solutions like Azure.  We have the same challenges as any other external customer, with the added bonus of developing, testing and implementing our own solutions. Sometimes people will ask me something like &ldquo;You work for Microsoft, isn&rsquo;t Azure just free for you?&rdquo;<p>Alas, it is not. Every bit of Azure I use to learn, test and demo is accounted for somewhere, and I&rsquo;m just lucky my manager hasn&rsquo;t come after me holding an embarrassing bill to explain! </p><p>The MSIT Showcase has a host of documents, case studies and webinars to peel back the curtain and give you an idea of what it&rsquo;s like to move many critical workloads into the cloud.  Here are three links to get you started:</p><p>The cloud security mindset (Article) &ndash;<br>
<a href="https://www.microsoft.com/itshowcase/Article/Content/703/The-cloud-security-mindset" rel="nofollow">https://www.microsoft.com/itshowcase/Article/Content/703/The-cloud-security-mindset</a></p><p>Managing resource efficiency in a hybrid cloud (Webinar) &ndash;<br>
<a href="https://www.microsoft.com/itshowcase/Article/Content/702/How-Microsoft-IT-manages-resource-efficiency-in-Azure-and-onpremises" rel="nofollow">https://www.microsoft.com/itshowcase/Article/Content/702/How-Microsoft-IT-manages-resource-efficiency-in-Azure-and-onpremises</a> </p><p>Architecting your network for successful Azure adoption (Case study) &ndash;<br>
<a href="https://www.microsoft.com/itshowcase/Article/Content/648/Architecting-your-network-for-successful-Azure-adoption" rel="nofollow">https://www.microsoft.com/itshowcase/Article/Content/648/Architecting-your-network-for-successful-Azure-adoption</a> </p><p>Enjoy!</p><br><a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/806/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/806/"></a><img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&amp;blog=101098484&amp;post=806&amp;subd=techbunnyblog&amp;ref=&amp;feed=1" width="1" height="1"></p>
]]></content:encoded>
    </item>
    <item>
      <title>New on MVA: Power Tools for Windows 10</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/new-on-mva-power-tools-for-windows-10</link>
      <pubDate>Fri, 27 May 2016 16:06:57 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/05/27/new-on-mva-power-tools-for-windows-10/</guid>
      <description><![CDATA[I&rsquo;m pretty sure you&rsquo;ll all be busy relaxing for the long weekend, but if you do need...]]></description>
      <content:encoded><![CDATA[<p>I&rsquo;m pretty sure you&rsquo;ll all be busy relaxing for the long weekend, but if you do need something to do check out this MVA course on Windows 10 with Ed Bott. Otherwise, it&rsquo;ll still be here for you on Tuesday!<p><a href="https://mva.microsoft.com/en-US/training-courses-embed/power-tools-for-windows-10-16405">https://mva.microsoft.com/en-US/training-courses-embed/power-tools-for-windows-10-16405</a></p><br><a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/803/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/803/"></a><img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&amp;blog=101098484&amp;post=803&amp;subd=techbunnyblog&amp;ref=&amp;feed=1" width="1" height="1"></p>
]]></content:encoded>
    </item>
    <item>
      <title>A May Shower of Resources for IT Pros</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/a-may-shower-of-resources-for-it-pros</link>
      <pubDate>Fri, 06 May 2016 10:57:24 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/05/06/a-may-shower-of-resources-for-it-pros/</guid>
      <description><![CDATA[It&rsquo;s May (already!!) and with it brings a bunch of good resources for IT Pros looking to...]]></description>
      <content:encoded><![CDATA[<p>It&rsquo;s May (already!!) and with it brings a bunch of good resources for IT Pros looking to refresh their skills this spring.&nbsp; Your first two stops should be the new <a href="https://www.itprocloudessentials.com/">IT Pro Cloud Essentials</a> and <a href="https://www.itprocareercenter.com">IT Pro Career Center</a>, which provide access to some great tools and features to help you tune up your skill set for the future, including:<ul>
<li>A 3 month Pluralsight subscription</li>
<li>Role specific MVA training suggestions</li>
<li>One free exam voucher (limited supply, don&rsquo;t wait to claim this!)</li>
<li>Azure credits and trials!</li>
<li>Guidance for career mapping, including salary information</li>
</ul><p>If you are looking for something to read and want to refresh the items on your e-reader, this recommendation comes straight from Jeffrey Snover &ndash; the free e-book on <a href="https://blogs.msdn.microsoft.com/microsoft_press/2016/04/20/free-ebook-introducing-windows-server-2016-technical-preview/">Windows Server 2016 Technical Preview</a>.</p><p>If you are already starting to architect a hybrid solution for your organization, I highly recommend checking out some of the architecture resources for <a href="https://technet.microsoft.com/library/dn919927.aspx#hybrid">hybrid cloud</a> and other cloud related systems, like storage and networking.&nbsp; These are great Visio diagrams and posters to help you understand and explain what changes might benefit your company.</p><ul>
<li><strong>Hybrid cloud overview&nbsp; </strong>Microsoft&rsquo;s cloud offerings (SaaS, Azure PaaS, and Azure IaaS) and their common elements.</li>
<li><strong>Architecture of Microsoft hybrid cloud scenarios&nbsp; </strong>An architectural diagram of hybrid cloud for Microsoft&rsquo;s cloud offerings, showing the common layers of on-premises infrastructure, networking, and identity.</li>
<li><strong>Hybrid cloud scenarios for Microsoft SaaS (Office 365)&nbsp; </strong>The SaaS hybrid scenario architecture and descriptions of key hybrid configurations for Skype for Business, SharePoint Server, and Exchange Server (2 printed pages).</li>
<li><strong>Hybrid cloud scenarios for Azure PaaS&nbsp; </strong>The Azure PaaS hybrid scenario architecture and the description of an Azure PaaS hybrid application, with an example.</li>
<li><strong>Hybrid cloud scenarios for Azure IaaS&nbsp; </strong>The Azure IaaS hybrid scenario architecture and the description of a line of business (LOB) application hosted in Azure IaaS.</li>
</ul><p>Finally, if you are a Bay Area local, keep an eye on the <a href="http://www.microsoftreactor.com/events">Microsoft Reactor events calendar</a>.&nbsp; The Reactor hosts a variety of community events on a variety of topics, including Microsoft and open source technology.</p><p>&nbsp;</p><br><a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/801/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/801/"></a><img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&amp;blog=101098484&amp;post=801&amp;subd=techbunnyblog&amp;ref=&amp;feed=1" width="1" height="1"></p>
]]></content:encoded>
    </item>
    <item>
      <title>Deconstructing JSON: Adding a Network Security Group</title>
      <link>https://docs.microsoft.com/archive/blogs/jennellecrothers/deconstructing-json-adding-a-network-security-group</link>
      <pubDate>Thu, 05 May 2016 09:40:16 GMT</pubDate>
      <dc:creator><![CDATA[Jennelle Crothers]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/jennellecrothers/2016/05/05/deconstructing-json-adding-a-network-security-group/</guid>
      <description><![CDATA[If you&#8217;ve come from the Service Manager days of Azure, you&#8217;ll be familiar with the...]]></description>
      <content:encoded><![CDATA[<p>If you&#8217;ve come from the Service Manager days of Azure, you&#8217;ll be familiar with the endpoints that came with each Cloud Service, handling the port forwarding needed to RDP to your server or to connect with PowerShell (port 5986). You could add or remove endpoints as need to provide access to whatever service you desired (after making the corresponding firewall change on the server itself.)</p>
<p>This is like parking your car in a garage.  You can choose to lock or unlock the doors (aka the OS firewall) and you can choose to provide access to the garage (aka Azure endpoints).</p>
<p>With ARM, when you deploy a server, you&#8217;ll be prompted to confirm the naming of your <a href="https://azure.microsoft.com/en-us/documentation/articles/virtual-networks-nsg/">network security group</a>, this network security group takes the place of the endpoints: providing some default rules, including the RDP access to port 3389.</p>
<p>So how does this differ from an endpoint?  One difference is that there is no port forwarding.  With a cloud service endpoint, the external port wasn&#8217;t 3389, because you could have multiple servers behind the single IP address assigned to the cloud service sharing the load balancer.   With ARM, the VM is assigned its own IP address without a load balancer, so the standard port number can be used. If you need to open an additional port, you simply add a new rule to the NSG and open the corresponding rule on the server firewall.</p>
<p>The second difference is that without a NSG (or the cloud service load balancer endpoints) to act as a gateway, your VM is basically just &#8220;hanging out there&#8221; with only its internal firewall to keep it safe.  So you really need to be sure you&#8217;ve checked that firewall configuration and you know what&#8217;s open to the public network.  By default, a Windows VM created with an Azure image has RDP and PowerShell/WinRM ports open on the operating system.</p>
<p>If you&#8217;ve been following along with my JSON template project, you&#8217;ll know that VMs can be created in ARM without the NSG.  And this fine if you are good with having your server parked out on the Internet with a few doors unlocked, so to speak.</p>
<p>But if you want to take advantage of the power of Network Security Groups to limit the sources of connections or to customize the way traffic flows between tiers of servers on your network, you&#8217;ll need to include the NSG resource in your template.</p>
<p>First you&#8217;ll  need to add a parameter to declare the Network Security Group.<br />
<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">  <span style="color:#cd5555;">&quot;networkSecurityGroupName&quot;</span><span style="color:#a61717;background-color:#e3d2d2;">:</span> {
            <span style="color:#8b008b;font-weight:bold;">&quot;defaultValue&quot;</span>: <span style="color:#cd5555;">&quot;NanoVMnsg&quot;</span>,
            <span style="color:#8b008b;font-weight:bold;">&quot;type&quot;</span>: <span style="color:#cd5555;">&quot;string&quot;</span>
    }<span style="color:#a61717;background-color:#e3d2d2;">,</span>
</pre>
</div>
<p>Then you&#8217;ll to configure the resource itself to include the security rules.<br />
<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">{
      <span style="color:#8b008b;font-weight:bold;">&quot;type&quot;</span>: <span style="color:#cd5555;">&quot;Microsoft.Network/networkSecurityGroups&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;networkSecurityGroupName&#39;)]&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;apiVersion&quot;</span>: <span style="color:#cd5555;">&quot;2015-06-15&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;location&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;location&#39;)]&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
            <span style="color:#8b008b;font-weight:bold;">&quot;securityRules&quot;</span>: [
                {
                    <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;winrm&quot;</span>,
                    <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
                        <span style="color:#8b008b;font-weight:bold;">&quot;protocol&quot;</span>: <span style="color:#cd5555;">&quot;Tcp&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;sourcePortRange&quot;</span>: <span style="color:#cd5555;">&quot;*&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;destinationPortRange&quot;</span>: <span style="color:#cd5555;">&quot;5985-5986&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;sourceAddressPrefix&quot;</span>: <span style="color:#cd5555;">&quot;*&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;destinationAddressPrefix&quot;</span>: <span style="color:#cd5555;">&quot;*&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;access&quot;</span>: <span style="color:#cd5555;">&quot;Allow&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;priority&quot;</span>: <span style="color:#b452cd;">110</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;direction&quot;</span>: <span style="color:#cd5555;">&quot;Inbound&quot;</span>
                    }
                  },
                  {
                    <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;rdp&quot;</span>,
                    <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
                        <span style="color:#8b008b;font-weight:bold;">&quot;protocol&quot;</span>: <span style="color:#cd5555;">&quot;Tcp&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;sourcePortRange&quot;</span>: <span style="color:#cd5555;">&quot;*&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;destinationPortRange&quot;</span>: <span style="color:#cd5555;">&quot;3389&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;sourceAddressPrefix&quot;</span>: <span style="color:#cd5555;">&quot;*&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;destinationAddressPrefix&quot;</span>: <span style="color:#cd5555;">&quot;*&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;access&quot;</span>: <span style="color:#cd5555;">&quot;Allow&quot;</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;priority&quot;</span>: <span style="color:#b452cd;">120</span>,
                        <span style="color:#8b008b;font-weight:bold;">&quot;direction&quot;</span>: <span style="color:#cd5555;">&quot;Inbound&quot;</span>
                    }
                 }
                ]
            },
            <span style="color:#8b008b;font-weight:bold;">&quot;dependsOn&quot;</span>: []
        }<span style="color:#a61717;background-color:#e3d2d2;">,</span>
</pre>
</div>
<p>Finally, you&#8217;ll need to adjust your network interface resource to depend on the NSG.<br />
<!-- HTML generated using hilite.me --></p>
<div style="background:#eeeedd;overflow:auto;width:auto;border:solid gray;border-width:.1em .1em .1em .8em;padding:.2em .6em;">
<pre style="margin:0;line-height:125%;">{
      <span style="color:#8b008b;font-weight:bold;">&quot;apiVersion&quot;</span>: <span style="color:#cd5555;">&quot;2015-06-15&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;type&quot;</span>: <span style="color:#cd5555;">&quot;Microsoft.Network/networkInterfaces&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;[variables(&#39;nicName&#39;)]&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;location&quot;</span>: <span style="color:#cd5555;">&quot;[parameters(&#39;location&#39;)]&quot;</span>,
      <span style="color:#8b008b;font-weight:bold;">&quot;dependsOn&quot;</span>: [
        <span style="color:#cd5555;">&quot;[concat(&#39;Microsoft.Network/publicIPAddresses/&#39;, variables(&#39;publicIPAddressName&#39;))]&quot;</span>,
        <span style="color:#cd5555;">&quot;[concat(&#39;Microsoft.Network/virtualNetworks/&#39;, parameters(&#39;vnetName&#39;))]&quot;</span>,
        <span style="color:#cd5555;">&quot;[resourceId(&#39;Microsoft.Network/networkSecurityGroups&#39;, parameters(&#39;networkSecurityGroupName&#39;))]&quot;</span>
      ],
      <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
        <span style="color:#8b008b;font-weight:bold;">&quot;ipConfigurations&quot;</span>: [
          {
            <span style="color:#8b008b;font-weight:bold;">&quot;name&quot;</span>: <span style="color:#cd5555;">&quot;ipconfig1&quot;</span>,
            <span style="color:#8b008b;font-weight:bold;">&quot;properties&quot;</span>: {
             <span style="color:#8b008b;font-weight:bold;">&quot;privateIPAllocationMethod&quot;</span>: <span style="color:#cd5555;">&quot;Dynamic&quot;</span>,
             <span style="color:#8b008b;font-weight:bold;">&quot;publicIPAddress&quot;</span>: {
                <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;[resourceId(&#39;Microsoft.Network/publicIPAddresses&#39;,variables(&#39;publicIPAddressName&#39;))]&quot;</span>
              },
              <span style="color:#8b008b;font-weight:bold;">&quot;subnet&quot;</span>: {
                <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;[variables(&#39;subnetRef&#39;)]&quot;</span>
              }
              }
          }
        ],
       <span style="color:#8b008b;font-weight:bold;">&quot;dnsSettings&quot;</span>: {
         <span style="color:#8b008b;font-weight:bold;">&quot;dnsServers&quot;</span>: []
       },
       <span style="color:#8b008b;font-weight:bold;">&quot;enableIPForwarding&quot;</span>: <span style="color:#8b008b;font-weight:bold;">false</span>,
       <span style="color:#8b008b;font-weight:bold;">&quot;networkSecurityGroup&quot;</span>: {
               <span style="color:#8b008b;font-weight:bold;">&quot;id&quot;</span>: <span style="color:#cd5555;">&quot;[resourceId(&#39;Microsoft.Network/networkSecurityGroups&#39;, parameters(&#39;networkSecurityGroupName&#39;))]&quot;</span>
            }
      }
    }<span style="color:#a61717;background-color:#e3d2d2;">,</span>
</pre>
</div>
<p>Go to my GitHub repository to find the <a href="https://github.com/techbunny/Templates/blob/master/smallcloudlab/smalllabdeploy_nsg.json">full version of this template</a>. By default, it will deploy a Nano Server VM.</p>
<p><em><strong>Now here&#8217;s a little gotcha when it comes to NSGs and remote server management (as of this writing):</strong></em> If you created a VM from the Azure Portal and accept all the defaults (which include an NSG), that NSG doesn&#8217;t open the ports for WinRM by default.  It only opens RDP.  The OS firewall is open to accept WinRM and PowerShell, but the NSG blocks it.  You need to edit the NSG to include TCP ports 5985 (http) and/or 5986 (https) for remote management.</p>
<p>You might not notice this issue if you are connecting to full GUI servers with RDP, but if you are trying out Nano Server there is no RDP, so you must be able to connect with PowerShell.</p><br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/techbunnyblog.wordpress.com/798/"><img alt=" " border="0" src="http://feeds.wordpress.com/1.0/comments/techbunnyblog.wordpress.com/798/" /></a> <img alt=" " border="0" src="https://pixel.wp.com/b.gif?host=blog.techbunny.com&#038;blog=101098484&#038;post=798&#038;subd=techbunnyblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
    </item>
  </channel>
</rss>