In a constantly evolving IT environment, migrating virtual machines (VMs) across platforms can be a critical need. Proxmox VE is becoming a popular choice due to its flexibility and robustness. Here’s how to perform the migration from VMware ESXi to Proxmox VE using two methods: one manual and one automated with specific tools.
Preparations Before Migration
Before starting, it is essential to take certain precautions to ensure a smooth transition:
- Network Configuration: Record the current network configuration of the source VM and enable DHCP to prevent IP address conflicts on the target VM.
- Network Connection: Ensure that there is a connection between the VMware ESXi and Proxmox hosts.
- Disable Encryption: Deactivate disk encryption and any TPM modules on the original VM to prevent errors during migration.
- VM Status: Ensure that the VM is powered off before starting the migration.
The example environment used includes:
- VMware ESXi: IP Address 192.168.101.31
- Proxmox VE: IP Address 192.168.101.226
Method 1: Manual Migration
This method involves creating a new VM in Proxmox with settings identical to those of the original VM in VMware ESXi and manually transferring the virtual disks.
Main Steps
- Configure SSH Access in ESXi:
- Enable the SSH service on ESXi from the VMware Host client.
- This is necessary to copy data using SCP.
- Create a New VM in Proxmox:
- In the Proxmox interface, configure the new VM with the same CPU, memory, disk, and network adapter parameters as the source VM.
- Select BIOS or UEFI depending on the firmware type of the original VM.
- Copy Virtual Disks:
- Use SCP to transfer the
.vmdk
and-flat.vmdk
files from the ESXi host to the VM directory in Proxmox. - Example command:
scp [email protected]:/vmfs/volumes/datastore50/WinServer2022/WinServer2022.vmdk /mnt/datastore/datastore55/images/101/
- Use SCP to transfer the
- Convert Disks:
- Use
qemu-img
to convert the disks to Proxmox’s native format (qcow2):qemu-img convert -O qcow2 WinServer2022.vmdk WinServer2022.qcow2
- Use
- Attach the Converted Disk:
- In the Proxmox interface, add the disk as unused to the VM and configure it as the primary boot device.
- Start the Migrated VM:
- Verify that the VM starts correctly. If not, check the virtual disk controller and boot configurations.
- Post-Migration Optimization:
- Install VirtIO drivers and guest tools to improve the VM’s performance in Proxmox.
Method 2: Using Specific Tools
Proxmox introduced the pve-esxi-import-tools
package in 2024, which simplifies migration by providing an assistant in the web interface.
Main Steps
- Update Proxmox:
- Ensure that your system is up to date and that the testing and non-subscription repositories are enabled.
- Install the tools package with:
dpkg -l | grep pve-esxi-import-tools
- Add Remote Storage:
- In the Proxmox interface, add the ESXi host as remote storage. This allows direct access to the source VMs.
- Import the VM:
- Select the
.vmx
file of the source VM from the remote storage in Proxmox and click “Import.” - Proxmox will automatically convert the disks to its native format (qcow2) and replicate the hardware configuration.
- Select the
- Configure the Imported VM:
- Make final adjustments, such as assigning VirtIO drivers, and ensure that the network configurations match those of the original VM.
Final Recommendations
Once the migration is complete, back up the migrated VMs in Proxmox to ensure data protection. Tools like NAKIVO BackupA backup is a copy of data that is created and stored… & Replication are ideal for managing backups in both VMware ESXi and Proxmox.
VM migration may seem complex, but with these methods, organizations can ensure an efficient and reliable transition to Proxmox VE, leveraging its advantages in flexibility and performance.
via: Nakivo