# Assigning IPv6 ranges

**URL:** <https://forum.opennebula.io/t/assigning-ipv6-ranges/9930>\
**Category:** Product Support\
**Created:** [September 14, 2021, 10:47am UTC](https://forum.opennebula.io/t/assigning-ipv6-ranges/9930 "2021-09-14T10:47:26Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gigatux](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.opennebula.io/gigatux/32/7085_2.png) [@gigatux](https://forum.opennebula.io/u/gigatux)\
**Post date:** [September 14, 2021, 10:47am UTC](https://forum.opennebula.io/t/assigning-ipv6-ranges/9930/1 "2021-09-14T10:47:26Z")

</div>

Hello,

Is there any way to assign entire IPv6 ranges to a VM?

I’ve created an IP6\_STATIC range with an entire /48 in there, but cannot find any way to assign subnets of this (e.g. a /64) to any VM. When creating a new network interface, I only appear to be able to add individual IPv6 addresses in the network overrides section:

 ![image](https://canada1.discourse-cdn.com/flex031/uploads/opennebula/original/2X/2/29051d72b2673d5bba35a382ae6a16fc44dcab17.png)

It looks like OpenNebula seems to base a lot of IPv6 things around MAC addresses, which I fully understand. However, our use case for these large ranges just has the one MAC address/interface which serves lots of statically configured IPv6 addresses.

Thanks.

---

<div class="post-metadata">

**Author:** ![gigatux](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.opennebula.io/gigatux/32/7085_2.png) [@gigatux](https://forum.opennebula.io/u/gigatux)\
**Post date:** [January 23, 2025, 6:34pm UTC](https://forum.opennebula.io/t/assigning-ipv6-ranges/9930/2 "2025-01-23T18:34:21Z")

</div>

To this day I still can’t figure this out.

Even when I add a PREFIX\_LENGTH of, say, 64, the size seems to refer to individual /128s with IP6\_STATIC address blocks.

Has anyone managed to assign a block, say a /32, with blocks of /64 allocated to VMs? What was the format of the address block you created?

---

<div class="post-metadata">

**Author:** ![FrancJP](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.opennebula.io/francjp/32/7690_2.png) [@FrancJP](https://forum.opennebula.io/u/FrancJP)\
**Post date:** [January 27, 2025, 10:16am UTC](https://forum.opennebula.io/t/assigning-ipv6-ranges/9930/3 "2025-01-27T10:16:38Z")

</div>

Hi @gigatux,

Apologies for not being able to help you earlier with this, but is not so simple (as you might guess).

From what I can comment from the Documentation, OpenNebula doesn’t offer a built-in feature to allocate entire IPv6 subnets to individual VMs automatically, so it has to be planned in advance and requires manual configuration.

Check the Address Range: [Virtual Network Template — OpenNebula 6.10.2 documentation](https://docs.opennebula.io/6.10/management_and_operations/references/vnet_template.html?highlight=ipv6#the-address-range)

The platform primarily manages individual IP addresses rather than subnet allocations. In scenarios where a VM requires control over a larger IPv6 subnet, such as a /64, a potential approach would be to assign a single IPv6 address from the desired subnet to the VM and then configure the VM’s internal networking to manage the rest of the subnet.

I can’t help you more on this, so if you need more support, let us know if you managed to follow the documentation and need more support on the manual configuration.

Regards,

---

<div class="post-metadata">

**Author:** ![gigatux](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.opennebula.io/gigatux/32/7085_2.png) [@gigatux](https://forum.opennebula.io/u/gigatux)\
**Post date:** [January 30, 2025, 2:04pm UTC](https://forum.opennebula.io/t/assigning-ipv6-ranges/9930/4 "2025-01-30T14:04:44Z")

</div>

Hi @FrancJP ,

I really appreciate the response.

I think half the confusion comes from the [Virtual Network Template](https://docs.opennebula.io/6.10/management_and_operations/references/vnet_template.html) page having `PREFIX_LENGTH`. I think this has made a few of us assume that OpenNebula would allocate a subnet of this size to VMs, especially as the `SIZE` argument also talks about using `PREFIX_LENGTH`.

Personally, I think this is quite an important omission especially as many home internet providers even allocate a /64 (so “servers” really should do this). However, I appreciate we’re in feature request territory, not bug territory (apart from possibly a bug because of potentially misleading documentation).

The problem with your suggestion is that firewall rules almost certainly won’t be created properly. I imagine they’ll allow the one IPv6 address through the host’s firewall, not the whole range.

In my ideal world, we would have:

- Another type of IPv6 address range, e.g. IP6\_SUBNETS. This would be necessary to ensure existing installs behave as expected.
- SIZE being based on the number of PREFIX\_LENGTHs, e.g. it would be 16 if you had a /60 you wanted to split into /64s. Maybe even SIZE being the exponent in the 2^x calculation, e.g. 4 in the above example.
- The full subnet being allocated to the VM (shown correctly in the UI, and with firewall rules created).
- The VM’s interfaces being correctly configured, at least with maybe the :: address or similar set up.

The above is just a wishlist of course!

Marc

---

<div class="post-metadata">

**Author:** ![FrancJP](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.opennebula.io/francjp/32/7690_2.png) [@FrancJP](https://forum.opennebula.io/u/FrancJP)\
**Post date:** [January 30, 2025, 2:11pm UTC](https://forum.opennebula.io/t/assigning-ipv6-ranges/9930/5 "2025-01-30T14:11:23Z")

</div>

Hello @gigatux,

No problem for the wishlist, if you want, you can suggest some of these on our Repo:

> **[OpenNebula/one](https://github.com/OpenNebula/one/issues/)**
>
> The open source Cloud & Edge Computing Platform bringing real freedom to your Enterprise Cloud 🚀 - OpenNebula/one

Regards,

---

<div class="post-metadata">

**Author:** ![gigatux](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.opennebula.io/gigatux/32/7085_2.png) [@gigatux](https://forum.opennebula.io/u/gigatux)\
**Post date:** [February 1, 2025, 10:49am UTC](https://forum.opennebula.io/t/assigning-ipv6-ranges/9930/6 "2025-02-01T10:49:45Z")

</div>

Feature request created here: [Add support for IPv6 ranges · Issue #6888 · OpenNebula/one · GitHub](https://github.com/OpenNebula/one/issues/6888)
