IPv6 EUI-64 explained

EUI-64 (Extended Unique Identifier) is a method we can use to automatically configure IPv6 host addresses. An IPv6 device will use the MAC address of its interface to generate a unique 64-bit interface ID. However, a MAC address is 48 bit and the interface ID is 64 bit. What are we going to do with the missing bits?

IPv6 MAC address vs Interface ID

Here’s what we will do to fill the missing bits:

  1. We take the MAC address and split it into two pieces.
  2. We insert “FFFE” in between the two pieces so that we have a 64 bit value.
  3. We invert the 7th bit of the interface ID.

So if my MAC address would be 1234.5678.ABCD then this is what the interface ID will become:

IPv6 EUI-64 FF FE

Above you see how we split the MAC address and put FFFE in the middle. It doesn’t include the final step which is “inverting the 7th” bit. To do this you have to convert the first two hexadecimal characters of the first byte to binary, lookup the 7th bit and invert it. This means that if it’s a 0 you need to make it a 1, and if it’s a 1 it has to become a 0.

The 7th bit represents the universal unique bit. A “built in” MAC address will always have this bit set to 0. When you change the MAC address this bit has to be set to 1. Normally people don’t change the MAC addresses of their interfaces which means that EUI-64 will change the 7th bit from 0 to 1 most of the time. Here’s what it looks like:

We're Sorry, Full Content Access is for Members Only...

If you like to keep on reading, Become a Member Now! Here is why:

  • Learn any CCNA, CCNP and CCIE R&S Topic. Explained As Simple As Possible.
  • Try for Just $1. The Best Dollar You've Ever Spent on Your Cisco Career!
  • Full Access to our 662 Lessons. More Lessons Added Every Week!
  • Content created by Rene Molenaar (CCIE #41726)

501 Sign Ups in the last 30 days

satisfaction-guaranteed
100% Satisfaction Guaranteed!
You may cancel your monthly membership at any time.
No Questions Asked!

Tags:


Forum Replies

  1. Hi Jose,

    Let’s look at an example:

    R1#show interfaces GigabitEthernet 1 | include bia
      Hardware is CSR vNIC, address is fa16.3e60.0217 (bia fa16.3e60.0217)
    

    The 7th bit is in the first two hexadecimal characters:

    fa = 1111 1010

    As you can see, the 7th bit is set to 1 here. Now let’s check the IPv6 address:

    R1#show ipv6 interface GigabitEthernet 1 | include link-local
      IPv6 is enabled, link-local address is FE80::F816:3EFF:FE60:217
    

    Let’s write down the complete uncompressed address:

    FE80:0000:0000:0000:F816:3EFF:FE60:0217

    Let’s look only at the EUI-64 part:

    F

    ... Continue reading in our forum

  2. Hi Joel,

    First of all, I wouldn’t worry too much about this too much. The bit flipping is just one minor sub-topic of all IPv6 related stuff you can expect in the exam. It’s possible that you don’t get any questions about it so don’t stress about it too much. You can expect a lot of regular subnetting questions so that’s why I highly recommend a “cheat sheet” for that.

    It seems this list would work. It might be a quick method if you’d get 10 bit flipping questions but if you only would get 1 question, it might be just as fast to quickly calculate it?

    hex > bina

    ... Continue reading in our forum

  3. Hello Nadav

    This is an excellent question. According to RFC 5375 in section B.2.4 EUI-64 ‘u’ and ‘g’ Bits, it states the following:

    When using subnet prefix lengths other than /64, the interface
    identifier cannot be in Modified EUI-64 format as required by
    [RFC4291]. However, nodes not aware that a prefix length other than
    /64 is used might still think it’s an EUI-64; therefore, it’s prudent
    to take into account the following points when setting the bits.

    The document continues to state several considerations that should be checked carefully. In general, d

    ... Continue reading in our forum

  4. Ok, thanks, now it comes in a new light. Or rather just ‘in light’ :slight_smile: . We simply have to flip the bit because IPV6 ‘thinks’ the 1 better than 0 identifies the address as unique. Thank you.

  5. Thanks Laz - as I learn about global unicast and link local I guess this will throw up more questions!

16 more replies! Ask a question or join the discussion by visiting our Community Forum