This section provides a sample of changing the stack ID and priority of a stack member using the config method.
Operation |
XPATH |
|---|---|
edit-config:config |
/huawei-stack/set-stack-configuration/stackid /huawei-stack/set-stack-configuration/next-stackid /huawei-stack/set-stack-configuration/next-priority |
Data Requirements
Item |
Data |
Description |
|---|---|---|
Existing stack ID of a stack member |
0 |
- |
New stack ID of the stack member |
1 |
- |
Stack priority of the stack member |
100 |
- |
Request Example
<?xml version="1.0" encoding="UTF-8"?>
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="8">
<hw-stack:set-stack-configuration xmlns:hw-stack="urn:huawei:params:xml:ns:yang:huawei-stack">
<hw-stack:stackid>0</hw-stack:stackid>
<hw-stack:next-stackid>1</hw-stack:next-stackid>
<hw-stack:next-priority>100</hw-stack:next-priority>
</hw-stack:set-stack-configuration>
</rpc>
Response Example
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="8"> <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="8">
<rpc-error xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<error-type>application</error-type>
<error-tag>operation-failed</error-tag>
<error-severity>error</error-severity>
<error-app-tag>1</error-app-tag>
<error-path/>
<error-message>handle stack board newid failed.</error-message>
</rpc-error>
</rpc-reply>