[Discuss] IPv6 question(s)
Craig Miller
cvmiller at gmail.com
Mon Oct 16 17:40:41 PDT 2023
Hi Ron,
See inline:
On 10/16/23 16:58, BCLUG wrote:
> Craig Miller wrote on 2023-10-16 16:48:
>
>> Typically a /64 is assigned to a VPS, which will give you more IP
>> addresses than you need.
>
> I requested "a couple, or a /64, what ever is easiest for you guys",
> so I guess I got what I asked for.
Yes, they gave you what was easiest for them. Still it looks like IPv4
thinking to me.
>
> Having 5 * /112 should give me quite a few? Or just 5?
Having 5 /112s means you will have 5 blocks of 65k addresses. However,
based on your example below, it looks like they just gave you 5 addresses.
>
> When I run `ip addr show` I get:
>
> inet6 2607:5300:203:b716::1:2/112 scope global
> valid_lft forever preferred_lft forever
> inet6 2607:5300:203:b716::1:3/112 scope global
> valid_lft forever preferred_lft forever
> inet6 2607:5300:203:b716::1:4/112 scope global
> valid_lft forever preferred_lft forever
> inet6 2607:5300:203:b716::1:5/112 scope global
> valid_lft forever preferred_lft forever
> inet6 2607:5300:203:b716::1:6/112 scope global
> valid_lft forever preferred_lft forever
However, what you listed is just 5 addresses in a single /112 block,
which may be all you need.
>
> Is that somehow equivalent to a /64, being contiguous?
No, it is _far_ from the same. 5*2^16 is NOT equal to 2^64. Punch that
into a calculator and you will see the difference.
>
> Sorry, my brain isn't up to trying to calculate this myself at the
> moment...
Even the IETF (the folks who create standards for the Internet say less
than /64 allocations is a bad idea
https://www.rfc-editor.org/rfc/rfc7421#page-10
>
>
>> To answer your question, since there are 128 bits in an IPv6 address,
>> 128-112=16 or 2^16 hosts in a /112 block.
>
> That's... 65536 addresses * 5 = 327680 addresses. "!"
>
>
> And, how would I extract, say, 1 single IPv6 from
> 2607:5300:203:b716::1:6/112 -- what would that even look like?
>
> I can ping the bare 2607:5300:203:b716::1:6 from another host, which
> leads me to think it's a single IP, but I'm unclear.
Host addresses are made up of an address and a mask. You may want to
look at the last NetSIG preso for more info:
http://www.makikiweb.com/netsig/2023_09_network_basics_addressing.html
But the real problem is that because you are using IPv6 in compressed
representation, the /112 doesn't make sense. Let me expand it out for
you, and it will make more sense. In your example above:
2607:5300:203:b716::1:6/112
2607:5300:0203:b716:0000:0000:0001:0006/112
----------------------------------|
The mask takes up the first 112 bits (as indicated by the dashes above)
The remaining 16 bits or '0006' is the host portion of the address.
Addresses should be dealt with on a nibble (or 4 bit) basis in IPv6.
Giving you 5 means they haven't divided your space on nibble boundaries.
Or perhaps they have only given you 5 addresses from a single /112.
Again they are making it harder than it needs to be, and they should
just be handing out /64s (as recommended by RFC 7421).
The beauty of IPv6, is you can do fun stuff with the address, and give
them "extra" meaning. For example, I run 2 servers, one is dual stack,
and the other is IPv6 only
$ hostwww.makikiweb.com
www.makikiweb.com has address 46.235.225.189
www.makikiweb.com has address 93.93.129.174
www.makikiweb.com has IPv6 address 2a00:1098:8:78::f02
cvmiller at hala:~$ hostwww.makiki.ca
www.makiki.ca has IPv6 address 2a00:1098:8:78::f03
You can see that I have decided to use the digit "F" to indicate that
the request came into the server on IPv6 (e.g. ...:f02 and ...:f03). The
V4 requests are via a proxy (the host is IPv6-only with Mythic Beasts)
and they come in as ...:002). So it is easy to figure out if the traffic
came in from the proxy or not.
I hope this helps,
Craig...
>
>
> _______________________________________________
> Discuss mailing list
> Discuss at vlug.org
> http://vlug.org/mailman/listinfo/discuss_vlug.org
--
IPv6 is the future, the future is here
ipv6hawaii.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://vlug.org/pipermail/discuss_vlug.org/attachments/20231016/2596f51a/attachment.html>
More information about the Discuss
mailing list