Skip to main content

Migrate Windows servers from on-premises ESX to Selectel

You can migrate Windows VMs from ESXi 7.0 to the Selectel Cloud Platform based on OpenStack.

Before migrating, the Windows server must be prepared for cloud operation: install paravirtualization drivers and the management agent, then unbind the OS from the current hardware. After that, the server disk is exported from ESXi and uploaded to the Selectel Cloud Platform as an image used to create a server.

The Windows server is turned off for the duration of the disk export.

1. Prepare the Windows server

Administrator privileges in Windows are required.

  1. Install the latest stable version of VirtIO drivers virtio-win.iso. Windows does not have built-in support for VirtIO paravirtualization; without these drivers, the OS will not boot in Selectel.

  2. Mount the ISO image using Windows tools and install all components suggested by the wizard.

  3. Install cloudbase-init. It is needed to manage the server in Selectel: change the password, apply settings from the control panel. Request the current version with Selectel-specific fixes from technical support. After installation, you can delete the distribution package from the server.

    During installation, cloudbase-init creates an additional user in the OS. Changes made in the control panel are applied through this user. You do not need to delete it.

  4. Unbind the OS from the hardware using Sysprep.

    4.1. Run C:\Windows\System32\Sysprep\sysprep.exe.

    4.2. Configure the parameters:

    • System Cleanup Action — Enter System Out-of-Box Experience (OOBE);
    • do not select the Generalize checkbox;
    • Shutdown Options — Shutdown.

    4.3. Click OK and wait for the server to shut down.

2. Configure OpenStack CLI

Configure OpenStack CLI to work with the cloud platform.

3. Transfer the disk

  1. Export the server disk VMDK files from the ESXi storage — to Selectel S3 via rclone or to an intermediate server.

  2. Upload the VMDK image to Selectel. Upload images larger than 30–40 GB via OpenStack CLI:

    openstack image create --disk-format vmdk --container-format bare \
    --file win-server-disk1.vmdk win-server-image
  3. If the server disk was on the IDE bus in ESXi, specify this in the image properties, otherwise the OS will not boot:

    openstack image set --property hw_disk_bus=ide IMAGE_ID

    The IDE bus is deprecated, and using it in the cloud platform is not recommended. If possible, convert the disk to SCSI while still in ESXi. If Windows Server 2016 with UEFI boot on a GPT disk was originally installed on an IDE bus and converting the disk to SCSI failed, leave IDE.

  4. Create a server and select the image you uploaded in step 2 as the source.

  5. If everything is done correctly, the OS will boot and open the initial setup window (OOBE). Complete the setup.