This section provides a sample of querying the switch stack status and system MAC address using the get method.
Operation |
XPATH |
|---|---|
get |
/device-state/user-define-info/stack-status /device-state/user-define-info/system-mac-address |
Request Example
<?xml version='1.0' encoding='UTF-8'?>
<rpc message-id="10" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<get>
<filter type="subtree">
<dev:device-state xmlns:dev="urn:huawei:params:xml:ns:yang:huawei-device">
<dev:user-define-info/>
</dev:device-state>
</filter>
</get>
</rpc>
Response Example
<?xml version='1.0' encoding='UTF-8'?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="10">
<data>
<device-state xmlns="urn:huawei:params:xml:ns:yang:huawei-device">
<user-define-info>
<stack-status>stack</stack-status>
<system-mac-address>02:00:70:be:9b:50</system-mac-address>
</user-define-info>
</device-state>
</data>
</rpc-reply>