This section provides a sample of querying ARP entries using the rpc method.
Operation |
XPATH |
|---|---|
rpc |
|
Item |
Data |
Description |
|---|---|---|
Maximum number of ARP entries that can be queried |
1 |
Only one ARP entry can be queried. |
IPv4 address in an ARP entry |
10.1.1.1 |
ARP entries with a specified IPv4 address 10.1.1.1 are queried. |
ARP entry query criteria |
ip-address |
ARP entries are queried based on the IPv4 address. |
<?xml version="1.0" encoding="UTF-8"?>
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="5">
<arp-entry-get xmlns="urn:huawei:params:xml:ns:yang:huawei-arp">
<get-num>1</get-num>
<destination-address>
<ip-address>10.1.1.1</ip-address>
<search-type>ip-address</search-type>
</destination-address>
</arp-entry-get>
</rpc>
Sample of successful response
<?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="10">
<arp-entry-get xmlns="urn:huawei:params:xml:ns:yang:huawei-arp">
<arp-entry-details>
<ip-address>10.1.1.1</ip-address>
<vpn-instance>1</vpn-instance>
<mac-address>d8:49:0b:94:27:ee</mac-address>
<peVid>-</peVid>
<ceVid>-</ceVid>
<forwarding-interface>GigabitEthernet0/0/1</forwarding-interface>
<forwarding-l3-interface>GigabitEthernet0/0/1</forwarding-l3-interface>
<expireTime>1199</expireTime>
<entry-type>dynamic</entry-type>
</arp-entry-details>
<has-more>false</has-more>
</arp-entry-get>
</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="15">
<arp-entry-get xmlns="urn:huawei:params:xml:ns:yang:huawei-arp">
<has-more>false</has-more>
</arp-entry-get>
</rpc-reply>