Skip to content

[Bug] Adding a metric with a slash(/) in the ID causes 404 errors when trying to edit the metric #530

@cullorblind

Description

@cullorblind

Just ran into this one. I didn't see any other obviously related issues.

  • What SnmpCollector version are you using? 0.13.1 commit d645bf2
  • What OS are you running snmpcollector on? Debian 11
  • What did you do? One of our techs added a metric with a slash(/) in the name, and was unable to edit that metric from the gui.
    eg. AVIAT-RF-MIB::aviatRfFreqTx-Carrier1/1
  • What was the expected result? Metrics shouldn't 404 when loading.
  • What happened instead? Received red 404 page not found alert box when clicking on metric edit button.

I was able to fix this instance by using sqlite3 to rename the metric IDs.

  • eg.
    sqlite> update snmp_metric_cfg set id="AVIAT-RF-MIB::aviatRfFreqTx-Carrier1-1" where id="AVIAT-RF-MIB::aviatRfFreqTx-Carrier1/1"
    sqlite> update measurement_field_cfg set id_metric_cfg="AVIAT-RF-MIB::aviatRfFreqTx-Carrier1-1" where id_metric_cfg="AVIAT-RF-MIB::aviatRfFreqTx-Carrier1/1";

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions