Basic Deployment

ZStack Cloud supports IPv4 flat networks, IPv6 flat networks, and public networks. This section describes basic deployments of IPv4 flat networks and IPv6 flat networks.


Deploy an IPv4 Flat Network

IPv4, known as Internet Protocol version 4 which defines IP addresses in a 32-bit format, is the most popular Internet Protocol version across the globe. ZStack Cloud flat networks support the IPv4 protocol. This topic mainly describes the basic deployment of IPv4 flat networks.

The following table lists the assumed environment configurations.
Table 1. IPv4 Flat Network Configuration
Flat Network Configurations
NIC em01
VLAN ID No VLAN
IP Range 172.20.108.40-172.20.108.50
Netmask 255.255.0.0
Gateway 172.20.0.1
DHCP IP 172.20.180.41
To create an IPv4 flat network, follow these steps:
  1. Create an L2 network corresponded by an IPv4 flat network, and attach the L2 network to the corresponding cluster.
  2. Create an L3 network corresponded by an IPv4 flat network.
  3. Create a VM instance by using this IPv4 flat network.
  4. Validate the connectivity of this IPv4 flat network.
  1. Create an L2 network corresponded by an IPv4 flat network, and attach this L2 network to the corresponding cluster.
    On the main menu of ZStack Cloud, choose Resource Center > Network Resource > L2 Network Resources > L2 Network. On the L2 Network page, click Create L2 Network. Then, the Create L2 Network page is displayed. On the displayed Create L2 Network page, set the following parameters by referring to IPv4 Flat Network Configuration:
    • Zone: By default, the current zone is displayed.
    • Name: Enter a name for the L2 flat network.
    • Description: Optional. Enter a description for the L2 flat network.
    • Type: Select L2NoVlanNetwork.
    • Cluster: Optional. Select the cluster to be attached, for example, Cluster-1.
    • Network Acceleration Mode: You can use different technologies to improve network performance of the L2 network, including Standard, SR-IOV, and Smart NIC. Here, select Standard.
    • NIC Name: Select or enter an NIC name for the L2 network. For example, em01.
    Figure 1. Create L2 Flat Network


  2. Create an L3 network corresponded by an IPv4 flat network.
    On the main menu of ZStack Cloud, choose Resource Center > Network Resource > L3 Network Resources > Flat Network. On the Flat Network page, click Create Flat Network. The Create Flat Network page appears. On the displayed Create Private Network page, set the following parameters by referring to IPv4 Flat Network Configuration:
    • Name: Enter a name for the L3 flat network.
    • Description: Optional. Enter a description for the L3 flat network.
    • L2 Network: Select an L2 flat network that you created.
    • IP Address Management: Select whether to enable IP Address Management (IPAM) for the L3 flat network. If you enable IPAM, you can set network ranges, IP allocation policy, and DHCP service for the L3 network. Enable IPAM here.
    • Network Address Type: Select IPv4.
    • Network Range Method: Select a method to add a network range for the flat network. Here, select IP Range.
    • Start IP: Set a start IP address for the network range, for example, 172.20.108.40.
    • End IP: Set an end IP address for the network range, for example, 172.20.108.50.
    • Netmask: Set a netmask for the network range, for example, 255.255.0.0.
    • Gateway: Set a gateway for the network range, for example, 172.20.0.1.
    • DHCP Service: Choose whether to enable the DHCP service.
      Note:
      • The DHCP service is a built-in distributed service of the Cloud, which assigns IP addresses only to resources in the Cloud and does not conflict with your existing DHCP server.
      • By default, the DHCP service is enabled so that IP addresses are automatically assigned to resources in the Cloud. You can customize a DHCP IP or use the DHCP IP that the system assigned according to the IP allocation policy.
      • If you disable this option, IP addresses are not automatically assigned to resources that use this network. Therefore, you need to manually assign IP addresses to these resources. In addition, you cannot specify a DHCP IP. Neither can the system allocate one.
      • IP Allocation Policy: Optional. After the DHCP service is enabled, IP addresses can be assigned according to the following three allocation policies:
        • Random: The system randomly assigns IP addresses from the network range.
        • Allocate in Order:
          • The system assigns all available IP addresses from the network range in ascending order. Released IP addresses are assigned in the next allocation.
          • Example: Assume that the network range is 192.168.0.101192.168.0.120, within which 192.168.0.101192.168.0.108 are allocated. If 192.168.0.106 is released, it will be assigned first in the next allocation.
        • Allocate in Cycle:
          • The system assigns available IP addresses to VM instances from the network range in ascending order. Released IP addresses are assigned when currently available IP addresses are used up.
          • Example: Assume that the network range is 192.168.0.101192.168.0.120, within which 192.168.0.101192.168.0.108 are allocated. If 192.168.0.106 is released, it will be assigned after 192.168.0.120 is used.
      • DHCP IP: Optional. Set an IP address for the DHCP server, for example, 172.20.180.41.
        Note:
        • A DHCP IP is an IP address used by the DHCP service to assign IP addresses to resources that use this L3 network.
        • If you create an L3 network for the first time with the DHCP service enabled, or if you add the first network range to an L3 network with the DHCP service enabled, you can customize the DHCP IP.
        • If the L3 network has a DHCP IP, you cannot customize the DHCP IP when you add a network range.
        • The DHCP IP can be in or outside the added IP range, but it must be an unoccupied IP address in the CIDR block of the added IP range
        • The IP range determined by the start IP and end IP cannot contain the link-local address 169.254.0.0/16.
        • If you select random as the IP allocation policy and this field is left blank, the system randomly assigns IP addresses from the added network range.
        • If you select allocate in order/allocate in cycle as the IP allocation policy and this field is left blank, the system uses the start IP address in the network range as the DHCP IP.
    • DNS: Optional. Enter a DNS, such as 114.114.114.114.
    Figure 2. Create L3 Flat Network


  3. Create a VM instance by using this IPv4 flat network.

    On the main menu of ZStack Cloud, choose Resource Center > Resource Pool > Virtual Resource > VM Instance. On the VM Instance page, click Create VM Instance. Then, the Create VM Instance page is displayed. On the displayed page, create two VM instances by using the IPv4 flat network, for example, VM-1 and VM-2.

  4. Validate the connectivity of this IPv4 flat network.

    Expected result: The two VM instances (VM-1 and VM-2) on the same network range can communicate with each other.

    Validate the connectivity:
    • Log in to VM-1 and validate whether VM-1 can ping VM-2.
      Figure 3. VM-1 Pings VM-2


    • Log in to VM-2 and validate whether VM-2 can ping VM-1.
      Figure 4. VM-2 Pings VM-1


    So far, we have introduced the basic deployments of the IPv4 flat network.


Deploy an IPv6 Flat Network

IPv6 is Internet Protocol version 6 that defines IP addresses in a 128-bit format. IPv6 resolves the long-anticipated problem of IPv4 address exhaustion, so many devices can be connected to the Internet. ZStack Cloud flat networks support the IPv6 protocol. This topic describes the basic deployment of IPv6 flat networks.

The following table lists the assumed environment configurations.
Table 1. IPv6 Flat Network Configuration
Flat Network Configurations
NIC em1
VLAN ID 2002
IP Range 234e:0:4567::2-234e:0:4567:0:ffff:ffff:ffff:ffff
Prefix length 64
Gateway 234e:0:4567::1
DHCP IP 234e:0:4567::3
DNS 240c::6644
To create an IPv6 flat network, follow these steps:
  1. Create an L2 network corresponded by an IPv6 flat network, and attach this L2 network to the corresponding cluster.
  2. Create an L3 network corresponded by the IPv6 flat network.
  3. Create two VM instances by using the IPv6 flat network.
  4. Obtain IPv6 addresses of the VM instances.
  5. Validate the connectivity of the IPv6 flat network.
  1. Create an L2 network corresponded by an IPv6 flat network, and attach this L2 network to the corresponding cluster.
    On the main menu of ZStack Cloud, choose Resource Center > Network Resource > L2 Network Resources > L2 Network. On the L2 Network page, click Create L2 Network. Then, the Create L2 Network page is displayed. On the displayed Create L2 Network page, set the following parameters by referring to IPv6 Flat Network Configuration:
    • Zone: By default, the current zone is displayed.
    • Name: Enter a name for the L2 flat network, for example, L2-IPv6-Flat Network.
    • Description: Optional. Enter a description for the L2 flat network.
    • Type: Select L2VlanNetwork.
    • Cluster: Optional. Select the cluster to be attached, for example, Cluster-1.
    • Network Acceleration Mode: You can use different technologies to improve network performance of the L2 network, including Standard, SR-IOV, and Smart NIC. Here, select Standard.
    • VLAN ID: Enter a VLAN ID, for example, 2002.
    • NIC Name: Select or enter an NIC name for the L2 network. For example, em1.
    Figure 1. Create L2-IPv6-Flat Network


  2. Create an L3 network corresponded by the IPv6 flat network.
    On the main menu of ZStack Cloud, choose Resource Center > Network Resource > L3 Network Resources > Flat Network. On the Flat Network page, click Create Flat Network. The Create Flat Network page appears. On the displayed Create Private Network page, set the following parameters by referring to IPv6 Flat Network Configuration.
    • Name: Enter a name for the L3 network, such as L3-IPv6-Flat Network.
    • Description: Optional. Enter a description for the L3 flat network.
    • L2 Network: Select an L2 flat network that you created, such as L2-IPv6-Flat Network.
    • IP Address Management: Select whether to enable IP Address Management (IPAM) for the L3 flat network. If you enable IPAM, you can set network ranges, IP allocation policy, and DHCP service for the L3 network. Enable IPAM here.
    • Network Address Type: Select IPv6.
    • Network Range Method: Select a method to add a network range for the flat network. Here, select IP Range.
    • IP Configuration Mode: Select Stateful-DHCP.
    • Start IP: Set a start IP address for the network range, for example, 234e:0:4567::2.
    • End IP: Set an end IP address for the network range, for example, 234e:0:4567:0:ffff:ffff:ffff:ffff.
    • Prefix Length: Set a prefix length for the network range, for example, 64.
    • Gateway: Set a gateway for the network range, for example, 234e:0:4567::1.
    • DHCP Service: Choose whether to enable the DHCP service.
      Note:
      • The DHCP service is enabled by default. This service automatically assigns an IP address to a VM instance. You can specify an IP address for the DHCP server. If you do not specify, the system assigns a random IP address for the DHCP server.
      • If you disable the DHCP service, no IP address is automatically assigned to VM instances in the flat network. You need to manually configure IP addresses for the VM instances.
      • DHCP IP: Optional. Set an IP address for the DHCP server, for example, 234e:0:4567::3.
        Note:
        • When you create an L3 network and enable the DHCP service for the first time, or when you add the first network range for an L3 network that has the DHCP service enabled, you can specify an IP address for the DHCP server.
        • If a DHCP IP is specified for an L3 network, you cannot specify another DHCP IP when you add a network range for the network.
        • The DHCP IP can be within or out of the added IP range. However, the IP address must be within the CIDR block to which the added IP range belongs and must not be in use.
        • The IP range determined by the start IP and end IP cannot contain the link-local address fe80::/10.
        • If not specified, the system would randomly specify a DHCP IP within the added IP range for the DHCP server.
    • DNS: Set a DNS address for the L3 network, for example, 240c::6644.
    Figure 2. Create L3-IPv6-Flat Network


  3. Create two VM instances by using the IPv6 flat network.

    On the main menu of ZStack Cloud, choose Resource Center > Resource Pool > Virtual Resource > VM Instance. On the VM Instance page, click Create VM Instance. Then, the Create VM Instance page is displayed. On the displayed page, create two VM instances by using the IPv6 flat network, for example, VM-1 and VM-2.

  4. Obtain IPv6 addresses of the VM instances.
    By default, ZStack Cloud can automatically obtain IP addresses for the IPv4 network, while you must manually configure IP addresses for VM instances that use the IPv6 network. Launch the consoles of these two VM instances respectively, and run the following commands to obtain IPv6 addresses:
    [root@loaclhost~]# dhclient -6 eth0  //eth0 indicates the NIC name.
    Note: The address that begins with FE80 is the link-local address instead of the expected address.
    Figure 3. Obtain IPv6 Address


    In this scenario, you will obtain the following IPv6 addresses:
    • VM-1 IP address: 234e:0:4567::63:ab4d
    • VM-2 IP address: 234e:0:4567::31:3c6e
  5. Validate the connectivity of the IPv6 flat network.

    Expected result: The two VM instances (VM-1 and VM-2) on the same network range can communicate with each other.

    Validate the connectivity:
    • Log in to VM-1 and validate whether VM-1 can ping VM-2.
      Figure 4. VM-1 Pings VM-2


    • Log in to VM-2 and validate whether VM-2 can ping VM-1.
      Figure 5. VM-2 Pings VM-1


    So far, we have introduced the basic deployments of the IPv6 flat network.


Deploy a Flat Network Disabled with IP Address Management

IP Address Management (IPAM) is a service for the allocation and management of IP addresses on an L3 network. Enabling IPAM for an L3 network requires you to add network ranges from which IP addresses are allocated to the resources on this L3 network automatically. ZStack Cloud allows you to disable IPAM when creating a flat network which does not need network ranges and other relevant parameters. You can allocate and manage IP addresses of resources on this flat network by yourself without the restriction of network ranges. This topic describes the deployment of a flat network disabled with IPAM.

The following table lists the assumed environment configurations.
Table 1. Flat Network Configuration
Flat Network Configurations
NIC eth0
VLAN ID 2002
Table 2. VM Instance NIC Configuration
Flat Network Configurations
IP address 172.20.60.107
Netmask 255.255.0.0
Gateway 172.20.0.1
To create a flat network disabled with IPAM, follow these steps:
  1. Prepare an L2 network for the flat network, and attach this L2 network to the corresponding cluster.
  2. Create a flat network and disable IP Address Management.
  3. Create a VM instance based on the no-IPAM flat network.
  4. Install GuestTools for the VM instance.
  5. Sync VM NIC configurations.
  6. Validate the IP configuration of the VM NIC.
  1. Prepare an L2 network for the flat network, and attach this L2 network to the corresponding cluster.
    On the main menu of ZStack Cloud, choose Resource Center > Network Resource > L2 Network Resources > L2 Network. On the L2 Network page, click Create L2 Network. Then, the Create L2 Network page is displayed. On the displayed Create L2 Network page, set the following parameters by referring to Flat Network Configuration:
    • Zone: By default, the current zone is displayed.
    • Name: Enter a name for the L2 flat network, for example, L2-No-IPAM-Flat.
    • Description: Optional. Enter a description for the L2 flat network.
    • Type: Select L2VlanNetwork.
    • Cluster: Optional. Select the cluster to be attached, for example, Cluster-1.
    • Network Acceleration Mode: You can use different technologies to improve network performance of the L2 network, including Standard, SR-IOV, and Smart NIC. Here, select Standard.
    • VLAN ID: Enter a VLAN ID, for example, 2002.
    • NIC Name: Select or enter an NIC name for the L2 network. For example, eth0.
    Figure 1. Create L2-No-IPAM-Flat Network


  2. Create a Flat Network and disable IP Address Management.
    On the main menu of ZStack Cloud, choose Resource Center > Network Resource > L3 Network Resources > Flat Network. On the Flat Network page, click Create Flat Network. The Create Flat Network page appears. On the displayed Create Private Network page, set the following parameters:
    • Name: Enter a name for the L3 network, such as L3-No-IPAM-Flat.
    • Description: Optional. Enter a description for the L3 flat network.
    • L2 Network: Select an L2 flat network that you created, such as L2-No-IPAM-Flat.
    • IP Address Management: Select whether to enable IP address management (IPAM) service for the 3 network. Disable IPAM in this scenario. After the disabling, you do not need to set network ranges, gateway netmask, and IP allocation policy for the L3 network.
    • DHCP Service: After disabling IPAM, the DHCP service is disabled by default and cannot be enabled.
    • DNS: Set a DNS address for the L3 network. You can leave this parameter as blank in this scenario.
    Figure 2. Create L3-No-IPAM-Flat Network


  3. Create a VM instance based on the no-IPAM flate network.
    On the main menu of ZStack Cloud, choose Resource Center > Resource Pool > Virtual Resource > VM Instance. On the VM Instance page, click Create VM Instance. Then, the Create VM Instance page is displayed. On the displayed page, create a VM instances by using the no-IPAM flat network you created. You can set the network configuration according to Table 2.
    • Network: Select the flat network disabled with IPAM you create.
    • Make Default: Select whether to set the flat network as the default network of the VM instance. In this scenario, set the flat network as the default network.
    • Enable SR-IOV: Do not enable SR-IOV in this scenario.
    • Assign IPv4: The system does not allocate an IP address to a VM NIC created on an L3 network disabled with IPAM. To configure the NIC IP address, you can either manually assign one on the Cloud or configure one in the VM instance. Assign one on the Cloud in this scenario.
      Note: If you configure an IP address in the VM instance, the IP address cannot be read or managed by the Cloud currently.
      • IPv4 : Manually assign an IP address for the VM instance. Enter 172.20.60.107 in this scenario.
        Note:
        • Make sure that the IP address has not been occupied on the Cloud.
        • Install GuestTools for the VM instance after the creation and sync NIC configurations to make the IP address take effect.
      • Netmask: Set the IPv4 netmask. Enter 255.255.0.0 in this scenario.
      • IPv4 Gateway: Set the IPv4 gateway. Enter 172.20.0.1 in this scenario.
      • Security Group: Associate an existing security group to the VM instance for network security services. You can leave this paramater as blank in this scenario.
    • Assign IPv6: Select whether to manually assign an IPv6 address for the VM instance. Do not assign an IPv6 address in this scenario.
    • MAC Address: Select whether to manually assign a MAC address for the VM instance. DO not assign a MAC address in this scenario.
    Figure 3. VM Instance Network Configuration


  4. Install GuestTools for the VM Instance.
    Follow these steps to install GuestTools for the VM instance:
    1. Install ISO.
      On the details page of the VM-Self-Managed-IP, click GuestTools: Install > Next: Install on VM Console.
      Figure 4. Install GuestTools: Install ISO


    2. Install on VM Console
      Run the following commands on the VM console to finish the installation:
      # Create a mount point. mkdir /mnt/cdrom # Attach the CD-ROM image. mount /dev/cdrom /mnt/cdrom # Install GuestTools. cd /mnt/cdrom/ bash ./zs-tools-install.sh # Unmount the CD-ROM image (optional). cd ~ umount /mnt/cdrom
      Figure 5. Install GuestTools: Install on VM Console




    Note: If you configure an IP address in the VM instance, you can skip this step.
  5. Sync VM NIC configurations.
    On the details page of VM-Self-Managed-IP, click Configuration > NIC > Synchronize Configurations to deploy the IP address assigned on the Cloud to the NIC actually.
    Note: If you configure an IP address in the VM instance, you can skip this step.
  6. Validate the IP address of the VM NIC.

    Expected result: The IP address assigned on the Cloud can be queried in the VM instance.

    Log in to the VM-Self-Managed-IP and check the VM IP address.

    Figure 6. Validate the IP Address of the VM NIC


    Note: If you configure the IP address in the VM instance, you can skip this validation.
So far, you have deployed a flat network disabled with IP Address Management.

Back to Top

Download

Already filled the basic info?Click here.

Enter at least 2 characters.
Invalid mobile number.
Enter at least 4 characters.
Invalid email address.
Wrong code. Try again. Send Code Resend Code (60s)

An email with a verification code will be sent to you. Make sure the address you provided is valid and correct.

同意 不同意

I have read and concur with the Site TermsPrivacy PolicyRules and Conventions on User Management of ZStack Cloud

Download

Not filled the basic info yet? Click here.

Invalid email address or mobile number.
同意 不同意

I have read and concur with the Site TermsPrivacy PolicyRules and Conventions on User Management of ZStack Cloud

Email Us

contact@zstack.io
ZStack Training and Certification
Enter at least 2 characters.
Invalid mobile number.
Enter at least 4 characters.
Invalid email address.
Wrong code. Try again. Send Code Resend Code (60s)

同意 不同意

I have read and concur with the Site TermsPrivacy PolicyRules and Conventions on User Management of ZStack Cloud

Email Us

contact@zstack.io
Request Trial
Enter at least 2 characters.
Invalid mobile number.
Enter at least 4 characters.
Invalid email address.
Wrong code. Try again. Send Code Resend Code (60s)

同意 不同意

I have read and concur with the Site TermsPrivacy PolicyRules and Conventions on User Management of ZStack Cloud

Email Us

contact@zstack.io

The download link is sent to your email address.

If you don't see it, check your spam folder, subscription folder, or AD folder. After receiving the email, click the URL to download the documentation.

The download link is sent to your email address.

If you don't see it, check your spam folder, subscription folder, or AD folder.
Or click on the URL below. (For Internet Explorer, right-click the URL and save it.)

Thank you for using ZStack products and services.

Submit successfully.

We'll connect soon.

Thank you for using ZStack products and services.