"IndexError: list index out of range" on Dell c6400

Bug #1771527 reported by Ante Karamatić
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Neutron Open vSwitch Charm
Fix Released
Undecided
Ante Karamatić

Bug Description

https://github.com/openstack/charm-neutron-openvswitch/blob/master/hooks/neutron_ovs_context.py#L272-L284

The code above expects "cpulist" to be a string of comma separated, dashed CPU ranges. It splits the string into a list at each comma, then iterates through that list of strings again, splitting on the dash symbol. This works fine for CPUs ordered this way..

root@standard:~# cat /sys/devices/system/node/node*/cpulist
0-13,28-41
14-27,42-55

but this throws a type error...

"IndexError: list index out of range"

for CPUs ordered as below because there is no dash symbol to split on....

root@dellc6400:~# cat /sys/devices/system/node/node*/cpulist
0,4,8,12,16,20,24,28,32,36,40,44,48,52
1,5,9,13,17,21,25,29,33,37,41,45,49,53
2,6,10,14,18,22,26,30,34,38,42,46,50,54
3,7,11,15,19,23,27,31,35,39,43,47,51,55

Tags: cpe-onsite
Ante Karamatić (ivoks)
Changed in charm-neutron-openvswitch:
assignee: nobody → Ante Karamatić (ivoks)
tags: added: cpe-onsite
Changed in charm-neutron-openvswitch:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to charm-neutron-openvswitch (master)

Fix proposed to branch: master
Review: https://review.openstack.org/568786

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-neutron-openvswitch (master)

Reviewed: https://review.openstack.org/568786
Committed: https://git.openstack.org/cgit/openstack/charm-neutron-openvswitch/commit/?id=54449e783db89a1ba83a1fa47b9a7ef34756de46
Submitter: Zuul
Branch: master

commit 54449e783db89a1ba83a1fa47b9a7ef34756de46
Author: Ante Karamatic <email address hidden>
Date: Wed May 16 10:45:52 2018 +0200

    Cover more NUMA CPU list types

    In some cases cpulist doesn't contain '-' and lists all
    cores one by one. For this kind of lists, splitting by
    comma will break parse_cpu_list().

    Change-Id: Icc5fcf6408d76fdef34ccb18657624cfe5593f10
    Closes-Bug: #1771527

Changed in charm-neutron-openvswitch:
status: In Progress → Fix Committed
James Page (james-page)
Changed in charm-neutron-openvswitch:
milestone: none → 18.05
David Ames (thedac)
Changed in charm-neutron-openvswitch:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.