Preparing Linux VMs

Linux VMs migrated to GCP with Migrate for Compute Engine need a prep package installed to automatically handle configuration changes.

This page describes how to install the Migrate for Compute Engine prep package on VMs you intend to run on GCP.

This package makes changes at boot after detecting that the VM is running on GCP. It can remain installed while the VM is running on-premises. For more information on the changes made by the package, see VM adaptations.

RHEL / CentOS

Use the following steps to prepare Red Hat Enterprise Linux (RHEL) 6/7 and CentOS 6/7.

You can install the Migrate for Compute Engine RPM package in two ways:

  1. Install the velostrata-prep package using Yum. This automatically fetches and installs the required prerequisites.
  2. Download and install the prerequisites, and then install the velostrata-prep RPM package.

Installing using Yum

  1. Sign in to the workload VM.
  2. From the VM, download the latest velostrata-prep RPM package.
  3. Install the prep package using yum:

    yum install velostrata-prep-<var>VERSION</var>.redhat.x86_64.rpm
    

Downloading and installing prerequisites

  1. Log in to the workload VM.
  2. From the VM, download the latest velostrata-prep RPM package.
  3. Check for the list of prerequisites by running:

    rpm -qpR velostrata-prep-<var>VERSION</var>.redhat.x86_64.rpm
    

    For example:

    rpm -qpR velostrata-prep-1.8-12.redhat.x86_64.rpm
    
  4. Install the prerequisites individually.

  5. Install the velostrata-prep RPM package using Yum.

    yum install velostrata-prep-<var>VERSION</var>.redhat.x86_64.rpm
    

If the installation is unsuccessful or if there are any warnings, ensure that you address them prior to executing the run-in-cloud operation.

SuSE SLES

Use the following steps to prepare SuSE Enterprise Linux Server (SLES) 11/12 for running in GCP.

  1. Log in to the SLES virtual machine as the root user.
  2. Install the SLES xen-kmp-default package:

    zypper install xen-kmp-default
    
  3. Reboot.

  4. Install the velostrata-prep package using a command such as the following.

    zypper install velostrata-prep-<var>VERSION</var>.suse.x86_64.rpm
    

    For example:

    zypper install velostrata-prep-1.8-12.suse.x86_64.rpm
    

If the installation is unsuccessful or if there are warnings during installation, address them prior to migrating this VM.

Ubuntu

Use the following steps to prepare Ubuntu 14/16/18.

  1. Sign in to the Ubuntu virtual machine as a user with sudo privileged access.
  2. Install the velostrata-prep RPM package using a command such as the following:

    sudo dpkg -i velostrata-prep-<var>VERSION</var>.deb
    

    For example:

    sudo dpkg -i velostrata-prep-1.8-12.deb
    
  3. Install all required or missing prerequisites for the velostrata-prep package.

    sudo apt-get install -f -y
    

If the installation is unsuccessful or if there are warnings during installation, address them prior to migrating this VM using Migrate for Compute Engine.

Amazon Linux

Use the following steps to prepare Amazon Linux AMI or Amazon Linux 2.

  1. Use the following commands to import the ELRepo repository and install the RPM package.

    • For Amazon Linux AMI:

      rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
      rpm -Uvh https://www.elrepo.org/elrepo-release-6-8.el6.elrepo.noarch.rpm
      
    • For Amazon Linux 2:

      rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
      rpm -Uvh http://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm
      
  2. Enable the repository and install the latest kernel:

    yum --disablerepo="*" --enablerepo="elrepo-kernel" list available
    yum --enablerepo=elrepo-kernel install kernel-ml
    
  3. Reboot the VM.

  4. Edit /etc/default/grub to include GRUB_DEFAULT=0.

  5. Run the following command:

    grub2-mkconfig -o /boot/grub2/grub.cfg
    
  6. Reboot the Amazon VM.

  7. Install the Migrate for Compute Engine RPM package for Red Hat.

    See the RHEL / CENTOS tab on this page for instructions.

  8. Perform the migration.

After detaching, be sure to run gcp_env.sh on the destination, cleaning up all AWS agents and installing needed GCP packages.

¿Te ha resultado útil esta página? Enviar comentarios:

Enviar comentarios sobre...

Migrate for Compute Engine (formerly Velostrata)