Missing tab "power ports" on devices with power ports #11082

Closed
opened 2025-12-29 21:40:00 +01:00 by adam · 14 comments
Owner

Originally created by @MatthiasKuehneEllerhold on GitHub (Apr 25, 2025).

Deployment Type

Self-hosted

NetBox Version

4.2.7 & 4.2.8

Plugins:

  • django-auth-ldap
  • netbox-attachments
  • netbox-floorplan-plugin
  • netbox-topology-views
  • netboxlabs-netbox-branching

Python Version

3.11

Steps to Reproduce

  1. Have a device with a power port
  2. Go to the devices' site
  3. Observe no "power ports" tab
  4. append /power-ports/ to the URL
  5. Power ports are there!

Expected Behavior

I expect a tab with the power port table if a device has at least one power port.

Observed Behavior

Tab "Power ports" is missing.

This was observed with 4.2.7 and 4.2.8 on SOME devices (not on others).

Neither housekeeping.sh, upgrade.sh or trace_paths --force fixed this error.

Originally created by @MatthiasKuehneEllerhold on GitHub (Apr 25, 2025). ### Deployment Type Self-hosted ### NetBox Version 4.2.7 & 4.2.8 Plugins: - django-auth-ldap - netbox-attachments - netbox-floorplan-plugin - netbox-topology-views - netboxlabs-netbox-branching ### Python Version 3.11 ### Steps to Reproduce 1. Have a device with a power port 2. Go to the devices' site 3. Observe no "power ports" tab 4. append /power-ports/ to the URL 5. Power ports are there! ### Expected Behavior I expect a tab with the power port table if a device has at least one power port. ### Observed Behavior Tab "Power ports" is missing. This was observed with 4.2.7 and 4.2.8 on SOME devices (not on others). Neither housekeeping.sh, upgrade.sh or trace_paths --force fixed this error.
adam added the netbox label 2025-12-29 21:40:00 +01:00
adam closed this issue 2025-12-29 21:40:00 +01:00
Author
Owner

@jeremystretch commented on GitHub (Apr 25, 2025):

I'm not able to reproduce this on NetBox v4.2.8.

Have a device with a power port

How did you create the device and power port?

@jeremystretch commented on GitHub (Apr 25, 2025): I'm not able to reproduce this on NetBox v4.2.8. > Have a device with a power port How did you create the device and power port?
Author
Owner

@MatthiasKuehneEllerhold commented on GitHub (Apr 26, 2025):

Ive just created device with a device type that has a power port.

Device type: https://cloud-rad.ellerhold.de/s/GjimJSGnwwBxrbc
Device: https://cloud-rad.ellerhold.de/s/43TL3wAkS4sSH8q
Manually adding /power-ports/ to the URL: https://cloud-rad.ellerhold.de/s/DooGYopp8ePityb

@MatthiasKuehneEllerhold commented on GitHub (Apr 26, 2025): Ive just created device with a device type that has a power port. Device type: https://cloud-rad.ellerhold.de/s/GjimJSGnwwBxrbc Device: https://cloud-rad.ellerhold.de/s/43TL3wAkS4sSH8q Manually adding /power-ports/ to the URL: https://cloud-rad.ellerhold.de/s/DooGYopp8ePityb
Author
Owner

@jeremystretch commented on GitHub (Apr 28, 2025):

@MatthiasKuehneEllerhold you've likely somehow assigned power ports to a device in a way that did not update its power_port_count. Try adding and removing a power port on the device to update the counter.

@jeremystretch commented on GitHub (Apr 28, 2025): @MatthiasKuehneEllerhold you've likely somehow assigned power ports to a device in a way that did not update its `power_port_count`. Try adding and removing a power port on the device to update the counter.
Author
Owner

@MatthiasKuehneEllerhold commented on GitHub (Apr 29, 2025):

Added a power port: tab is visible with a "1": https://cloud-rad.ellerhold.de/s/2LTA4kfRWNpaQZe
Removed the port again: tab is hidden again.

@MatthiasKuehneEllerhold commented on GitHub (Apr 29, 2025): Added a power port: tab is visible with a "1": https://cloud-rad.ellerhold.de/s/2LTA4kfRWNpaQZe Removed the port again: tab is hidden again.
Author
Owner

@jeremystretch commented on GitHub (Apr 29, 2025):

Sounds like it's working correctly then.

@jeremystretch commented on GitHub (Apr 29, 2025): Sounds like it's working correctly then.
Author
Owner

@MatthiasKuehneEllerhold commented on GitHub (Apr 29, 2025):

See screenshot: Tab has "Power Ports (1)", but there are two power ports in this device. Not correct afaik.

After deleting the test power port: Tab "Power Ports" is missing, but there is one connected power port in this device. Not correct afaik.

@MatthiasKuehneEllerhold commented on GitHub (Apr 29, 2025): See screenshot: Tab has "Power Ports (1)", but there are two power ports in this device. Not correct afaik. After deleting the test power port: Tab "Power Ports" is missing, but there is one connected power port in this device. Not correct afaik.
Author
Owner

@jeremystretch commented on GitHub (Apr 29, 2025):

Unfortunately without steps to reproduce the current state, we won't be able to move forward with the bug report. Please see if you're able to reproduce it on a clean installation.

@jeremystretch commented on GitHub (Apr 29, 2025): Unfortunately without steps to reproduce the current state, we won't be able to move forward with the bug report. Please see if you're able to reproduce it on a clean installation.
Author
Owner

@MatthiasKuehneEllerhold commented on GitHub (Apr 30, 2025):

Ive just renamed the correct power port "PS" to "delete_me", renamed the "test" power port to "PS", edited the cable and deleted the "delete_me" power port. Same happened again. Now the tab is invisible again, but the new & renamed power port is there.

It seems like the power_port_count is not calculated correctly, but just incremented and decremented. Is there a CLI-command to reset all these power_port_count's ? Like the trace_cable command for the cables?

@MatthiasKuehneEllerhold commented on GitHub (Apr 30, 2025): Ive just renamed the correct power port "PS" to "delete_me", renamed the "test" power port to "PS", edited the cable and deleted the "delete_me" power port. Same happened again. Now the tab is invisible again, but the new & renamed power port is there. It seems like the `power_port_count` is not calculated correctly, but just incremented and decremented. Is there a CLI-command to reset all these `power_port_count`'s ? Like the `trace_cable` command for the cables?
Author
Owner

@Chiniquy commented on GitHub (May 5, 2025):

Have you perhaps used the script that updates devices based on the Device Type? I had issues with that script breaking the count of power ports previously.

@Chiniquy commented on GitHub (May 5, 2025): Have you perhaps used the script that updates devices based on the Device Type? I had issues with that script breaking the count of power ports previously.
Author
Owner

@MatthiasKuehneEllerhold commented on GitHub (May 5, 2025):

Not that I know of... just the 5 plugins in the bug description.

@MatthiasKuehneEllerhold commented on GitHub (May 5, 2025): Not that I know of... just the 5 plugins in the bug description.
Author
Owner

@github-actions[bot] commented on GitHub (May 13, 2025):

This is a reminder that additional information is needed in order to further triage this issue. If the requested details are not provided, the issue will soon be closed automatically.

@github-actions[bot] commented on GitHub (May 13, 2025): This is a reminder that additional information is needed in order to further triage this issue. If the requested details are not provided, the issue will soon be closed automatically.
Author
Owner

@MatthiasKuehneEllerhold commented on GitHub (May 13, 2025):

This is a reminder that additional information is needed in order to further triage this issue. If the requested details are not provided, the issue will soon be closed automatically.

What informations do you require?

@MatthiasKuehneEllerhold commented on GitHub (May 13, 2025): > This is a reminder that additional information is needed in order to further triage this issue. If the requested details are not provided, the issue will soon be closed automatically. What informations do you require?
Author
Owner

@jeremystretch commented on GitHub (May 13, 2025):

Unfortunately without steps to reproduce the current state, we won't be able to move forward with the bug report. Please see if you're able to reproduce it on a clean installation.

Closing this out as reproduction steps have not been identified.

@jeremystretch commented on GitHub (May 13, 2025): > Unfortunately without steps to reproduce the current state, we won't be able to move forward with the bug report. Please see if you're able to reproduce it on a clean installation. Closing this out as reproduction steps have not been identified.
Author
Owner

@MatthiasKuehneEllerhold commented on GitHub (May 15, 2025):

Just fyi: A workaround is cloning the device and migrating all cables, ... to the clone and deleting the original after.

@MatthiasKuehneEllerhold commented on GitHub (May 15, 2025): Just fyi: A workaround is cloning the device and migrating all cables, ... to the clone and deleting the original after.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#11082