is there a max length for file names

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
pkarr
Posts: 58
Joined: Fri Oct 05, 2012 1:01 pm

is there a max length for file names

Post by pkarr »

Hi,
We are in the process of designing our new Nagios environment. We want to have descriptive names for our templates, service check, hostgroups, et al. The names are starting to get kind of long so I was wondering if there was a maximum length for a file name? Also, how about spaces in file names? I've talked my boss out of using them in everything but HostGroup names.

thanks,
Penny


Penny Karr | IT Infrastructure Monitoring
Harvard Vanguard Medical Associates, an Affiliate of Atrius Health
254 Second Avenue | Needham, MA 02494
P (781) 292-1853 | F (781 292-1980 | http://www.harvardvanguard.org
Email: [email protected]
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: is there a max length for file names

Post by sreinhardt »

Linux\Unix max path names are ~252 characters last I checked. (technically 254 or 256, but bsd has a smaller default so I artificially limit myself) I do not believe nagios should have any known issues with paths that match the max size for filenames. As for internal hostnames, I would honestly have to check, but I doubt we have any hard limits that you would reasonably hit. If you'd like I can check on the absolute max sizes internal to nagios, but I think you were just asking about file name size, so I'll stop here.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
Locked