< Home

Configuring a QoS Profile

This section provides a sample of configuring a QoS profile using the edit-config method.

Table 1 Configuring a QoS profile

Operation

XPATH

edit-config

  • /huawei-qos-profile:qos-profiles/profile/name
  • /huawei-qos-profile:qos-profiles/profile/qos-para/car-para/direction
  • /huawei-qos-profile:qos-profiles/profile/qos-para/car-para/cir
  • /huawei-qos-profile:qos-profiles/profile/qos-para/car-para/cbs
  • /huawei-qos-profile:qos-profiles/profile/qos-para/car-para/pir
  • /huawei-qos-profile:qos-profiles/profile/qos-para/car-para/pbs
  • /huawei-qos-profile:qos-profiles/profile/qos-para/remark-priority/direction
  • /huawei-qos-profile:qos-profiles/profile/qos-para/remark-priority/priority-type
  • /huawei-qos-profile:qos-profiles/profile/qos-para/remark-priority/priority-value

Data Requirements

Item

Data

Description

Name of a QoS profile

test

Set the QoS profile name to test.

Direction of traffic policing

inbound

Set the direction of traffic policing to inbound.

CIR

5000

Set the CIR to 5000, in kbit/s.

CBS

10240

Set the CBS to 10240, in bytes.

PIR

6000

Set the PIR to 6000, in kbit/s.

PBS

10240

Set the PBS to 10240, in bytes.

Direction in which the priority of IP packets is re-marked

inbound

Re-mark the DSCP priority of incoming IP packets.

Type of the priority to be re-marked for packets

dscp

Re-mark the DSCP priority of IP packets.

Value of the priority to be re-marked for packets

5

Re-mark the priority of IP packets as 5.

Request Example

<?xml version='1.0' encoding='UTF-8'?>
<rpc message-id="2" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
  <edit-config>
    <target>
      <running/>
    </target>
    <config>
      <hw-qos-profile:qos-profiles xmlns:hw-qos-profile="urn:huawei:params:xml:ns:yang:huawei-qos-profile">
        <hw-qos-profile:profile>
          <hw-qos-profile:name>test</hw-qos-profile:name>
          <hw-qos-profile:qos-para>
            <hw-qos-profile:car-para>
              <hw-qos-profile:direction>inbound</hw-qos-profile:direction>
              <hw-qos-profile:cir>5000</hw-qos-profile:cir>
              <hw-qos-profile:cbs>10240</hw-qos-profile:cbs>
              <hw-qos-profile:pir>6000</hw-qos-profile:pir>
              <hw-qos-profile:pbs>10240</hw-qos-profile:pbs>
            </hw-qos-profile:car-para>
            <hw-qos-profile:remark-priority>
              <hw-qos-profile:direction>inbound</hw-qos-profile:direction>
              <hw-qos-profile:priority-type>dscp</hw-qos-profile:priority-type>
              <hw-qos-profile:priority-value>5</hw-qos-profile:priority-value>
            </hw-qos-profile:remark-priority>
          </hw-qos-profile:qos-para>
        </hw-qos-profile:profile>
      </hw-qos-profile:qos-profiles>
    </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="2">
  <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="3">
  <rpc-error>
    <error-app-tag>-1</error-app-tag>
    <error-message> The PIR value must be no less than the CIR value. </error-message>
    <error-info>Error on node /huawei-qos-profile:qos-profiles/profile[name="test"]/qos-para</error-info>
  </rpc-error>
</rpc-reply>
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic