Changing module bay to existing module doesn't update module's component. #9253

Closed
opened 2025-12-29 20:47:31 +01:00 by adam · 2 comments
Owner

Originally created by @francesco-noc on GitHub (Feb 15, 2024).

Deployment Type

Self-hosted

NetBox Version

v.3.7.0

Python Version

3.11

Steps to Reproduce

  1. Create a device based on a device type having module bays (es ProCurve 5304xl)
  2. Create a module with components whose names depend on the module bay (es. HP 4-Port 10GbE CX4 ZL) assigned to the previously created device.
  3. Edit the module by changing the module bay.

Expected Behavior

Module components are renamed according to new module bay.
es.
Changing slot A to slot B
Interface A1 becomes B1

Observed Behavior

Module components do not change name.
es.
Changing slot A to slot B
Interface A1 remains A1

Originally created by @francesco-noc on GitHub (Feb 15, 2024). ### Deployment Type Self-hosted ### NetBox Version v.3.7.0 ### Python Version 3.11 ### Steps to Reproduce 1. Create a device based on a device type having module bays (es [ProCurve 5304xl](https://github.com/netbox-community/devicetype-library/blob/master/device-types/HPE/ProCurve-5304xl.yaml)) 2. Create a module with components whose names depend on the module bay (es. [HP 4-Port 10GbE CX4 ZL](https://github.com/netbox-community/devicetype-library/blob/master/module-types/HPE/J8708A.yaml)) assigned to the previously created device. 3. Edit the module by changing the module bay. ### Expected Behavior Module components are renamed according to new module bay. _es. Changing slot A to slot B Interface A1 becomes B1_ ### Observed Behavior Module components do not change name. _es. Changing slot A to slot B Interface A1 remains A1_
adam closed this issue 2025-12-29 20:47:31 +01:00
Author
Owner

@francesco-noc commented on GitHub (Feb 16, 2024):

I was working on this feature because we have to manage about 3,000 devices with more than 2,000 modules and therefore we desperately need it.

This is my implementation that fix this issue's behaviour and also the proposed feature.

@francesco-noc commented on GitHub (Feb 16, 2024): I was working on [this feature](https://github.com/netbox-community/netbox/issues/13779) because we have to manage about 3,000 devices with more than 2,000 modules and therefore we desperately need it. [This](https://github.com/netbox-community/netbox/compare/develop...francesco-noc:netbox:13779-change-device-to-module) is my implementation that fix this issue's behaviour and also the proposed feature.
Author
Owner

@jeremystretch commented on GitHub (Feb 20, 2024):

Module components do not change name

Of course they don't; there is no mechanism in place to enable this. The name template defined for the component type is available only when creating a new component. There is no logic in place to facilitate modifying the name of an existing component. You're welcome to submit a feature request if you'd like to propose a detailed, feasible implementation.

@jeremystretch commented on GitHub (Feb 20, 2024): > Module components do not change name Of course they don't; there is no mechanism in place to enable this. The name template defined for the component _type_ is available only when creating a new component. There is no logic in place to facilitate modifying the name of an existing component. You're welcome to submit a [feature request](https://github.com/netbox-community/netbox/issues/new?assignees=&labels=type%3A+feature&projects=&template=feature_request.yaml) if you'd like to propose a detailed, feasible implementation.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#9253