After you establish a ClassicLink connection, you can connect an Elastic Compute Service (ECS) instance in a classic network to the cloud resources deployed in a Virtual Private Cloud (VPC) network.

Prerequisites

Before you can establish a ClassicLink connection, make sure that the following conditions are met:
  • You have read and understand the limits for establishing a ClassicLink connection. For more information, see Overview.
  • The ClassicLink feature is enabled for the VPC network to which the ClassicLink connection is established. For more information, see Enable ClassicLink.

Procedure

  1. Log on to the ECS console.
  2. In the left-side navigation pane, choose Instances & Images > Instances.
  3. Select the region where your ECS instance is deployed.
  4. On the Instances page, find the classic network-connected ECS instance, choose More > Network and Security Group > Set classic link in the Actions column.
  5. In the Connect to VPC dialog box, select the VPC network to be connected, and click OK.
  6. Click Go to the instance security group list and add ClassicLink rules, and click Add ClassicLink Rule.
    Add a ClassicLink rule
  7. In the Add ClassicLink Rule dialog box, set the required parameters, and click OK. The following table describes the parameters.
    Parameter Description
    Classic Security Group The name of the classic security group.
    Select VPC Security Group Select the security group of the VPC network.
    Mode Select one of the following authorization modes:
    • Classic <=> VPC: allows the ECS instance in the classic network and cloud resources in the VPC network to access each other (recommended).
    • Classic => VPC: allows the ECS instance in the classic network to access cloud resources in the VPC network.
    • VPC => Classic: allows the cloud resources in the VPC network to access the ECS instance in the classic network.
    Protocol Type Select the protocol for communication.
    Port Range Specify the ports for communication. Ports must be specified in the format of xx/xx. For example, if port 80 is used, enter 80/80.
    Priority Specify the priority of the security group rule. A smaller value indicates a higher priority.
    Description Enter a description for the security group.
  8. Go back to the Instances page, click the Column Filters icon in the upper-right corner. In the dialog box that appears, select Connection Status, and click OK to check the connection status of the ECS instance.
    Figure 1. Column Filters
    Column Filters
    Figure 2. Connection Status
    Connection Status
    Figure 3. Connected
    Connected