<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Azure on Mark Allison</title>
    <link>https://markallison.co.uk/tags/azure/</link>
    <description>Recent content in Azure on Mark Allison</description>
    <image>
      <title>Mark Allison</title>
      <url>https://markallison.co.uk/%3Clink%20or%20path%20of%20image%20for%20opengraph,%20twitter-cards%3E</url>
      <link>https://markallison.co.uk/%3Clink%20or%20path%20of%20image%20for%20opengraph,%20twitter-cards%3E</link>
    </image>
    <generator>Hugo -- 0.151.2</generator>
    <language>en</language>
    <lastBuildDate>Mon, 16 Sep 2024 07:27:43 +0100</lastBuildDate>
    <atom:link href="https://markallison.co.uk/tags/azure/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Connect Logic App to  Azure Sql Securely</title>
      <link>https://markallison.co.uk/blog/logicapp-connect-azuresql/</link>
      <pubDate>Mon, 16 Sep 2024 07:27:43 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/logicapp-connect-azuresql/</guid>
      <description>&lt;h1 id=&#34;the-problem&#34;&gt;The Problem&lt;/h1&gt;
&lt;p&gt;Recently, I was working on a &lt;a href=&#34;https://ppgstats.markallison.co.uk/&#34;&gt;personal project&lt;/a&gt; where I needed to export data from my Azure SQL Database into a JSON file roughly every hour. This JSON file would then be used by a static website hosted on Azure Blob Storage. I wanted a secure way to do this without maintaining passwords, so I decided to use &lt;strong&gt;Managed Identity&lt;/strong&gt; to connect my Logic App to the Azure SQL Database.&lt;/p&gt;</description>
    </item>
    <item>
      <title>SQLMI Restore Blob Storage Access Denied</title>
      <link>https://markallison.co.uk/blog/sqlmi-restore-blob-storage-access-denied/</link>
      <pubDate>Tue, 08 Aug 2023 11:24:22 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/sqlmi-restore-blob-storage-access-denied/</guid>
      <description>&lt;p&gt;If you are using Azure SQL Managed Instance and encounter an error like this when restoring a database from an Azure Blob Storage container:&lt;/p&gt;
&lt;div class=&#34;admonition admonition-failure&#34;&gt;
  &lt;p class=&#34;admonition-title&#34;&gt;
      Msg 3201, Level 16, State 2, Line 1 
  &lt;/p&gt;
  &lt;div class=&#34;admonition-content&#34;&gt;
    
Cannot open backup device &#39;https://{storage-account}.blob.core.windows.net/my-container/mydb/FULL/mydb-backup.bak&#39;. Operating system error 5(Access is denied.).

  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;You can try the following steps to fix it:&lt;/p&gt;
&lt;h2 id=&#34;1-check-the-sas-token-and-generate-a-new-one-if-needed&#34;&gt;1. Check the SAS token and generate a new one if needed.&lt;/h2&gt;
&lt;p&gt;The most common cause of this error is that the SAS token used to access the Azure Blob Storage container has expired or is invalid. A SAS token is a shared access signature that grants limited access to a resource in Azure. You can generate a SAS token for your Azure Blob Storage container using the Azure portal, PowerShell, CLI, or SDK.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Which ADF Integration Runtime for my workload?</title>
      <link>https://markallison.co.uk/blog/which-adf-runtime/</link>
      <pubDate>Wed, 29 Mar 2023 08:26:42 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/which-adf-runtime/</guid>
      <description>&lt;h2 id=&#34;self-hosted-or-managed-virtual-network-for-adf&#34;&gt;Self Hosted or Managed Virtual Network for ADF?&lt;/h2&gt;
&lt;p&gt;I was recently asked which runtime would be better to run ADF pipelines in Azure; use Private Managed Endpoints with the Managed Virtual Network, or provision a Self-Hosted Integration Runtime on a Virtual Machine?&lt;/p&gt;
&lt;h3 id=&#34;paas-vs-iaas&#34;&gt;PaaS vs. IaaS&lt;/h3&gt;
&lt;p&gt;My default position on which technology to use is PaaS &lt;em&gt;where possible&lt;/em&gt;. Organisations should focus on providing value to their business, not micro-managing infrastructure. PaaS reduces the operational burden of managing infrastructure in most cases.&lt;/p&gt;</description>
    </item>
    <item>
      <title>How to Move a VM to Another Vnet in Azure</title>
      <link>https://markallison.co.uk/blog/move-vm-to-another-vnet/</link>
      <pubDate>Sun, 19 Mar 2023 09:20:12 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/move-vm-to-another-vnet/</guid>
      <description>&lt;p&gt;Hello everyone,&lt;/p&gt;
&lt;p&gt;In this blog post, I want to share with you a problem that I faced this week with moving a VM from one vnet to another in Azure. It was not as easy as I expected and it required some downtime.&lt;/p&gt;
&lt;h2 id=&#34;the-problem&#34;&gt;The problem&lt;/h2&gt;
&lt;p&gt;I had a VM that needed to move to another vnet as part of organisational change.&lt;/p&gt;
&lt;p&gt;I thought it would be a simple task of creating a new network interface card (NIC) in the target vnet and attaching it to the VM. However, it seems that it&amp;rsquo;s not possible to create a NIC in another Vnet and attach it to a VM attached to a different vnet. Also, as you may know a VM must have at least one NIC attached at all times which must be connected to a vnet.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Importance of Testing Your Azure Backups</title>
      <link>https://markallison.co.uk/blog/vm-restore-failure/</link>
      <pubDate>Tue, 28 Feb 2023 10:37:04 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/vm-restore-failure/</guid>
      <description>&lt;h2 id=&#34;my-recent-experience&#34;&gt;My recent experience&lt;/h2&gt;
&lt;p&gt;Disaster recovery testing is a critical aspect of any organization&amp;rsquo;s infrastructure. It is crucial to regularly test the resilience of your systems and make sure that they are properly backed up and can be restored in case of an emergency. Recently, a VM that had been restored as part of disaster recovery testing would not start but entered an infinite blue-screen boot loop.&lt;/p&gt;
&lt;figure&gt;
    &lt;img src=&#34;2023-02-10_10-30-17.jpg&#34; alt=&#34;&#34; /&gt;
    
      &lt;figcaption&gt;Blue screen loop&lt;/figcaption&gt;
    
&lt;/figure&gt;
  
&lt;h2 id=&#34;testing-backups&#34;&gt;Testing Backups&lt;/h2&gt;
&lt;p&gt;As part of disaster recovery resilience testing, I restored a virtual machine from &lt;strong&gt;Azure Recovery Services Vault&lt;/strong&gt;. The first test was done using the latest snapshot backup, and it took around two minutes to complete. However, when I checked the overview page for the virtual machine in the Azure portal, I noticed that the virtual machine agent status was not ready. This meant that I couldn&amp;rsquo;t connect to the VM, not even from within the virtual network.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Troubleshooting Get-AzVirtualNetwork</title>
      <link>https://markallison.co.uk/blog/get-azvirtualnetwork-error/</link>
      <pubDate>Mon, 16 Jan 2023 12:15:23 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/get-azvirtualnetwork-error/</guid>
      <description>&lt;p&gt;Are you encountering the following error message when working with Azure in PowerShell and running the command Get-AzVirtualNetwork?&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code class=&#34;language-Get-AzVirtualNetwork:&#34; data-lang=&#34;Get-AzVirtualNetwork:&#34;&gt;&amp;#39;Microsoft.Azure.Management.Network.Models.SecurityRule&amp;#39;, 
on &amp;#39;T MaxInteger[T](System.Collections.Generic.IEnumerable`1[T])&amp;#39; 
violates the constraint of type &amp;#39;T&amp;#39;.
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This error can be caused by an incompatibility between PowerShell 7 and the &lt;code&gt;Az&lt;/code&gt; Module and &lt;a href=&#34;https://github.com/Azure/azure-powershell/issues/18721&#34;&gt;incompatibilty with .NET 7&lt;/a&gt;. To fix this issue, try the following steps:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Upgrade to the latest versions of PowerShell 7 and the Az module.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;If the issue persists, remove all versions of the Az Module on your system by using the command &lt;code&gt;Uninstall-Module Az -AllVersions&lt;/code&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Sql Virtual Machine Race Conclusion</title>
      <link>https://markallison.co.uk/blog/sqliaas-race-conclusion/</link>
      <pubDate>Thu, 30 Jun 2022 16:28:59 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/sqliaas-race-conclusion/</guid>
      <description>&lt;p&gt;A couple of months ago &lt;a href=&#34;https://markallison.co.uk/blog/sqliaas-problem/&#34;&gt;I wrote about&lt;/a&gt; a race condition in a &lt;a href=&#34;https://docs.microsoft.com/en-us/azure/azure-sql/virtual-machines/?view=azuresql&#34;&gt;SQL IaaS VM&lt;/a&gt; using the Azure sqlvm resource. I have been working with Microsoft and have come to a better resolution than placing tempdb on a separate remote drive as mentioned in that article.&lt;/p&gt;
&lt;h2 id=&#34;suggestion&#34;&gt;Suggestion&lt;/h2&gt;
&lt;p&gt;Microsoft suggested to change the startup type of the SQL Server service to Automatic (Delayed Start). I have now put this into the bicep template for both SQL Server and SQL Server Agent service.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Sql Virtual Machine Race Condition</title>
      <link>https://markallison.co.uk/blog/sqliaas-problem/</link>
      <pubDate>Tue, 12 Apr 2022 07:54:52 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/sqliaas-problem/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been having problems deploying a Sql Virtual Machine in Azure lately and decided to perform some tests to get to the bottom of the issue. I&amp;rsquo;d like to share some strange behaviour.&lt;/p&gt;
&lt;h2 id=&#34;problem&#34;&gt;Problem&lt;/h2&gt;
&lt;p&gt;If I deploy a new SQL VM using bicep, it deploys fine. If however, I redeploy the same VM the deployment fails with this error:&lt;/p&gt;
&lt;div class=&#34;admonition admonition-failure&#34;&gt;
  &lt;p class=&#34;admonition-title&#34;&gt;
      Ext_AutomatedBackupError 
  &lt;/p&gt;
  &lt;div class=&#34;admonition-content&#34;&gt;
    
* code: **Ext_AutomatedBackupError**
* Error: **Execution Timeout Expired**.  The timeout period elapsed prior to completion of the operation or the server is not responding.;System.Data.SqlClient.SqlException (0x80131904): Execution Timeout Expired.  The timeout period elapsed prior to completion of the operation or the server is not responding. ---&gt; System.ComponentModel.Win32Exception (0x80004005): The wait operation timed out.

  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;In the SQL Server ERRORLOG on the VM:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Where to store Azure Pipelines Variables?</title>
      <link>https://markallison.co.uk/blog/azure-pipelines-variables/</link>
      <pubDate>Fri, 04 Mar 2022 07:30:29 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/azure-pipelines-variables/</guid>
      <description>&lt;h2 id=&#34;question&#34;&gt;Question&lt;/h2&gt;
&lt;p&gt;Where should variables be stored for deploying &lt;em&gt;infrastructure-as-code&lt;/em&gt; in Azure DevOps pipelines to Azure? Resources need to be deployed to different regions and environments, and attributes for these need to be stored somewhere.&lt;/p&gt;
&lt;h2 id=&#34;options&#34;&gt;Options&lt;/h2&gt;
&lt;p&gt;Six options spring to mind.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;https://docs.microsoft.com/en-us/azure/azure-resource-manager/templates/parameter-files&#34;&gt;Parameter files&lt;/a&gt;&lt;/strong&gt;. Seems like the obvious choice.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;https://docs.microsoft.com/en-us/azure/azure-resource-manager/templates/parameters#default-value&#34;&gt;Template file defaults&lt;/a&gt;&lt;/strong&gt; in &lt;code&gt;azuredeploy.json&lt;/code&gt; or &lt;code&gt;main.bicep&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;https://docs.microsoft.com/en-us/azure/devops/pipelines/library/variable-groups?view=azure-devops&amp;amp;tabs=yaml&#34;&gt;Azure DevOps Library&lt;/a&gt;&lt;/strong&gt; variable groups. Seems good, a single place&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;https://docs.microsoft.com/en-us/azure/devops/pipelines/process/variables?view=azure-devops&amp;amp;tabs=yaml%2Cbatch&#34;&gt;Azure Pipelines variables&lt;/a&gt;&lt;/strong&gt; in individual pipelines&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;https://docs.microsoft.com/en-us/azure/azure-resource-manager/bicep/bicep-functions-files#loadtextcontent&#34;&gt;Configuration file&lt;/a&gt;&lt;/strong&gt; within the project source code&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&#34;https://docs.microsoft.com/en-us/azure/devops/pipelines/process/runtime-parameters?view=azure-devops&amp;amp;tabs=script&#34;&gt;Runtime parameters&lt;/a&gt;&lt;/strong&gt; for setting values at run time&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Let&amp;rsquo;s go through each option and then discuss my preferred approach.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Automate Setting the SqlIaaS Backup Container</title>
      <link>https://markallison.co.uk/blog/sqliaas-backup-container/</link>
      <pubDate>Fri, 25 Feb 2022 12:36:08 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/sqliaas-backup-container/</guid>
      <description>&lt;p&gt;Even though Microsoft offer Azure Sql Database and Azure Sql Managed Instance, there are occasions when SQL Server in a VM is required.&lt;/p&gt;
&lt;h2 id=&#34;the-sqliaas-azure-resource&#34;&gt;The SqlIaaS Azure Resource&lt;/h2&gt;
&lt;p&gt;If you&amp;rsquo;ve read my posts before you will know that I deploy resources to the cloud using infrastructure-as-code, with my preferred language being bicep. As a lazy developer, I like to use built-in offerings and PaaS wherever possible. For SQL server on VMs in Azure, the resource &lt;code&gt;Microsoft.SqlVirtualMachine/sqlVirtualMachines&lt;/code&gt; is great.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Run DBCC CHECKDB?</title>
      <link>https://markallison.co.uk/blog/sqlmi-checkdb/</link>
      <pubDate>Wed, 16 Feb 2022 09:20:58 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/sqlmi-checkdb/</guid>
      <description>&lt;p&gt;As a standard practise for IaaS and on-premises SQL Servers, I usually like to install &lt;a href=&#34;https://ola.hallengren.com/sql-server-integrity-check.html&#34;&gt;Ola Hallengren&amp;rsquo;s maintenance scripts&lt;/a&gt;. Why invent the wheel when we already have a super-shiny one? These scripts include integrity checks, which run DBCC CHECKDB.&lt;/p&gt;
&lt;h2 id=&#34;is-dbcc-checkdb-needed-anymore&#34;&gt;Is DBCC CHECKDB needed anymore?&lt;/h2&gt;
&lt;p&gt;It depends. 😉&lt;/p&gt;
&lt;p&gt;It comes down to a cost/benefit analysis.&lt;/p&gt;
&lt;p&gt;I have been working with Sql Managed Instances quite closely over the past couple of years and wondered whether DBCC CHECKDB needs to be run on these. The whole point of CHECKDB is to notify us that something is wrong but also to &lt;em&gt;do something&lt;/em&gt; if the database becomes corrupt in some way. They are very IO intensive operations which can impact user queries on the server.&lt;/p&gt;</description>
    </item>
    <item>
      <title>What-If In Production</title>
      <link>https://markallison.co.uk/blog/powershell-what-if/</link>
      <pubDate>Wed, 26 Jan 2022 09:59:06 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/powershell-what-if/</guid>
      <description>&lt;p&gt;What if you could do a dry run of your PowerShell script when making a change to your production environment?&lt;/p&gt;
&lt;p&gt;If you&amp;rsquo;ve read my other posts, you will know I am a big advocate of &lt;em&gt;infrastructure-as-code&lt;/em&gt;. Most of my work is done in the Microsoft Azure cloud, and although I encourage source controlling all assets within Azure, sometimes developers create things manually through the portal.&lt;/p&gt;
&lt;p&gt;Yes, I know! 🙄&lt;/p&gt;
&lt;h2 id=&#34;removing-azure-resources-safely&#34;&gt;Removing Azure Resources safely&lt;/h2&gt;
&lt;p&gt;A scheduled drift report should alert developers or DevOps engineers that the production state is out-of-sync with the source controlled code. If this happens, and some resources need removing, then the &lt;code&gt;-WhatIf&lt;/code&gt; switch comes in handy and provides confidence to remove items in production that shouldn&amp;rsquo;t be there.&lt;/p&gt;</description>
    </item>
    <item>
      <title>ADF HTTP/3 Issue</title>
      <link>https://markallison.co.uk/blog/adf-https3-issue/</link>
      <pubDate>Tue, 30 Nov 2021 07:44:13 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/adf-https3-issue/</guid>
      <description>&lt;p&gt;One of my ADF pipelines started failing recently where a Generic REST API Linked Service gave the following error:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;525: SSL handshake failed&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Digging deeper into the logs, I see a message from Cloudflare.&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;It appears that the SSL configuration used is not compatible with Cloudflare. This could happen for a several reasons, including no shared cipher suites.
&lt;/code&gt;&lt;/pre&gt;&lt;h2 id=&#34;http3-quic&#34;&gt;HTTP/3 QUIC&lt;/h2&gt;
&lt;p&gt;There had been no code changes in ADF, but something on the source side had changed. After working with the data provider, it turns out that Cloudflare was using HTTP/3 which causes the ADF connection to fail.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Grant User JIT Access</title>
      <link>https://markallison.co.uk/blog/grant-user-jit/</link>
      <pubDate>Mon, 27 Sep 2021 10:28:47 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/grant-user-jit/</guid>
      <description>&lt;p&gt;An issue came up this week where some external consultants needed access to remote onto an Azure Windows VM to configure a third-party application. The consultants were given AAD logins and are working from home with dynamic IP addresses.&lt;/p&gt;
&lt;p&gt;What is the best way to grant them access to RDP onto the VM?&lt;/p&gt;
&lt;p&gt;The preferred method would be via a private endpoint into the VNet via point-to-site VPN or Bastion, but external consultants can&amp;rsquo;t be granted access that way.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Connect to SQLMI with Managed Identity</title>
      <link>https://markallison.co.uk/blog/connect-mi-with-managedidentity/</link>
      <pubDate>Wed, 11 Aug 2021 15:42:06 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/connect-mi-with-managedidentity/</guid>
      <description>&lt;p&gt;Consider the scenario where some PowerShell scripts need to be scheduled on an Azure virtual machine, which connects to an Azure SQL Managed Instance.&lt;/p&gt;
&lt;p&gt;The PowerShell script needs to run on a schedule and must be able to connect to the managed instance securely. You would rather not have to manage passwords.&lt;/p&gt;
&lt;p&gt;What&amp;rsquo;s the best way to do this? You guessed it, &lt;strong&gt;Managed Identity&lt;/strong&gt;. This post will describe two ways of doing it, one using Azure AD with a Managed Identity and one using SQL Authentication and Azure Key Vault using a &lt;strong&gt;Service Principal&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>SQL Managed Instance Server Audit Fails</title>
      <link>https://markallison.co.uk/blog/mi-server-audit-fails/</link>
      <pubDate>Thu, 05 Aug 2021 08:56:42 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/mi-server-audit-fails/</guid>
      <description>&lt;p&gt;I have set up server auditing for some managed instances in the same virtual cluster to record login success and failed events and write them to blob storage.&lt;/p&gt;
&lt;p&gt;Downstream, an ADF pipeline reads the events asynchronously and inserts them into a database for further analysis and reporting.&lt;/p&gt;
&lt;h2 id=&#34;server-audit-stops-writing&#34;&gt;Server audit stops writing&lt;/h2&gt;
&lt;p&gt;Recently the server audit stopped writing to blob storage, even though the server audit status was still running and enabled. I have seen failures before where the server audit failed because of an expiring SAS token, but in this case the SAS token has a long expiry date, so know it&amp;rsquo;s not that.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Bicep Resource Not Found</title>
      <link>https://markallison.co.uk/blog/bicep-resource-not-found/</link>
      <pubDate>Thu, 22 Jul 2021 10:02:11 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/bicep-resource-not-found/</guid>
      <description>&lt;h2 id=&#34;bicep-stopped-deploying-with-this-error&#34;&gt;Bicep stopped deploying with this error&lt;/h2&gt;
&lt;p&gt;I&amp;rsquo;m trying to deploy a resource group which has two storage accounts in it with this PowerShell command using a bicep template:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-PowerShell&#34; data-lang=&#34;PowerShell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nb&#34;&gt;New-AzResourceGroupDeployment&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;-ResourceGroupName&lt;/span&gt; &lt;span class=&#34;nv&#34;&gt;$resourcegroupName&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;-TemplateFile&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;.\&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;azuredeploy&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;py&#34;&gt;bicep&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;-TemplateParameterFile&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;.\&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;azuredeploy&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;py&#34;&gt;test&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;py&#34;&gt;parameters&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;py&#34;&gt;json&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class=&#34;admonition admonition-failure&#34;&gt;
  &lt;p class=&#34;admonition-title&#34;&gt;
      Error 
  &lt;/p&gt;
  &lt;div class=&#34;admonition-content&#34;&gt;
    
New-AzResourceGroupDeployment: Cannot retrieve the dynamic parameters for the cmdlet. Build succeeded: 0 Warning(s), 0 Error(s)

  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;I haven&amp;rsquo;t made any code changes, just not deployed this resource for a while. I decided to update bicep to the latest version (at the time of writing is Bicep CLI version 0.4.412 (f1169d063e)).&lt;/p&gt;</description>
    </item>
    <item>
      <title>Minimum data file size on MI is 128 GB!</title>
      <link>https://markallison.co.uk/blog/mi-exceeds-storage-account-size/</link>
      <pubDate>Mon, 10 May 2021 17:15:11 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/mi-exceeds-storage-account-size/</guid>
      <description>&lt;h2 id=&#34;storage-underlying-a-managed-instance&#34;&gt;Storage underlying a Managed Instance&lt;/h2&gt;
&lt;p&gt;Microsoft Azure should not require you to have deep understanding of the underlying technologies used to provide the service, after all the whole point of PaaS is to abstract you away from implementation details. One of these details is storage of data files in the file system.&lt;/p&gt;
&lt;p&gt;When provisioning a General Tier Sql Managed Instance, the maximum storage size for the instance is capped at 8 TB. However this is not the whole story and it&amp;rsquo;s important to understand some of what is happening under the covers, especially if you are migrating an on-premises SQL Server instance to the cloud that contains a lot of databases or uses partitioning.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Deployments with Bicep and Azure DevOps</title>
      <link>https://markallison.co.uk/blog/deploy-bicep-with-azure-devops/</link>
      <pubDate>Sun, 11 Apr 2021 21:08:20 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/deploy-bicep-with-azure-devops/</guid>
      <description>&lt;h2 id=&#34;goodbye-json&#34;&gt;Goodbye JSON&lt;/h2&gt;
&lt;p&gt;Since Microsoft released &lt;a href=&#34;https://github.com/Azure/bicep&#34;&gt;bicep version 0.3&lt;/a&gt; I thought I&amp;rsquo;d give it a try because anyone that&amp;rsquo;s authored ARM templates will know, they tend to make your eyes bleed after a while.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Bicep aims to drastically simplify the authoring experience with a cleaner syntax, improved type safety, and better support for modularity and code re-use.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I&amp;rsquo;m sold!&lt;/p&gt;
&lt;p&gt;I reverse-engineered an existing simple template that deploys two storage accounts by using &lt;code&gt;bicep decompile&lt;/code&gt; and got a template like this:&lt;/p&gt;</description>
    </item>
    <item>
      <title>⚠ Careful with Maintenance Window</title>
      <link>https://markallison.co.uk/blog/managedinstance-maintenancewindow/</link>
      <pubDate>Fri, 19 Mar 2021 13:41:54 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/managedinstance-maintenancewindow/</guid>
      <description>&lt;h2 id=&#34;maintenance-window-now-in-preview&#34;&gt;Maintenance Window now in Preview&lt;/h2&gt;
&lt;p&gt;(at the time of writing)&lt;/p&gt;
&lt;p&gt;On 2nd March 2021, &lt;a href=&#34;https://techcommunity.microsoft.com/t5/azure-sql/maintenance-window-for-azure-sql-database-and-managed-instance/ba-p/2174835&#34;&gt;Microsoft announced&lt;/a&gt; a long-awaited feature, at least by me, to give choice over when OS and SQL patching occurs behind-the-scenes in Azure SQL Managed Instance. Before this feature, Microsoft would patch the Virtual Cluster supporting Managed Instances outside of regular business hours in the region your Managed Instance is located.&lt;/p&gt;
&lt;p&gt;You now get &lt;strong&gt;two&lt;/strong&gt; additional options:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Weekday window, 10PM to 6AM local time Monday – Thursday&lt;/li&gt;
&lt;li&gt;Weekend window, 10PM to 6AM local time Friday - Sunday&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;System default:&lt;/p&gt;</description>
    </item>
    <item>
      <title>EXECUTE denied on Managed Instance</title>
      <link>https://markallison.co.uk/blog/regread-failure-on-mi/</link>
      <pubDate>Wed, 17 Mar 2021 12:20:04 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/regread-failure-on-mi/</guid>
      <description>&lt;h2 id=&#34;the-problem&#34;&gt;The problem&lt;/h2&gt;
&lt;p&gt;I came across an interesting (!) issue with an Azure Sql Managed Instance today. One of our users came across this error when trying to &lt;code&gt;SELECT&lt;/code&gt; from a view in a database where they are not a member of the &lt;code&gt;db_owner&lt;/code&gt; database role or any elevated server-level permission by right clicking the view in SSMS 18.8 and choosing &lt;strong&gt;Select Top 1000 Rows&lt;/strong&gt;.&lt;/p&gt;
&lt;figure&gt;
    &lt;img src=&#34;2021-03-17_11-40-04.png&#34; alt=&#34;&#34; /&gt;
    
      &lt;figcaption&gt;Select Top 1000 Rows in SSMS&lt;/figcaption&gt;
    
&lt;/figure&gt;
  
&lt;figure&gt;
    &lt;img src=&#34;2021-03-17_11-40-44.png&#34; alt=&#34;&#34; /&gt;
    
      &lt;figcaption&gt;EXECUTE denied on xp_instance_reg_read in mssqlsystemresource&lt;/figcaption&gt;
    
&lt;/figure&gt;
  
&lt;p&gt;The full text of the error is &lt;code&gt;The EXECUTE permission was denied on the object &#39;xp_instance_regread&#39;, database &#39;mssqlsystemresource&#39;, schema &#39;sys&#39;.&lt;/code&gt;
I verified that this was indeed the case with:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Az.Sql Module won&#39;t load</title>
      <link>https://markallison.co.uk/blog/az-sql-module/</link>
      <pubDate>Tue, 16 Mar 2021 18:17:22 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/az-sql-module/</guid>
      <description>&lt;p&gt;Today, the &lt;code&gt;Az.Sql&lt;/code&gt; module would not load on my machine when attempting to manually fail over a SQL Managed Instance with this error:&lt;/p&gt;
&lt;figure&gt;
    &lt;img src=&#34;2021-03-16_18-19-15.png&#34; alt=&#34;&#34; /&gt;
    
      &lt;figcaption&gt;module could not be loaded&lt;/figcaption&gt;
    
&lt;/figure&gt;
  
&lt;p&gt;I followed the advice of the error message and tried to import the module to get further information.&lt;/p&gt;
&lt;figure&gt;
    &lt;img src=&#34;2021-03-16_18-19-54.png&#34; alt=&#34;&#34; /&gt;
    
      &lt;figcaption&gt;module is already loaded&lt;/figcaption&gt;
    
&lt;/figure&gt;
  
&lt;p&gt;Hmmm :thinking:&lt;/p&gt;
&lt;p&gt;I decided to uninstall the Azure PowerShell from my machine using the Windows 10 Settings App. Looks like an old version.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Running Sql Server in an Azure Container Instance</title>
      <link>https://markallison.co.uk/blog/running-sql-server-in-an-azure-container-instance/</link>
      <pubDate>Tue, 24 Oct 2017 15:50:31 +0000</pubDate>
      <guid>https://markallison.co.uk/blog/running-sql-server-in-an-azure-container-instance/</guid>
      <description>&lt;p&gt;Azure Container Instances are still in Preview and not officially available for Windows yet, which made me smile. It took me a while to figure out how to get this working so I thought I’d share what I’ve found. Containers are great for lightweight testing of code before deployment to production servers because they can be created so quickly and they give the same environment to test in very reliably. Now that Microsoft is offering container instances in Azure it means you don’t have to worry about provisioning and configuring your own docker host/cluster. The options for deploying SQL Server are really getting large now, look at this list below!&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
