< Home

Changing the Management VLAN

This section describes how to change the management VLAN using the rpc method.

Table 1 Changing the management VLAN

Operation

XPATH

rpc

/huawei-vlan:vlans/management-vlan/vlanid

Data requirement

Table 2 Changing the management VLAN

Item

Data

Description

VLAN ID

100

Changes the management VLAN to VLAN 100.

Request example

<?xml version='1.0' encoding='UTF-8'?>
<rpc message-id="17" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
    <edit-config>
        <target>
            <running/>
        </target>
        <config>
            <huawei-vlan:vlans xmlns:huawei-vlan="urn:huawei:params:xml:ns:yang:huawei-vlan">
                <huawei-vlan:vlan>
                    <huawei-vlan:id>100</huawei-vlan:id>
                </huawei-vlan:vlan>
                <huawei-vlan:management-vlan>
                    <huawei-vlan:vlanid>100</huawei-vlan:vlanid>
                </huawei-vlan:management-vlan>
            </huawei-vlan:vlans>
        </config>
    </edit-config>
</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="17">
    <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="18">
    <rpc-error>
        <error-type>application</error-type>
        <error-tag>operation-failed</error-tag>
        <error-severity>error</error-severity>
        <error-message>parse rpc config error.</error-message>
    </rpc-error>
</rpc-reply>
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >