1

As I was reading this article on How to: calculating IPv6 subnets outside the nibble boundary https://blog.apnic.net/2018/08/10/how-to-calculating-ipv6-subnets-outside-the-nibble-boundary/

The author takes an example for subnet address 2001:558::/31. He calculates the subnets for /32 and /36? can anyone explain why he goes for /32 and /36 instead of calculating for /31 ?

  • Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you can provide and accept your own answer. – Ron Maupin 6 hours ago
3

So, the point is that given a /31 prefix, how to get subnets from that, and his example is for /32 and /36 subnets. It works the same way for IPv6 as for IPv4, except that the IPv6 address is 128 bits, and the IPv4 address is 32 bits.

Think about this; the current Global IPv6 address range is 2000::/3 (a non-nibble boundary), and every Global prefix is a subnet of that, generally allocated as a /48 prefix for each site, giving you 65,536 standard /64 networks per site. That means there are 2^45 (48 bits per prefix, minus the 3 bit prefix equals 45 bits), or 35,184,372,088,832 prefixes for standard /48 sites.

You can break prefixes on any bit boundary, but it is simpler to use nibble boundaries, and IPv6 has plenty of addressing to do that. The currently allocated global address space comprises only one eighth of the entire IPv6 address space.

In most cases, your IPv6 subnet to which hosts connect will be /64 networks because networks of other sizes break some IPv6 features. What you are really concerned about are the prefixes smaller than /64 that are subnetted out to /64 networks.

2

Calculating subnets for IPv4 has an excellent Q&A here: How do you calculate the prefix, network, subnet, and host numbers?`

Subnetting for IPv6 works in exactly the same way as Ron has already pointed out - always remember that an IP address really is a 128-bit (IPv6) or a 32-bit (IPv4) number. The only difference is the human-readable notation which uses dotted decimal octets for IPv4 or colon-seperated hexadecimal 16-bit words for IPv6.

Splitting IPv6 subnets on nibble boundaries just makes it easier for us humans to handle, just like splitting IPv4 subnets on octet boundaries. Machines don't care.

0

When using reverse DNS, subnets are constrained to be on nibble boundaries because that’s how the arpa zones are structured.

  • ... only if each subnet needs to represented in a separate DNS zone. Reverse DNS works fine with non-nibble subnet boundaries but different subnets will end up in the same zone. Of course, all that depends on the DNS server at hand and that's entirely off-topic here. – Zac67 Aug 16 at 9:53
  • Sorry, newbie here. On topic I think from the theoretical standpoint because this the only actual constraint in IPv6. We all know that the whole of the address space can be sub-netted, even so so-called host identifier so why would you ever need to not use a nibble boundary? Good practice I think beyond the the top few nibbles. – Terry Horridge Aug 16 at 10:51
  • It might be off topic but I am at a loss to understand why anyone needs to use subnetting in IPv6 once you are inside a private network. – Terry Horridge Aug 16 at 11:03
  • You wouldn't want all nodes in a /48 network to live in a single subnet now, would you? – Zac67 Aug 16 at 11:45
  • Gotcha, guess that’s a bit radical then. You certainly do if you are working within the public address space. Better to keep to existing practice as long as we have dual stacks. Just hide your private addresses at boundary firewalls using NAT as we do now. – Terry Horridge Aug 16 at 12:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.