cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
347
Views
3
Helpful
3
Replies

C98k API call shows AP ethernet link speed as 0

0_Kiss
Level 1
Level 1

Hi all,

I am currently trying to get the Ethernet link speeds of all APs connected to a C98k Controller via REST API call.
My issue is that the link speeds which get returned always show a value of 0.

I am accessing the following module:
module: Cisco-IOS-XE-wireless-access-point-oper
+--ro access-point-oper-data
  +--ro ethernet-if-stats* [wtp-mac if-index]
  | +--ro link-speed? uint32


My method looks something like this:

def get_ethernet_stats(wlc_url
    url = wlc_url + f'/data/Cisco-IOS-XE-wireless-access-point-oper:access-point-oper-data/ethernet-if-stats'
    r = requests.get(url, verify=False, headers=WLC_HEADER, auth=WLC_AUTH)
    if r.status_code == 200:
        wlc_reply = json.loads(r.text)
        print(wlc_reply)

 

And the output for an AP looks like this:

{'Cisco-IOS-XE-wireless-access-point-oper:ethernet-if-stats': [{'wtp-mac': 'xxxxx', 'if-index': 0, 'if-name': 'GigabitEthernet0', 'rx-pkts': 18308538, 'tx-pkts': 9117891, 'oper-status': 'oper-state-up', 'rx-ucast-pkts': 17541999, 'rx-non-ucast-pkts': 766539, 'tx-ucast-pkts': 9076820, 'tx-non-ucast-pkts': 41071, 'duplex': 2, 'link-speed': 0, 'rx-total-bytes': 1846914231, 'tx-total-bytes': 3800054541, 'input-crc': 0, 'input-aborts': 0, 'input-errors': 0, 'input-frames': 0, 'input-overrun': 0, 'input-drops': 0, 'input-resource': 0, 'unknown-protocol': 0, 'runts': 0, 'giants': 0, 'throttle': 0, 'resets': 3, 'output-collision': 0, 'output-no-buffer': 0, 'output-resource': 0, 'output-underrun': 0, 'output-errors': 0, 'output-total-drops': 0}

 

I have tried this with 100+ APs and the link speed is always 0 no matter which speed the AP is actually using.
On the WLC GUI itself the speed is shown correctly.

Am I missing something here? Is this a bug?
Do you know if there is another way to get to this information via WLC REST API?

We are running Version 17.9.4, I am unable to test this on another version unfortunately.

Thanks in advance!

Best regards,
Oli

1 Accepted Solution

Accepted Solutions

0_Kiss
Level 1
Level 1

Thanks @marce1000 

It indeed seems to be a bug.
I found a way to move an AP to a 9800-CL with version 17.13 and test another call.
With this version the link speed is shown correctly (1000).

View solution in original post

3 Replies 3

marce1000
VIP
VIP

 

 - Most likely a bug as you say ; should for instance be verified against latest release ; 17.13.1 (e.g.) ; theoretically you could download and install the 9800-CL (virtual) controller with that release ,configure the controller and test with an AP ; 
                                         if all of that would be worth the  effort ....

 M.



-- Each morning when I wake up and look into the mirror I always say ' Why am I so brilliant ? '
    When the mirror will then always repond to me with ' The only thing that exceeds your brilliance is your beauty! '

0_Kiss
Level 1
Level 1

Thanks @marce1000 

It indeed seems to be a bug.
I found a way to move an AP to a 9800-CL with version 17.13 and test another call.
With this version the link speed is shown correctly (1000).

 

     - Good to know , if future upgrades would be planned , needed and or intended.

 M.



-- Each morning when I wake up and look into the mirror I always say ' Why am I so brilliant ? '
    When the mirror will then always repond to me with ' The only thing that exceeds your brilliance is your beauty! '
Review Cisco Networking for a $25 gift card