Port list causing exception and result in empty list

Running port list - https://librenms.url/ports/state=down, release version 21.10.2, with state “down” or “All states” causing in log exception for me and results in “no results found” in web ui. Exception:

[2021-10-24 17:52:56] production.ERROR: Trying to get property 'os' of non-object 
{"userId":8,"exception":"[object] (ErrorException(code: 0): Trying to get property 'os' of non-object at /opt/librenms/app/Models/Port.php:64)

I think there is some problem port causing this, but probably list function need some fail safe condition to get past such ports and list them somehow for admin to take proper action?

Purge deleted ports in the meantime. Not sure why they are still there after the device has been deleted.

That was my first idea also, im purging all deleted ports then enter ports list and still state down ports cause exception. Maybe something left in ports table, but i cant figure how to catch problematic port.

Found orphaned ports with left join from devices and then deleted all where hostname is empty and all states works fine again.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.