Posts Tagged ‘Software Mirroring’

Software Mirroring using ESXi: A Poor Man’s RAID

January 23rd, 2009 by Paul Sterley | 6 Comments | Filed in ESXi, Hyper-V, In the Windows Box, Virtualization, Windows Server

You’re familiar, of course with Windows software mirroring: A poor man’s RAID.

In the traditional hardware world, you added two disks, loaded Windows on one of them, added the second one as a mirror set, optionally added a line in the boot.ini with the second ARC path, and you were off to the races.

ESXi has a fairly specific list of RAID controllers that it is fully compatible with, and sometimes either you don’t have one to work with, or the one you have doesn’t work right. In such cases, if you want fault tolerance, you have to get creative about.

This, then is a creative plan:

  1. Establishing Software Mirroring in ESXi (or Hyper-V, for that matter)
  2. Add one physical disk to your server.
  3. Install ESXi on the disk.
  4. Disconnect the disk.
  5. Connect a second disk.
  6. Install ESXi on the second disk.
  7. Connect both disks and boot. Verify that ESXi can see both datastores.
  8. Create your VM, and add two virtual hard disks of identical size to it. One virtual disk should be placed in each datastore.
  9. Load Windows, and add the second virtual disk as a mirror set.

It’s quite simple, really, and it’s the same concept – the only differences are that you have to load your base OS (ESXi) twice, and that if you have a failure on your primary boot disk, you’re going to have to create your VM (using the existing virtual hard disk) on the second OS on order to boot it. That’s not such a big deal, really. A bit of a manual process, but not bad.

Fair warning: Switching back and forth between ESXi instances in this configuration had some interesting and undesirable results in the area of snapshots, and virtual disk files, so your best bet is to do this only when you have to becauseof disk failure. If you have an active snapshot when your primary disk fails, you’re going to forcibly be reverted to the snapshot. It could get very interesting. I recommend very short-lived snapshots in this scenario.

Come to think of it, I don’t really recommend this scenario – but if you’re broke/desperate, or don’t have much to lose…

Tags: , , ,