After Option 82 field insertion is enabled on a device, the device can record the location information of the DHCP client or create binding entries with accurate interface information based on the Option 82 information.
The Option 82 field contains the location information of Dynamic Host Configuration Protocol (DHCP) hosts, such as information about the login interface, virtual local area network (VLAN), and address. After DHCP snooping is configured, the device can create binding entries with accurate interface information based on the Option 82 field. In addition, the DHCP server that supports the Option 82 field can allocate different IP policies to different clients based on the Option 82 information. This provides more flexible address allocation modes.
The system view is displayed.
The VLAN view is displayed.
Run dhcp option82 insert enable [ interface interface-type interface-number ] or dhcp option82 rebuild enable [ interface interface-type interface-number ]
Option 82 field insertion is enabled.
Run quit
Return to the system view.
(Optional) Run dhcp option82 inner-vlan insert enable
Option 82 information is encapsulated into the inner and outer VLAN IDs of a double-tagged user packet.
When users go online from a Layer 2 interface or a VLANIF interface and device interworking and upgrade exist, run the dhcp option82 inner-vlan insert enable command to prevent user online failures caused by inconsistency between Option 82 information in the inner and outer VLAN IDs of a double-tagged user packet.
The configuration is committed.
The system view is displayed.
The BD view is displayed.
Run dhcp option82 insert enable
Option 82 field insertion is enabled.
The configuration is committed.
The system view is displayed.
The interface view is displayed.
Run dhcp option82 insert enable or dhcp option82 rebuild enable
Option 82 field insertion is enabled.
The function of inserting sub-option 5 into Option 82 is enabled.
An IP address corresponding to sub-option 5 in Option 82 is configured.
The device is enabled to insert Option 82's sub-option 9 into a DHCP packet.
A format is configured for Option 82's sub-option 9 carried in a DHCP packet.
Run quit
Return to the system view.
(Optional) Run dhcp option82 inner-vlan insert enable
Option 82 information is encapsulated into the inner and outer VLAN IDs of a double-tagged user packet.
When users go online from a Layer 2 interface or a VLANIF interface and device interworking and upgrade exist, run the dhcp option82 inner-vlan insert enable command to prevent user online failures caused by inconsistency between Option 82 information in the inner and outer VLAN IDs of a double-tagged user packet.
The configuration is committed.
After Option 82 field insertion is enabled, you can configure the format of the Option 82 field as required.
The system view is displayed.
The VLAN view is displayed.
Run dhcp option82 format { user-defined text | type1 | type2 | self-define self-define | cn-telecom | cn-telecom-inherit } interface interface-type interface-number
The format of the Option 82 field is configured for the VLAN.
The configuration is committed.
The system view is displayed.
The interface view is displayed.
Run dhcp option82 format { self-define extendtext | type1 | type2 | cn-telecom | cn-telecom-inherit } or dhcp option82 { circuit-id | remote-id } format self-define extendtext or dhcp option82 [ circuit-id | remote-id ] format user-defined text
The format of the Option 82 field is configured.
The configuration is committed.