Packet IPAM driver¶
Feature available since OpenNebula 5.8.5 only.
This IPAM driver is responsible for managing the public IPv4 ranges on Packet as IPv4 Address Ranges within the OpenNebula Virtual Networks. It manages full lifecycles of the Address Range from allocation of a new custom range to its release. Read more about the IPAM Driver in the Integration Guide.
The functionality can be used only for external NIC aliases (secondary addresses) of the virtual machines, and only if all the following drivers and hooks are used together:
To enable the Packet IPAM, you need to update the
IPAM_MAD section in your
oned.conf configuration file to look like:
IPAM_MAD = [ EXECUTABLE = "one_ipam", ARGUMENTS = "-t 1 -i dummy,packet" ]
After that, you have to restart OpenNebula so the change takes effect.
Create Address Range¶
An IPAM-managed Address Range can be created during the creation of a new Virtual Network, or any time later as an additional Address Range in an existing Virtual Network. Follow the Virtual Network Management documentation.
The Packet IPAM managed Address Range requires following template parameters to be provided:
||Random fake starting IP address of the range|
||OpenNebula Address Range type|
||Number of IPs to request|
||IPAM driver name|
||Types of IPs to request|
||Packet datacenter name|
||Packet project ID|
||Packet API token|
Due to a bug in OpenNebula, you need to always provide fake starting
IP for the new address range. Unfortunately, this IP address won’t be respected and only the IPs provided by Packet will be always used.
To create the address range:
$ cat packet_ar AR = [ IP = "192.0.2.0", TYPE = IP4, SIZE = 2, IPAM_MAD = "packet", PACKET_IP_TYPE = "public_ipv4", FACILITY = "ams1", PACKET_PROJECT = "****************", PACKET_TOKEN = "****************", ] $ onevnet addar <vnetid> --file packet_ar