This program implements methods provided by the `qos` object on U-Bus. This is done by calling `libqos` provided by `easy-soc-libs`.
This program implements methods provided by the `qos` object on U-Bus. This is done by calling `libqos` provided by `easy-soc-libs`.
...
@@ -7,7 +6,7 @@ This program implements methods provided by the `qos` object on U-Bus. This is d
...
@@ -7,7 +6,7 @@ This program implements methods provided by the `qos` object on U-Bus. This is d
qosmngr requires a configuration file provide objects over ubus. The configuration file is an uci file `/etc/config/qos`. Sample configuration file is provided below.
qosmngr requires a configuration file provide objects over ubus. The configuration file is an uci file `/etc/config/qos`. Sample configuration file is provided below.
````bash
```
config queue 'q_0_eth1'
config queue 'q_0_eth1'
option enable '1'
option enable '1'
option ifname 'eth1'
option ifname 'eth1'
...
@@ -413,27 +412,27 @@ config policer
...
@@ -413,27 +412,27 @@ config policer
option meter_type '0'
option meter_type '0'
option name 'cfg2b6c73'
option name 'cfg2b6c73'
````
```
## Ubus API
## uBus API
`ubusd` has to be running all time, as it exposes the qos functionality over ubus. By default,qosmngr registers below namespace with ubus.
`ubusd` has to be running all time, as it exposes the qos functionality over ubus. By default,qosmngr registers below namespace with ubus.
-`ifname`: interface name for which we want to get the QoS statistics. Optional argument: if not provided, the statistics of all ports for all queues are returned.
-`ifname`: interface name for which we want to get the QoS statistics. Optional argument: if not provided, the statistics of all ports for all queues are returned.
-`qid`: the TX queue ID for which we want to get the statistics. Optional argument: if not provided, the statistics of all queues for a given interface are returned.
-`qid`: the TX queue ID for which we want to get the statistics. Optional argument: if not provided, the statistics of all queues for a given interface are returned.
The response given by this method is a JSON-formatted dump as such:
The response given by this method is a JSON-formatted dump as such: