This section describes how to configure a user VLAN in a service scheme using the rpc method.
Operation |
XPATH |
|---|---|
edit-config:create |
/huawei-aaa:aaa/service-scheme |
Item |
Data |
Description |
|---|---|---|
| ID of the user VLAN configured in a service scheme | 121 | Configure user VLAN 121 in the service scheme. |
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="43a8e485-35d2-499e-895c-e2d2d5f555a8">
<edit-config>
<target>
<running/>
</target>
<error-option>rollback-on-error</error-option>
<config>
<vlans xmlns="urn:huawei:params:xml:ns:yang:huawei-vlan">
<vlan xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="merge">
<id>121</id>
</vlan>
</vlans>
<aaa xmlns="urn:huawei:params:xml:ns:yang:huawei-aaa">
<service-scheme xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="merge">
<name>lsw_serv</name>
<vsys>public</vsys>
<vlan>121</vlan>
</service-scheme>
</aaa>
</config>
</edit-config>
</rpc>
Sample of successful response
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="43a8e485-35d2-499e-895c-e2d2d5f555a8"> <ok/> </rpc-reply>
Sample of failed response
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="43a8e485-35d2-499e-895c-e2d2d5f555a8"> <rpc-error> <error-app-tag>1</error-app-tag><error-message>Service process failed.</error-message> <error-info>Error on node /huawei-aaa:aaa/service-scheme[name="lsw_serv",vsys="public"]/vlan</error-info> </rpc-error> </rpc-reply>