VLAN
What is a VLAN?
A VLAN lets your instances in the same zone communicate over public networks by grouping them into isolated, secured network segments, that is a CIDR block. A VLAN also helps maximize traffic efficiency if you have a large number of instances.
VLANs are auto system-generated upon assigning a CIDR block to a zone. You do not need to create a VLAN manually. There is only one VLAN in a specific zone.
Note
VLANs are nit supported in Los Angeles Zone B and Frankfurt Zone A for now.
Features
Adding your instances into a VLAN, you can enjoy:
An isolated and secured network;
Floating IPs between different instances.
Use a VLAN if you want to:
Build your own LVS in DR mode;
Have floating IP addresses between instances for application requirement or redundancy;
Get a bigger IP range and start using it immediately;
Attach more instances for the same IP range in future.
Limits
VLANs use CIDR notation to represent the IP space. For example, a
/29
represents a 29 leading 1-bits subnet mask (255.255.255.248
), an IP space with 8 IP addresses. Take out the network ID and broadcast IP, and we will use the first usable IP for your VLAN gateway, then you will get 8-3=5 usable IP addresses.When you attach the instances to the VLANs, you will be asked to pick up one usable IP for the instance, and the instance's existing internet IP address will be replaced by the VLANs' usable IP address.
VLAN and Elastic IP
VLAN provides Layer 2 communication between servers, and most of the technologies such as load balancing, redundancy DR and IP floating are based on Layer 2 communication. Therefore if you need to deploy the above technologies, please add your instances into a VLAN first.
Elastic IP only provides additional public IP, and one IP can only be used for one instance at the same time. In addition an elastic IP does not support Layer 2 communication with other IPs.
VLAN and Virtual Private Cloud
VLAN provides public Layer 2 communication while Virtual Private Cloud provides private Layer 2 communication.
If your business requires public communication between instances in the same zone, please add your instances into a VLAN.
Functions like load balancing and firewall need to be built upon public Layer 2 communication.
Last updated