Skip to content

/32 IP's not automatically represented in /32 subnet. #6632

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

Closed
darcynz opened this issue Jun 20, 2021 · 5 comments · Fixed by #6790
Closed

/32 IP's not automatically represented in /32 subnet. #6632

darcynz opened this issue Jun 20, 2021 · 5 comments · Fixed by #6790
Assignees
Labels
status: accepted This issue has been accepted for implementation type: feature Introduction of new functionality to the application

Comments

@darcynz
Copy link

darcynz commented Jun 20, 2021

NetBox version

v2.11.7

Python version

3.7

Steps to Reproduce

  1. Have a /32 IP address,

  2. Create a /32 Subnet for that IP address

  3. In the new subnet on the IP addresses tab observe IP's.

Expected Behavior

IP address reference should be observed and not the ability to assign an IP address in the subnet.

Observed Behavior

'Available IP' Button is present instead of a reference to the IP address as per 1).

@darcynz darcynz added the type: bug A confirmed report of unexpected behavior in the application label Jun 20, 2021
@jeremystretch jeremystretch added status: under review Further discussion is needed to determine this issue's scope and/or implementation and removed type: bug A confirmed report of unexpected behavior in the application labels Jun 21, 2021
@jeremystretch
Copy link
Member

Why shouldn't a user be able to create a /32 IP address for assignment to an interface in addition to a /32 route to advertise that address?

@WillIrvine
Copy link
Contributor

I think the issue here is that the /32 IP address gets created in the /32 subnet, but then does not display when navigating back to the Subnet

Example:

  1. Make /32 Prefix

image

  1. Make /32 IP address within that prefix

image

  1. Go back to parent prefix, newly created IP address does not display under /32 prefixes IP address's, however IP address has been created.

image

@darcynz
Copy link
Author

darcynz commented Jun 21, 2021

Sorry I should have included pictures. We have no issue with duplicate /32's just that they are not displaying within a subnet as per WillIrvine's images above.

@WillIrvine
Copy link
Contributor

Hi

#6455 (comment)

This solution seems to work and AFAIA does not look to cause any undesired issues.
This looks to however be more of a design question as expressed by Jeremy - Should a /32 Prefix contain a /32 IP.

I think it should as people are using IP's and Prefix's for separate purposes, and it maintains a familiar workflow to track both individually. But if not we should at least limit the UI from displaying that there is 1 available address within the prefix.

Happy to put in a PR for this if accepted.

@stevenmyhre
Copy link

I also ran into this. We are using prefixes to document NAT translations (even though netbox doesn't support it specifically), and, it's perfectly valid to have a 1-1 nat with a /32 prefix, i.e. 1-1 NAT. However, the single IP Address in the prefix gets lost the way it is coded currently.

WillIrvine pushed a commit to WillIrvine/netbox that referenced this issue Jul 22, 2021
@jeremystretch jeremystretch added status: accepted This issue has been accepted for implementation type: feature Introduction of new functionality to the application and removed status: under review Further discussion is needed to determine this issue's scope and/or implementation labels Aug 20, 2021
jeremystretch added a commit that referenced this issue Aug 20, 2021
Fixes #6632  - Allow a /32 prefix to contain a /32 ipaddress
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: accepted This issue has been accepted for implementation type: feature Introduction of new functionality to the application
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants