This section provides a sample of configuring the device to automatically generate the DHCP snooping binding table for static IP users using the merge method.
Operation |
XPATH |
|---|---|
edit-config:merge |
/huawei-nac-dot1x:dot1x-access/configure-mode/unified-mode/dot1x-access-profile/dhcp-binding |
Item |
Data |
Description |
|---|---|---|
name |
d1 |
Configure the 802.1X access profile named d1. |
dhcp-binding |
true |
Configure the device to automatically generate the DHCP snooping binding table for static IP users. |
<?xml version='1.0' encoding='UTF-8'?>
<rpc message-id="0" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<edit-config>
<target>
<running/>
</target>
<config>
<hw-nac-dot1x:dot1x-access xmlns:hw-nac-dot1x="urn:huawei:params:xml:ns:yang:huawei-nac-dot1x">
<hw-nac-dot1x:dot1x-access-profile>
<hw-nac-dot1x:name>d1</hw-nac-dot1x:name>
<hw-nac-dot1x:dhcp-binding>true</hw-nac-dot1x:dhcp-binding>
</hw-nac-dot1x:dot1x-access-profile>
</hw-nac-dot1x:dot1x-access>
</config>
</edit-config>
</rpc>
Sample of successful response
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="0"> <ok/> </rpc-reply>
Sample of failed response
<?xml version='1.0' encoding='UTF-8'?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="12">
<rpc-error>
<error-type>application</error-type>
<error-tag>operation-failed</error-tag>
<error-severity>error</error-severity>
<error-path>/huawei-nac-dot1x:dot1x-access/dot1x-access-profile[name='d1']/dhcp-binding</error-path>
<error-message>parse rpc config error.(Invalid value "1" in "dhcp-binding" element.).</error-message>
</rpc-error>
</rpc-reply>