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

Prefix cannot be assigned if the site is a member of a sitegroup #10104

Closed
heiko-ma opened this issue Aug 23, 2022 · 3 comments
Closed

Prefix cannot be assigned if the site is a member of a sitegroup #10104

heiko-ma opened this issue Aug 23, 2022 · 3 comments
Labels
status: revisions needed This issue requires additional information to be actionable type: bug A confirmed report of unexpected behavior in the application

Comments

@heiko-ma
Copy link

NetBox version

v3.2.9

Python version

3.10

Steps to Reproduce

  1. Create a VLAN Group (e.g. Global) with no scope filtering (should be usable everywhere)
  2. Create a VLAN and assign it to the created VLAN group
  3. Create a Prefix and assign it to any site which is a member of a sitegroup
  4. Try to assign the Prefix to the created VLAN

Expected Behavior

The VLAN group and the VLAN is selectable as the group has no filtering and should be considered "global".

Observed Behavior

The VLAN group selection returns not results and the only usable VLANs are the ones assigned directly to the site or site group.
image

The interesting thing about this is the following:
When you remove all site and site group assignments and assign the VLAN group and VLAN, the site and site group can be assigned afterwards resulting in the following constillation:
image

Is this a wanted behavior? I believe there is something wrong with the API-Request and there are to many filters so that no result is returned.

I want to provide a little context as why this is a problem:
We have some VLANs we use at every site of ours (e.g. VLAN 10). Instead of creating this vlan for every site, we'd like to create it once and assign all corresponding prefixes to it, resulting in a more structured VLAN database.

@heiko-ma heiko-ma added the type: bug A confirmed report of unexpected behavior in the application label Aug 23, 2022
@IdRatherStand
Copy link

I can't help as to whether this is a bug or not - but we currently assign both a Site + Vlan Group as per your second screenshot, if the ability to do this is removed then this would cause us some headaches (we stretch some L2 between sites and the only way to represent this is in a VLAN group AFAIK)

@DanSheps
Copy link
Member

DanSheps commented Aug 23, 2022

I would call this more of a feature request as currently this would be going against the data model where the prefix and vlan need to be in the same site (a global vlan is not in a single site and should have a prefix reflected as such, if it is really multiple vlans at different sites, it should be modelled as separate vlans) if it operated differently.

Would you be willing to re-open this as such using the feature request template (Should be specific to prefixes, I don't think there are any data model changes needed, depending on what is being done)? Otherwise, please revise your post above to elaborate on why you believe the observed behavior is flawed.

Also, I see this being tangentally related to #10054

@DanSheps DanSheps added the status: revisions needed This issue requires additional information to be actionable label Aug 23, 2022
@heiko-ma
Copy link
Author

Thank you for your response. If this isn't wanted behavior, I'll create a feature request as this could be useful for a couple of cases.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: revisions needed This issue requires additional information to be actionable type: bug A confirmed report of unexpected behavior in the application
Projects
None yet
Development

No branches or pull requests

3 participants