When converting or replicating VMware virtual machines as Amazon instances, you can install Xen drivers on Linux guest VMs before replicating the VMs. This enables the required drivers to be in place when the Amazon instances are created, so that the Amazon instance can be started and users can access the instance.
Before You Begin
Log on to the Linux VM as a root user.
Procedure
On Linux VMs running CentOS or RHEL, perform the following steps:
-
To identify the current kernel version, run the following command:
uname -r
-
Go to the /boot folder:
cd /boot
-
Take a backup of the .img file for the kernel.
-
Open the editor to edit the dracut.conf configuration file:
vi /etc/dracut.conf
-
Uncomment the line that contains the string "add_drivers".
-
Add the xen-blkfront and xen-netfrontdriver module names to the line with spaces separating each module. (Do not include the .ko suffix in the driver module name.)
For example:
add_drivers+="xen-blkfront xen-netfront"
-
Return to the /boot folder:
cd /boot
-
Recut the initramfs:
dracut -f -v
When replicating a VM to a Nitro instance type, certain drivers must be pre-installed on the guest. For information, see Preparing the Source VM for Conversion to an Amazon EC2 Instance.