Page 1 of 1
Nagios 4.1.1: Disable hostgroup alphabetic sorting ?
Posted: Mon Aug 01, 2016 12:59 pm
by nagmoto
I like to have rendered html page go by following sequence exactly.
Code: Select all
hostgroups siteA,linux,non-prod,business
But I found "business" will showup in the web page as first one.
Re: Nagios 4.1.1: Disable hostgroup alphabetic sorting ?
Posted: Mon Aug 01, 2016 1:18 pm
by rkennedy
This really isn't going to be possible, unless you modified the C that actually does the sorting. One work around, is to put a number before your hostgroup names. For example -
Code: Select all
hostgroups siteA,linux,non-prod,business
would become -
Code: Select all
hostgroups 1siteA,2linux,3non-prod,4business
This would then be displayed like so -
Re: Nagios 4.1.1: Disable hostgroup alphabetic sorting ?
Posted: Tue Aug 02, 2016 12:35 pm
by nagmoto
Can you advise which C file and where I need might need to change ?
Thanks
Re: Nagios 4.1.1: Disable hostgroup alphabetic sorting ?
Posted: Tue Aug 02, 2016 12:57 pm
by mcapra
It would most likely be in cgi/status.c. Without knowing the specific page you're referring to, I can't say for sure.