Set up for migration

Before you start the modernization process, you need to check whether your application component is compatible for modernization and prepare your setup for modernization.

This page describes how to prepare your source and local machines for modernization.

Set up the Linux source machine

  • Install rsync:

    • On Debian:

      sudo apt install rsync
      
    • On Fedora:

      sudo dnf install rsync
      

    Ensure that rsync is available in the PATH setting.

Set up the Linux local machine

Download or upgrade Migrate to Containers CLI

  • Download or upgrade the Migrate to Containers CLI on a Linux machine:

    curl -O "https://m2c-cli-release.storage.googleapis.com/$(curl -s https://m2c-cli-release.storage.googleapis.com/latest)/linux/amd64/m2c"
    chmod +x ./m2c
    

    This downloads the latest version of the Migrate to Containers CLI and Migrate to Containers plugins.

Check connectivity

Ensure that you can access the source machine from the local machine using either direct SSH or the gcloud compute ssh command.

Optional: Set up for offline migration

If you want to perform migration on your local network without pulling resources from the internet, then you can complete the following steps to prepare your local machine for offline migrations.

After you've downloaded Migrate to Containers CLI, perform the following steps:

  1. Download the offline Migrate to Containers CLI plugins bundle:

    curl -O https://storage.googleapis.com/modernize-plugins-prod/$(curl -s https://storage.googleapis.com/modernize-plugins-prod/latest)/m2c-offline-bundle-linux.tar
    
  2. If required, copy the Migrate to Containers CLI and offline Migrate to Containers CLI plugins bundle to the offline environment.

  3. Unpack the offline Migrate to Containers CLI plugins bundle:

    ./m2c plugins unpack -i m2c-offline-bundle-linux.tar
    

    To add support for offline data migration, specify a container registry that is available in your local network:

    ./m2c plugins unpack -i m2c-offline-bundle-linux.tar --registry HOSTNAME
    

    Replace HOSTNAME with the container registry hostname.

Your local machine is set up for offline migration. To upgrade the offline Migrate to Containers CLI plugins bundle, upgrade Migrate to Containers CLI to the latest version, and then repeat the steps to download and unpack the plugins bundle.

If you want to turn off the offline mode later, then you can use the config set command to set the offline option to false.

Set up the Windows local machine

  • You must be able to run as administrator on the local machine.
  • Install Docker.

Download or upgrade Migrate to Containers CLI

To download or upgrade Migrate to Containers CLI on a Windows machine, perform the following steps:

cmd

  1. Find the latest version of Migrate to Containers CLI:

    curl -s https://m2c-cli-release.storage.googleapis.com/latest
    
  2. Download the latest version of Migrate to Containers CLI:

    curl -O "https://m2c-cli-release.storage.googleapis.com/VERSION/windows/amd64/m2c.exe"
    

    Replace VERSION with the latest version of Migrate to Containers CLI.

PowerShell

  • Download the latest version of Migrate to Containers CLI:

    curl.exe -O https://m2c-cli-release.storage.googleapis.com/$(curl.exe -s https://m2c-cli-release.storage.googleapis.com/latest)/windows/amd64/m2c.exe
    

This downloads the latest version of the Migrate to Containers CLI and Migrate to Containers plugins.

What's next