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

get_port_stats_by_port_hostname returns deleted port #5131

Closed
davehope opened this Issue Dec 7, 2016 · 1 comment

Comments

Projects
None yet
2 participants
@davehope
Copy link
Contributor

davehope commented Dec 7, 2016

DO NOT DELETE THIS INFORMATION.

Please read this information carefully.

GitHub issues is for feature requests or bugs, please do not post issues asking for help or how to do X, Y or Z.
You can use our irc channel ##librenms on freenode to ask questions or our community site.

  • Is your install up to date? Updating your install
    Please do not submit an issue if your install is not up to date within the last 24 hours or on a stable monthly release.
  • Please include all of the information between the ==================================== section of ./validate.php.
  • If you would like us to add a new device then please provide the information asked for here
  • Please provide as much detail as possible.
Component Version
LibreNMS 28e35ef
DB Schema 151
PHP 5.6.27-0+deb8u1
MySQL 10.0.28-MariaDB-0+deb8u1
RRDTool 1.4.8
SNMP NET-SNMP 5.7.2.1

When using the get_port_stats_by_port_hostname through curl, a deleted port is returned rather than the active (non ignored,disabled,deleted) port.

curl -H 'X-Auth-Token: x' http://x/api/v0/devices/x/ports/ppp0 | grep _id

   "port_id": "171",
   "device_id": "14",

Checking the corresponding list of ports for the device via the web interface (http://monitoringHost/ports) and selected "deleted" shows 15 deleted ports with the same device/name.

I would expect the port that is not deleted to be returned rather than the port with the lowest port_id.

@laf laf added API Bug 🐞 labels Dec 7, 2016

laf added a commit that referenced this issue Dec 8, 2016

@davehope

This comment has been minimized.

Copy link
Contributor Author

davehope commented Dec 8, 2016

Closed by #5137

@davehope davehope closed this Dec 8, 2016

VimCommando added a commit to VimCommando/librenms that referenced this issue Jan 4, 2017

@lock lock bot locked as resolved and limited conversation to collaborators May 18, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.