fix(snmp): fix sa_08 test failure due to outdated snmp_generator schema and missing MIB
Problem
The sa_08-VNF With VNF Indicators SNMP Robot test suite has been failing deterministically in the Jenkins daily build. Two test cases fail:
Instantiate Network ServiceGet VNF SNMP Metrics
Root cause:
level=error msg="Error generating config netsnmp"
err="error parsing yml config: yaml: unmarshal errors:
line 13: field auth not found in type main.plain"Root Cause Analysis
Since snmp_exporter v0.24.0, the auth field was removed from modules and moved to a top-level auths section. The generator.yml still used the old inline schema, causing generate_snmp Day-1 primitive to fail and the NS to reach BROKEN state.
Changes
- Migrate
generator.ymltoauthstop-level schema — fixesgenerate_snmpfailure - Add missing
HCNUM-TCMIB — required by IF-MIB for 64-bit counters - Upgrade snmpexporter runtime to v0.30.1 + add
authparam toprometheus-job-template.j2 - Upgrade
install.shto Go 1.26.4 + snmp_generator v0.30.1 - Migrate init-container seed
snmp.ymltoauths/modulesschema (was 20k-line flat pre-v0.24 config causing CrashLoopBackOff with v0.30.1 runtime)
Verification — E2E on ephemeral ETSI VM (Jenkins build #536, 2026-06-16)
NS instantiation — COMPLETED
| sa_08-test | 9a4d5185-9802-4bb8-a138-4e69d29019b6 | READY | IDLE (None) | N/A |
| 8b2d8d08 | instantiate | COMPLETED | 2026-06-16T21:26:12 |Pod status — Running 2/2, no CrashLoopBackOff
NAME READY STATUS RESTARTS AGE
eechart-0030788334-0 2/2 Running 1 9m3ssnmp.yml generated correctly by generate_snmp Day-1 primitive
# WARNING: This file was auto-generated using snmp_exporter generator
auths:
osm_auth:
community: public
security_level: noAuthNoPriv
version: 2
modules:
osm-snmp:
walk:
- 1.3.6.1.2.1.2
metrics:
- name: ifInOctets
oid: 1.3.6.1.2.1.2.2.1.10
type: counter
- name: ifMtu
oid: 1.3.6.1.2.1.2.2.1.4
type: gaugePrometheus metrics — ifInOctets and ifMtu present with real values
{"status":"success","data":{"resultType":"vector","result":[
{"metric":{"__name__":"ifInOctets","ifAlias":"VyOS-eth0","ifIndex":"2","ifName":"eth0","instance":"172.21.249.162"},"value":[1781645717,"110716"]},
{"metric":{"__name__":"ifMtu","ifAlias":"VyOS-eth0","ifIndex":"2","ifName":"eth0","instance":"172.21.249.162"},"value":[1781645446,"1500"]}
]}}All three failure points resolved and verified on ephemeral ETSI environment:
- Fix 1: snmpexporter starts without CrashLoopBackOff (seed schema migrated)
- Fix 2: NS reaches READY,
generate_snmpCOMPLETED (generator.yml schema migrated) - Fix 3:
ifInOctetsandifMtuavailable in Prometheus (auth param added to job template)
Edited by Alejandro Sanchez