Best practices for server configuration generally suggest installing applications / app data to a separate disk and volume than the OS. However, when you deploy a Windows 2008 or 2012 VM from a VM template in System Center 2012 R2 Virtual Machine Manager (VMM), you may find the second disk (vhd or vhdx) containing the application partition in an offline or uninitialized state when the VM is deployed from the template. The error you will see is “the disk is offline because of policy set by an administrator”.
Root Cause and Fix
This issue is caused by the default SAN Policy setting in Windows 2008 and Windows 2012. SAN policy was introduced in Windows Server 2008 to protect shared disks being accessed by multiple servers. If (and only if) the disk is not shared amongst other servers, you can change the SAN Policy setting to OnlineAll setting to get around this.
Perform these steps before running sysprep to create the VM template for VMM will ensure all the disks in a multi-disk VM template are in an online state on first boot.
To verify the current SAN Policy setting
From a command prompt, type DISKPART.EXE and then press Enter.
DISKPART> san and then press Enter.
If the default is in place, this command will return a status of “Offline Shared”
To change SAN Policy to OnlineAll, type the following at the DISPART prompt:
san policy=OnlineAll and then press Enter.
Now you can sysprep your VM to make your template with the assurance that non-OS disks in your template will be online on first boot.