Increase "name" field maxmimum length from 50 characters #709

Closed
opened 2025-12-29 16:24:59 +01:00 by adam · 9 comments
Owner

Originally created by @InsaneSplash on GitHub (Feb 14, 2017).

The current limit for characters in the name of a tenant,site,rack, device is set to a maximum of 50 characters. Can this be increased to say 100?

Example Import:

Record 11 (name): Ensure this value has at most 50 characters (it has 58).
Record 12 (name): Ensure this value has at most 50 characters (it has 55).
Record 13 (name): Ensure this value has at most 50 characters (it has 60).
Record 14 (name): Ensure this value has at most 50 characters (it has 59).
Record 15 (name): Ensure this value has at most 50 characters (it has 59).
Record 16 (name): Ensure this value has at most 50 characters (it has 51).
Record 17 (name): Ensure this value has at most 50 characters (it has 56).
Record 18 (name): Ensure this value has at most 50 characters (it has 53).
Record 19 (name): Ensure this value has at most 50 characters (it has 55).
Record 20 (name): Ensure this value has at most 50 characters (it has 52).
Record 21 (name): Ensure this value has at most 50 characters (it has 58).
Record 22 (name): Ensure this value has at most 50 characters (it has 58).
Record 23 (name): Ensure this value has at most 50 characters (it has 56).
Record 25 (name): Ensure this value has at most 50 characters (it has 61).
Record 26 (name): Ensure this value has at most 50 characters (it has 59).
Record 28 (name): Ensure this value has at most 50 characters (it has 58).
Record 29 (name): Ensure this value has at most 50 characters (it has 52).
Record 30 (name): Ensure this value has at most 50 characters (it has 55).
Record 31 (name): Ensure this value has at most 50 characters (it has 57).
Record 32 (name): Ensure this value has at most 50 characters (it has 52).
Originally created by @InsaneSplash on GitHub (Feb 14, 2017). The current limit for characters in the name of a tenant,site,rack, device is set to a maximum of 50 characters. Can this be increased to say 100? Example Import: ``` Record 11 (name): Ensure this value has at most 50 characters (it has 58). Record 12 (name): Ensure this value has at most 50 characters (it has 55). Record 13 (name): Ensure this value has at most 50 characters (it has 60). Record 14 (name): Ensure this value has at most 50 characters (it has 59). Record 15 (name): Ensure this value has at most 50 characters (it has 59). Record 16 (name): Ensure this value has at most 50 characters (it has 51). Record 17 (name): Ensure this value has at most 50 characters (it has 56). Record 18 (name): Ensure this value has at most 50 characters (it has 53). Record 19 (name): Ensure this value has at most 50 characters (it has 55). Record 20 (name): Ensure this value has at most 50 characters (it has 52). Record 21 (name): Ensure this value has at most 50 characters (it has 58). Record 22 (name): Ensure this value has at most 50 characters (it has 58). Record 23 (name): Ensure this value has at most 50 characters (it has 56). Record 25 (name): Ensure this value has at most 50 characters (it has 61). Record 26 (name): Ensure this value has at most 50 characters (it has 59). Record 28 (name): Ensure this value has at most 50 characters (it has 58). Record 29 (name): Ensure this value has at most 50 characters (it has 52). Record 30 (name): Ensure this value has at most 50 characters (it has 55). Record 31 (name): Ensure this value has at most 50 characters (it has 57). Record 32 (name): Ensure this value has at most 50 characters (it has 52). ```
adam added the type: feature label 2025-12-29 16:24:59 +01:00
adam closed this issue 2025-12-29 16:24:59 +01:00
Author
Owner

@jeremystretch commented on GitHub (Feb 15, 2017):

Can you provide an example of a name that's too long? I'm curious.

@jeremystretch commented on GitHub (Feb 15, 2017): Can you provide an example of a name that's too long? I'm curious.
Author
Owner

@InsaneSplash commented on GitHub (Feb 16, 2017):

As an example, we chose to make use of a router hostname that contains identifying information. Due to the vast number of devices, sites and tenants we have, it helps locate the device across databases, monitoring and the like. Below is an example CPE hostname that we may use.

Example:
CUSTCODE-BUSINESSUNIT-BRANCHCODE-CPETYPE-LOCATION

As you can imagine this can quite easily become a name larger than 50 characters. Just the above vanilla example is 49 characters.

We are in the process of importing all our disparate technical information (1st Tier ISP) in to Netbox and have so far over 3500+ sites, 1500+ tenants which is easily expected to double once we get closer to completing the import. Each site could have more than 10 devices at times.

Great product btw!

@InsaneSplash commented on GitHub (Feb 16, 2017): As an example, we chose to make use of a router hostname that contains identifying information. Due to the vast number of devices, sites and tenants we have, it helps locate the device across databases, monitoring and the like. Below is an example CPE hostname that we may use. Example: CUSTCODE-BUSINESSUNIT-BRANCHCODE-CPETYPE-LOCATION As you can imagine this can quite easily become a name larger than 50 characters. Just the above vanilla example is 49 characters. We are in the process of importing all our disparate technical information (1st Tier ISP) in to Netbox and have so far over 3500+ sites, 1500+ tenants which is easily expected to double once we get closer to completing the import. Each site could have more than 10 devices at times. Great product btw!
Author
Owner

@rlaneyjr commented on GitHub (Feb 23, 2017):

I see this problem all too often. Why do we need that much information from one name? All of the info can be easily gathered by digging just a little deeper. We have gotten so lazy, we expect to look at one name and identify location, business unit, site, building, floor, closet, cage, rack, serial number, IP address, MAC address, fqdn,... Sorry, I got carried away. I needed to vent.

@rlaneyjr commented on GitHub (Feb 23, 2017): I see this problem all too often. Why do we need that much information from one name? All of the info can be easily gathered by digging just a little deeper. We have gotten so lazy, we expect to look at one name and identify location, business unit, site, building, floor, closet, cage, rack, serial number, IP address, MAC address, fqdn,... Sorry, I got carried away. I needed to vent.
Author
Owner

@th3goose commented on GitHub (Feb 28, 2017):

I've personally not had this problem as we've always kept identifying information on interface descriptions or in the snmp sections on configs, but this shouldn't really be a problem to change can it? I can't come up with any dependencies that would break and would give the greater community more flexibility. I can see some old-school phone companies who use a CLEI code struggling with the character limit as well.

@th3goose commented on GitHub (Feb 28, 2017): I've personally not had this problem as we've always kept identifying information on interface descriptions or in the snmp sections on configs, but this shouldn't really be a problem to change can it? I can't come up with any dependencies that would break and would give the greater community more flexibility. I can see some old-school phone companies who use a CLEI code struggling with the character limit as well.
Author
Owner

@jeremystretch commented on GitHub (Feb 28, 2017):

Even if we widened the field, we'd have to implement truncation in many places when displaying the device name (such as in the device list) to keep the layout readable.

Interestingly, RFC 1035 suggests a limit of 63 characters for host names, and my Ubuntu-based system seems to enforce a 64-character limit:

$ getconf HOST_NAME_MAX
64
@jeremystretch commented on GitHub (Feb 28, 2017): Even if we widened the field, we'd have to implement truncation in many places when displaying the device name (such as in the device list) to keep the layout readable. Interestingly, [RFC 1035](https://tools.ietf.org/html/rfc1035#section-2.3.1) suggests a limit of 63 characters for host names, and my Ubuntu-based system seems to enforce a 64-character limit: ``` $ getconf HOST_NAME_MAX 64 ```
Author
Owner

@jeremystretch commented on GitHub (Mar 1, 2017):

@InsaneSplash how do you feel about a 64-character limit?

@jeremystretch commented on GitHub (Mar 1, 2017): @InsaneSplash how do you feel about a 64-character limit?
Author
Owner

@VictorJ76 commented on GitHub (Mar 2, 2017):

higher is better

@VictorJ76 commented on GitHub (Mar 2, 2017): higher is better
Author
Owner

@jeremystretch commented on GitHub (Mar 2, 2017):

64 characters should be more than sufficient. This is the maximum hostname length for many platforms.

@jeremystretch commented on GitHub (Mar 2, 2017): 64 characters should be more than sufficient. This is the maximum hostname length for many platforms.
Author
Owner

@InsaneSplash commented on GitHub (Mar 3, 2017):

Thanks for the increase in characters!

@InsaneSplash commented on GitHub (Mar 3, 2017): Thanks for the increase in characters!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#709