<?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>Maintenance on Mark Allison</title>
    <link>https://markallison.co.uk/tags/maintenance/</link>
    <description>Recent content in Maintenance 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>Sun, 19 Mar 2023 09:20:12 +0000</lastBuildDate>
    <atom:link href="https://markallison.co.uk/tags/maintenance/index.xml" rel="self" type="application/rss+xml" />
    <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>Clear Msdb Backup History Safely</title>
      <link>https://markallison.co.uk/blog/clear-msdb-backup-history/</link>
      <pubDate>Fri, 10 Jun 2022 06:46:13 +0100</pubDate>
      <guid>https://markallison.co.uk/blog/clear-msdb-backup-history/</guid>
      <description>&lt;p&gt;I came across a situation this week where the &lt;strong&gt;msdb&lt;/strong&gt; database had grown to a large amount (130 GB). This is the largest I&amp;rsquo;ve ever seen msdb and is a result of no scheduled maintenance of the backup history for several years.&lt;/p&gt;
&lt;h2 id=&#34;msdbdbosp_delete_backuphistory&#34;&gt;msdb.dbo.sp_delete_backuphistory&lt;/h2&gt;
&lt;p&gt;Why not just run &lt;code&gt;msdb.dbo.sp_delete_backuphistory&lt;/code&gt; I hear you say?&lt;/p&gt;
&lt;p&gt;Well, when the history tables have over 100 million rows each and the database files are on the C drive, running this proc will require huge amounts of transaction log space. Each delete statement will be cleaning out millions of rows per table in a single transaction.&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>⚠ 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>
  </channel>
</rss>
