Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix missing queues in SNMP MIB when create_only_db_buffers=true (test_snmp_queue_counters.py) #340

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/sonic_ax_impl/mibs/vendor/cisco/ciscoSwitchQosMIB.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,16 @@ def update_stats(self):
if pq_count < max_queues_half:
pq_count = max_queues_half

# Check number of priority groups (We may use this value if create_db_buffers_only removes intermediary queues eg. Ethernet0[3-4])
pg_max = 0;
buffer_parms = Namespace.dbs_get_all(self.db_conn, mibs.STATE_DB,
mibs.buffer_max_parm_table(self.oid_name_map[if_index]))
if 'max_priority_groups' in buffer_parms:
pg_max = int(buffer_parms['max_priority_groups'])

if(pq_count < pg_max):
pq_count = pg_max

for queue in if_queues:
# Get queue type and statistics
queue_sai_oid = self.port_queues_map[mibs.queue_key(if_index, queue)]
Expand Down
Loading