< Home

Configuring the IP Address of a Specified Interface as the Source IP Address Used by the Device to Communicate with the Portal Server

This section provides a sample of configuring the IP address of a specified interface as the source IP address used by the device to communicate with the Portal server using the merge method.

Table 1 Configuring the IP address of a specified interface as the source IP address used by the device to communicate with the Portal server

Operation

XPATH

edit-config:merge

/huawei-aaa-portal:portal/portal-server/source-ip-address/interface/loopback-interface

Data Requirements

Table 2 Configuring the IP address of a specified interface as the source IP address used by the device to communicate with the Portal server

Item

Data

Description

name

huawei

Configure the Portal server template named huawei.

loopback-interface

loopback1

Set the interface number to loopback1.

Request Example

<?xml version='1.0' encoding='UTF-8'?>
<rpc message-id="0" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
  <edit-config>
    <target>
      <running/>
    </target>
    <config>
      <hw-aaa-portal:portal xmlns:hw-aaa-portal="urn:huawei:params:xml:ns:yang:huawei-aaa-portal">
        <hw-aaa-portal:portal-server>
          <hw-aaa-portal:name>huawei</hw-aaa-portal:name>
          <hw-aaa-portal:loopback-interface>loopback1</hw-aaa-portal:loopback-interface>
        </hw-aaa-portal:portal-server>
      </hw-aaa-portal:portal>
    </config>
  </edit-config>
</rpc>

Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="0">
 <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="20">
  <rpc-error>
    <error-type>application</error-type>
    <error-tag>invalid-value</error-tag>
    <error-severity>error</error-severity>
    <error-path>/huawei-aaa-portal:portal/portal-server[name='huawei']/loopback-interface</error-path>
    <error-message>validation failed(Leafref "/ietf-interfaces:interfaces/ietf-interfaces:interface/ietf-interfaces:name" of value "loopback100" points to a non-existing leaf.).</error-message>
  </rpc-error>
</rpc-reply>
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >