tencent cloud


Building Up an IPv4 VPC

Last updated: 2024-01-24 17:22:28
    This tutorial describes how to quickly build up a Virtual Private Cloud (VPC) with IPv4 CIDR blocks.


    This document guides through whole process of setting up an IPv4-based VPC.


    Before using Tencent Cloud products, create a Tencent Cloud account and complete identity verification.


    Step 1: create a VPC and subnet

    Once created, the CIDR blocks (IP ranges) of VPCs and subnets cannot be modified. Therefore, complete network planning in advance.
    1. Log in to the VPC console.
    2. Select a region at the top of the page and click + New.
    3. In the Create VPC pop-up window, configure the VPC and subnet information as instructed below.
    VPC information
    Name: the name of the VPC.
    IPV4 CIDR Block: You can choose any one of the IP ranges as the VPC IP range, such as - (mask range: 12 to 28) - (mask range: 12 to 28) - (mask range: 16 to 28)
    Tags: You can optionally add tags to help you better manage resource permissions of sub-users and collaborators.
    Subnet information
    IPv4 CIDR Block:
    You can choose an IP range within or the same as the VPC IP range. For example, if the VPC IP range is, you can choose an IP range between and as the subnet IP range.
    If the VPC in which subnets are located needs to communicate with other VPCs or IDCs, make sure that the subnet IP range does not overlap with the peer IP range. Otherwise, the interconnection over a private network may fail.
    Availability Zone: select an availability zone in which the subnet resides. A VPC allows subnets in different availability zones, and these subnets can communicate with each other via a private network by default.
    Tags: You can optionally add tags to help you better manage resource permissions of sub-users and collaborators.

    Step 2: purchase a CVM instance

    1. Log in to the CVM console to create a CVM instance in the VPC created in the previous step.
    2. Click Create in the top-left corner of the list page to go to the CVM purchase page.
    3. On the custom configuration page, configure the CVM instance and then click Buy Now. The CVM network configurations are as follows:
    Network: select the created VPC and subnet.
    Public network IP: do not check
    Security Group: select New security group and configure it as instructed in Configuring Security Groups.

    Step 3: apply for an EIP and bind it to the CVM instance

    An EIP is a public IP address that can be applied for and purchased independently. You can bind an EIP to a CVM instance to enable public network access.
    1. Log in to the EIP console.
    2. On the EIP page, select the region where the CVM instance is located. Click Apply in the top-left corner.
    3. In the Apply for EIP pop-up window, configure relevant parameters and click OK.
    4. On the EIP page, locate the EIP you applied for, and click More > Bind in the Operation column.
    5. In the Bind resources window, select CVM Instances as the resource type to be bound, select the CVM instance, and click OK.
    6. In the pop-up confirmation window, click OK.

    Step 4: test public network connectivity

    Perform the following operations to test the public network connectivity of the CVM instance.
    Before performing the test, make sure that the security group allows access to the corresponding IP address and port. For example, the ICMP protocol is opened, and the server can be pinged over the public network. For more information, see Viewing a Security Group Rule.
    1. Log in to the CVM instance with an EIP bound. For more information, see Login and Connect to Instances.
    2. Run the ping Another public IP command, such as ping www.qq.com, to test public network connectivity.
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support