Description

The current address and hardware address of management interfaces for Juniper Networks EX/QFX Series Switches, 'fresh out-of-the-box' chassis are always different. This should be a consideration for ZTP because the ZTP process is based on DHCP and the ZTP/ DHCP server needs the MAC address of the chassis to be provisioned.

Symptoms

When EX/QFX switches are fresh out of the box or after being zeroized, the management interface current MAC address and the hardware MAC are always different.

The following command shows the MAC addresses of an em0 interface for a zeroized or a new EX/QFX chassis:

root@QFX5200> show interfaces extensive em0 | match Hardware 
  Current address: e8:b6:c2:84:ae:81, Hardware address: e8:b6:c2:84:b3:78

This ' current address ' is same as the MAC of VME interface, and different from the ' Hardware address '.

The following command shows the MAC addresses of the VME interface for the same zeroized chassis. The 'Hardware address' is the same as the 'Current address':

root@QFX5200> show interfaces extensive vme | match Hardware 
  Current address: e8:b6:c2:84:ae:81, Hardware address: e8:b6:c2:84:ae:81

Solution

By default, management interfaces have no configuration while the VME interfaces do.  The em0 interface will change the MAC address once it is configured with any information, such as IP/description etc.

{master:0}
root> show configuration interfaces em0

{master:0}
root> show configuration interfaces
vme
unit 0 {
family inet {
dhcp {
vendor-id Juniper:qfx5100-96s-8q:VB3715300242;
}
}

family inet6 {
dhcpv6-client {
client-type stateful;
client-ia-type ia-na;
client-identifier duid-type duid-ll;
vendor-id Juniper:qfx5100-96s-8q:VB3715300242;
}
}
}

As soon as configuration is added to em0, the current hardware address becomes the same as its own hardware address.

root@switch# set interfaces em0.0 family inet address 192.168.0.1/24
root@switch# commit

root@switch# run show interfaces extensive em0 | match Hard
Current address: e8:b6:c2:84:b3:78, Hardware address: e8:b6:c2:84:b3:78

This can be verified by running a 'monitor traffic interface' on em0 (or me0) interface on a zeroized system and comparing it with a 'monitor traffic interface' when em0 (or me0) has some configuration:

Example output of 'monitor traffic interface' when an EX switch was zeroized:

      root@switch> monitor traffic interface me0 no-resolve size 500
      17:13:46.483349 IP 0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from e8:b6:c2:84:ae:81 (oui Unknown), length 298


The above example shows that the ZTP (DHCP) packets that are being originated by em0 have the source MAC of VME interface. This was taken when there is no configuration on me0 as of now. Then me0 interface was configured with just dhcp vendor-id. (The behavior will be the same irrespective of config, for example, users can add IPV4 address of only the description and still see the same behavior.)
 

root@switch# set interface me0.0 family inet dhcp vendor-id TEST
root@switch# commit
           
root@switch> monitor traffic interface me0 no-resolve size 500

17:15:47.483349 IP 0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from e8:b6:c2:84:b3:78 (oui Unknown), length 298


The same interface is now using its own hardware address for DHCP.
 

This behavior is by design because Juniper L2 platforms support Virtual chassis.  This should be factored in while using ZTP for provisioning.  It is recommended to use a VME MAC address for ZTP if the management port is used.

Modification History

08/29/2022 - Updated IPs, article is still valid and relevant.