Objective
On the High Grade & SCALE ranges, it is not possible to manage additional IPs in bridged mode (via virtual MACs). It is therefore necessary to configure additional IPs in routed mode or via the vRack.
To date, the documentation only covers the solution via the vRack.
This guide explains how to configure the network on VMware ESXi.
Requirements
- a public block of IP addresses in your account, with a minimum of four addresses
- your chosen private IP address range
- a vRack-compatible dedicated server
- a vRack service activated in your account
- access to the OVHcloud Control Panel
Instructions
On these server ranges, there are four network cards. The first two for the public, the last two for the private network. To get all the bandwidth, aggregates must be created.
Additional IP via vRack
Original configuration
In this example:
- the public interfaces are
vmnic2
andvmnic3
; - the private interfaces are on
vmnic0
andvmnic1
.
A first vSwitch exists but only has a vmnic2
interface.
Check that your configuration is similar. You can access information on MACs and public or private interfaces in your OVHcloud Control Panel or via the OVHcloud API.
Explanations
You need to:
- create the aggregate on the public vSwitch
- create the vSwitch for the vRack
- create a port group
- create VMs using the new port group as the network interface.
Configure ESXi
You will need to follow the next steps in command mode (shell) instead of the ESXi GUI.
Creating the aggregate in LACP mode on the vSwitch that carries the public interfaces
[root@localhost:~] esxcli network vswitch standard uplink add --uplink-name=vmnic3 --vswitch-name=vSwitch0
[root@localhost:~] esxcli network vswitch standard policy failover set -l iphash -v vSwitch0
Output:
Creating vSwitch and vRack aggregation on private interfaces
[root@localhost:~] esxcli network vswitch standard add --vswitch-name=vRackvSwitch
[root@localhost:~] esxcli network vswitch standard uplink add --uplink-name=vmnic0 --vswitch-name=vRackvSwitch
[root@localhost:~] esxcli network vswitch standard uplink add --uplink-name=vmnic1 --vswitch-name=vRackvSwitch
[root@localhost:~] esxcli network vswitch standard policy failover set -l iphash -v vRackvSwitch
[root@localhost:~]
Output:
Creating a port group for the new “vRackvSwitch” vSwitch
[root@localhost:~] esxcli network vswitch standard portgroup add --portgroup-name=portgroupvRackvSwitch --vswitch-name=vRackvSwitch
VM configuration
The VMs must have the new portgroupvRackvSwitch
port group in the network interface.
Configure a usable IP address
In the case of vRack, the first address and the last two addresses in a given IP block are always reserved for the network address, its gateway and its broadcast address respectively. This means that the first usable address is the second address in the block, as shown below:
46.105.135.96 # Reserved: network address
46.105.135.97 # First usable IP
46.105.135.98
46.105.135.99
46.105.135.100
46.105.135.101
46.105.135.102
46.105.135.103
46.105.135.104
46.105.135.105
46.105.135.106
46.105.135.107
46.105.135.108
46.105.135.109 # Last usable IP
46.105.135.110 # Reserved: network gateway
46.105.135.111 # Reserved: network broadcast
To configure the first usable IP address, you must edit the network configuration file as shown below. In this example, we use a subnet mask of 255.255.255.240.
Additionally, we are using ens18
for our interface name in this example. To check the name of your interface, use the ip add
command.
The subnet mask used in this example is appropriate for our IP block. Your subnet mask may differ depending on the size of your block. When you purchase your IP block, you will receive an email notifying you of the subnet mask to use.
Configuration example of a client VM on Debian
File contents /etc/network/interfaces
:
auto lo ens18
iface lo inet loopback
iface ens18 inet static
address 46.105.135.97
netmask 255.255.255.240
gateway 46.105.135.110