Help Center/ Migration Center/ Best Practices/ Server Migration/ Keeping Private IP Addresses of Servers Unchanged After the Migration
Updated on 2025-12-02 GMT+08:00

Keeping Private IP Addresses of Servers Unchanged After the Migration

In MgC server migration workflows, you can choose to retain private IP addresses for source servers on target servers after the migration. This feature can reduce the need to modify service code due to IP address changes.

Disclaimer

  • Service availability risks

    This feature can ensure that the private IP addresses of source servers are retained on target servers. It does not guarantee your services can run properly on the target servers. You need to evaluate and assume the risks arising from using this feature.

  • Rollback description

    Migration workflows cannot automatically roll back the IP addresses of target servers to their original ones. If any problems happen when you use this function, you can perform a rollback manually.

  • IP address conflicts

    Since the source and target servers have the same private IP addresses, there may be IP address conflicts. This may result in service unavailability.

  • Unknown risks

    There may be other unknown issues since the migration does not detect or scan source services.

  • Customer responsibilities

    You need to fully test and prepare for the migration as well as check and solve possible problems after the migration is complete. You are advised to simulate the migration in a test environment to evaluate potential risks and formulate corresponding countermeasures.

Constraints

  • Target server shutdown

    To retain source servers' private IP addresses on the paired target servers, the target servers must be stopped. If a target server is not stopped, the system will stop it automatically.

  • Subnet requirements

    When you select a subnet in the target VPC, the subnet must be in the same network range as the source servers.

  • Network interface requirements

    A target server can only have one network interface. Extended network interfaces are not allowed for target servers.

  • Supported IP version

    Only IPv4 addresses can be retained.

Preparations

  • Prepare a Huawei account.

    Before using MgC, prepare a HUAWEI ID or an IAM user that can access MgC and obtain an AK/SK pair for the account or IAM user. For details, see Preparations.

  • Create a migration project.

    Create a migration project on the MgC console. For details, see Managing Migration Projects. Set Project Type to Application migration.

Procedure

  1. Download and install the MgC Agent (formerly Edge).

    Prepare a Windows server in the source intranet for installing the MgC Agent. For details about the server requirements and the MgC Agent installation method, see Installing the MgC Agent on Windows.

  2. Connect the MgC Agent to MgC.

    Log in to the MgC Agent console and connect the MgC Agent to MgC. For details, see Connecting the MgC Agent to MgC.

  3. Add resource credentials.

    After the connection is successful, add the credentials of the source servers to be migrated to the MgC Agent. For details, see Adding Resource Credentials. Correctly configure Resource Type based on the source servers when you add their credentials.

  4. Discover source servers.

    MgC provides three methods to meet your requirements in different scenarios.

  5. Create an application assessment.

    The system will generate target server recommendations based on the collected source server details, including specifications, performance data, and workload types. For details, see Generating Target Recommendations.

    After the assessment, you can adjust the specifications of the targets servers and disks, for example, scaling in or out the disks. For details, see Modifying Target Configurations.

  6. Create a batch migration plan and a workflow.

    After all the preceding steps are complete, go to the Migration Plans page and create a batch server migration plan. Check the box of Retain Private IP Address of Primary NIC.

    • In the VPC drop-down list, select the VPC that contains the private IP address segments of the source servers.
    • In the Subnet drop-down list, select the subnet that contains the private IP addresses of the source servers. The system will check whether the selected subnet contains the private IP addresses of all the source servers. You can proceed with creating the workflow only if this condition is met.
    • In the Security Group drop-down list, select a security group as required.

Manual Rollback

If you do not want to retain the private IP addresses of the source servers or any problems happen, you can manually switch the VPC for rollback. For details, see Changing a VPC.