Configuring basic DHCP snooping features in a common network
About basic DHCP snooping features in a common network
Basic DHCP snooping features refer to the following features:
Enabling DHCP snooping.
Configuring DHCP snooping trusted ports.
Enabling recording client information in DHCP snooping entries.
If you enable DHCP snooping globally, DHCP snooping is enabled on all interfaces on the device.
You can also enable DHCP snooping for specific VLANs. After enabling DHCP snooping for a VLAN, you can configure the other basic DHCP snooping features in the VLAN.
Restrictions and guidelines
If the basic DHCP snooping features are configured globally, you can only use the undo form of the global configuration commands to disable the setting globally. The VLAN-specific configuration commands cannot disable the settings.
If the basic DHCP snooping features are configured in a VLAN, you can only use the undo form of the VLAN-specific configuration commands to disable the setting in the VLAN. The global configuration command cannot disable the settings.
Configuring basic DHCP snooping features globally
Step | Command | Remarks |
---|---|---|
1. Enter system view. | system-view | N/A |
2. Enable DHCP snooping. | dhcp snooping enable | By default, DHCP snooping is disabled. |
3. Enter interface view. | interface interface-type interface-number | This interface must connect to the DHCP server. |
4. Specify the port as a trusted port. | dhcp snooping trust | By default, all ports are untrusted ports after DHCP snooping is enabled. |
5. Return to system view. | quit | N/A |
6. Enter interface view. | interface interface-type interface-number | This interface must connect to the DHCP client. |
7. (Optional.) Enable the recording of DHCP snooping entries. | dhcp snooping binding record | By default, the recording of DHCP snooping entries is disabled. |
Configuring basic DHCP snooping features for VLANs
Step | Commands | Remarks |
---|---|---|
1. Enter system view. | system-view | N/A |
2. Enable DHCP snooping for VLANs. | dhcp snooping enable vlan vlan-id-list | By default, DHCP snooping is disabled for all VLANs. |
3. Enter VLAN view | vlan vlan-id | Make sure DHCP snooping is enabled for the VLAN. |
4. Configure an interface in the VLAN as a trusted port. | dhcp snooping trust interface interface-type interface-number | By default, all interfaces in the VLAN are untrusted ports. |
5. (Optional.) Enable recording of client information in DHCP snooping entries. | dhcp snooping binding record | By default, recording of client information in DHCP snooping entries is disabled. |