UnixSage

IPv6 Notes

Layout

         ---- Network        ---- Host
         |                   |
         |                   |
/-----------------\ /-----------------\
2001:0DB8:0000:0000:0000:0000:0000:0000
\-------/ \--/ \--/
    |      |    |
    |      |    --------------- Site Subnetting /64 (16 bits)
    |      |
    |      -------------------- ISP -> Site /48 (16 bits)
    |
    --------------------------- RIR -> ISP /32 (32 bits)

Short Hand

So an IPv6 address is 8 “hextets” In a hextet leading 0s can be dropped so:
2001:0db8:e01b:fe00:0000:0000:0000:0001

Can be shortened to:
2001:db8:e01b:fe00:0:0:0:1

If you have multiple “zero” hextets together they can be additionally shortened to “::” BUT only ONCE per address (since it would be impossible to extract how many were in each)

So 2001:db8:e01b:fe00:0:0:0:1
Becomes 2001:db8:e01b:fe00::1

Two Examples:

  • 2001:0db8:e01b:fe00:0000:0000:0000:0001 -> 2001:db8:e01b:fe00::1
  • 2001:0db8:e01b:fe00:0000:0000:0001:0001 -> 2001:db8:e01b:fe00::1:1