Skip to main content

How the network works

Networking inside a VDC is built around Virtual Networks (VNets)Virtual Network: a private network inside a VDC, defined by a CIDR and divided into subnets.. A VNet is a private network that you divide into subnets, connect to the internet when needed, and protect with firewall rules. This page explains the pieces and how they fit together.

Virtual Networks (VNets)​

A VNet is a private network defined by a CIDRNotation for an IP address range, such as 10.0.0.0/16. block, such as 10.0.0.0/16. That block is the address space from which all of the VNet's subnets are carved. A VDC can hold more than one VNet, and each VNet is isolated from the others unless you connect them.

A VNet also has a default DNS domain (for example, network.local) used for internal name resolution.

Subnets​

A VNet is split into one or more subnetsA range within a VNet, defined by its own CIDR, to which VMs connect., each with its own CIDR inside the VNet's range. Subnets cannot overlap. Every subnet has a gateway address and assigns IPs to VMs either by DHCP or as a static IP.

When you create a VM, each of its network adapters (NICs) connects to a subnet.

The subnet assigns an address automatically from its range. This is the simplest choice for most VMs.

Type a CIDR to see the address range a subnet would cover:

Network address
10.0.1.0
Netmask
255.255.255.0
Usable range
10.0.1.1 to 10.0.1.254
Broadcast
10.0.1.255
Usable hosts
254
Total addresses
256

Internet access​

Internet access is turned on per subnet, with the Internet access switch of each subnet. A subnet with it on reaches the internet through the VNet's internet gatewayA public IP that acts as a VNet egress point to the internet., a public IP that acts as the egress point; a subnet with it off is isolated, with no internet in or out. The VNet gets its public IP from the pool only when at least one subnet or VPN uses it, and gives it back when none does.

Advanced: changing internet access later

You can turn internet access on or off on a subnet at any time. Turning it on in a VNet without a public IP assigns one from the pool. Turning it off on the last subnet that uses it releases the IP, unless a VPN of the VNet still uses it, and turning it on again later brings the same address back while it is still free (see Getting the same address back).

Public IPs​

A public IPA routable external address from the VDC pool, attached to a VM or used as an internet gateway. is a routable external address. You do not pick one from a list: when you ask for a public IP, the platform assigns a free address from the datacenter's pool at that moment. You can ask for one:

  • on a VM's network adapter (Allocate public IP), so the VM is reachable from the internet,
  • as a VNet's internet gateway, when a subnet turns on Internet access or a VPN is created in the VNet, or
  • as a separate endpoint of an OpenVPN server (Use a separate public IP), which takes one more IP from the contract.

IPsec connections and OpenVPN servers use the VNet's public IP by default; the form shows it as the Endpoint address, the address to set on your router or to give to your users.

The address stays with the resource for as long as the resource exists. How many public IPs a VDC can hold at the same time is set by the public IP limit of its contract.

Getting the same address back​

When you release a public IP, or delete the resource that used it, the platform remembers who used it last: the VM, the VNet or the OpenVPN server, and the VDC they belong to. When that same resource asks for a public IP again, it gets the same address back, so a DNS record or an allow list that points to it keeps working. A VM with more than one network adapter gets each adapter's own address back.

  • For a period after the release (30 days by default), the address is kept for your VDC.
  • While the resource that used it still exists, the address waits for it: another VM of your VDC gets a different address from the pool.
  • If you delete that resource, the next resource of your VDC that asks for a public IP gets the kept address, so a new VM that replaces a deleted one keeps its address.
  • A kept address is not billed and does not count as in use. If the IPs in use plus the kept ones already reach the public IP limit of the contract, a new public IP in your VDC reuses the oldest address your VDC keeps instead of taking a new one from the pool.
  • Keeping an address never leaves anyone without a public IP: when the datacenter's pool has no other free address, a kept address is handed out, even to another VDC.
  • After the period, the address goes back to the pool, but the same resource still gets it back as long as nobody else has taken it.

Internal DNS​

Within a VNet you can create static DNS records that map a hostname to an internal IPv4 address (an A record). Combined with the VNet's default domain, this lets VMs reach each other by name instead of by IP.

Connecting and protecting the network​

  • Firewall: rules are defined per VNet under a default-deny policy. Traffic that is not explicitly allowed is blocked. See What is a firewall.
  • VPNs and Direct Connect: connect your on-premises networks to a VNet through OpenVPN, IPsec, or a dedicated Direct Connect link.