John Liu Blog

Every drop counts

Run container in Azure VM

We can run container (using Docker Desktop) inside Azure VM. Following are some considerations for the setup. Not all Azure VM support container. D4_v5 and above VM support nested virtulization. When creating the Zure VM, ensure the security type on the Basic tab is set to “Standard”, not “Trusted Launch”. Trusted Launch does not support Nested Virtualization. Azure Portal default to Trusted Launch. After VM is created, turn Windows featur “Windows Hypervisor Platform” on.

SQL Server on Azure VM

Some considerations when configure SQL Server on Azure VM. This also applicable to AWS VM For storage: - Separate volume for data and log file - Enable read caching on data file volume - Disable any caching on log file volume - Use D: drive (local SSD that will be cleared each time with server reboot) for TempDB - Enable instant file initialization - Move trace file and error log directories to data volume To evaluate disk performance when migrate from on-premises to cloud, capture following counters in Performance Monitor:

Availability % and downtime mapping

When people talking about system availability, it reflects to an agreed downtime. The mapping is as following: Availability % Downtime per year 99% 3.65 days 99.5% 1.83 days 99.9% 8.77 hours 99.95% 4.38 hours 99.99% 52.60 minutes 99.995% 26.30 minutes 99.999% 5.26 minutes (Table source: https://docs.microsoft.com/en-us/learn/modules/deploy-sql-server-virtual-machine/2-explain-iaas-options-deploying-azure) For solution involves mulitple system with different availabilities, the maximum availability of the overall solution is the smallest availability. However, you can utilise Availability Zones to increase overall availability.

SQL Server on Azure config best practice

Each Azure VM has a OS disk (C drive) and a temporary disk (D drive). Only store on the temporary disk temp data that doesn’t need to be retained as all data on this disk will be lost after server reboot. The best practice for SQL Server on Azure VM is to use Premium Disks pooled for increased IOPs and storage capacity. Data file should be on its own pool with read-caching on the Azure disk.