how to migrate nagios from one server to another server
Re: how to migrate nagios from one server to another server
i checked in commands.cfg and nagios.cfg.
i didnt find anywhere.
normally where is it defined?
i didnt find anywhere.
normally where is it defined?
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: how to migrate nagios from one server to another server
sinkak wrote: cfg_file=/etc/nagios3/commands.cfg
cfg_dir=/etc/nagios-plugins/config
cfg_dir=/etc/nagios3/conf.d
Code: Select all
grep check_nrpe_args /etc/nagios3/commands.cfg
grep -R check_nrpe_args /etc/nagios-plugins/config
grep -R check_nrpe_args /etc/nagios3/conf.dRe: how to migrate nagios from one server to another server
i changed the paths in config file.
i no longer see that error
i no longer see that error
Re: how to migrate nagios from one server to another server
i am having the error while loading config file
I checked the config file. Valid member group exits
Code: Select all
sudo service nagios reload
Error: Could not find member group '!all-elbs' specified in hostgroup 'all_hosts' (config file '/usr/local/nagios/etc/conf.d/hostgroups_nagios2.cfg', starting on line 115)
Error processing object config files!Code: Select all
define hostgroup{
hostgroup_name all-rds
alias rds
members db[0-9]+.*
}
define hostgroup {
hostgroup_name all-elbs
members (LB.*)
}
define hostgroup {
hostgroup_name all_hosts
alias all
hostgroup_members !all-elbs,!all-rds
Last edited by sinkak on Tue Aug 04, 2015 2:20 pm, edited 2 times in total.
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: how to migrate nagios from one server to another server
not hostgroups aren't allowed. Only not hosts.
New topic please if your old one is solved.
New topic please if your old one is solved.
Re: how to migrate nagios from one server to another server
still in the process of migration.
migrated config files and edited the paths for plugins, scripts and config files.
still have some errors while starting new config
migrated config files and edited the paths for plugins, scripts and config files.
still have some errors while starting new config
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: how to migrate nagios from one server to another server
OK, what are the current issues? Did your config verify when you didn't have the invalid hostgroup?
Re: how to migrate nagios from one server to another server
same config files exist on old server. it doenst have error.
on new server it shows error
Error: Could not find member group '!all-elbs' specified in hostgroup 'all_hosts' (config file '/usr/local/nagios/etc/conf.d/hostgroups_nagios2.cfg', starting on line 115)
member group is clearly defined in that config file
on new server it shows error
Error: Could not find member group '!all-elbs' specified in hostgroup 'all_hosts' (config file '/usr/local/nagios/etc/conf.d/hostgroups_nagios2.cfg', starting on line 115)
member group is clearly defined in that config file
Code: Select all
define hostgroup {
hostgroup_name all-elbs
members (LB.*)
}
define hostgroup {
hostgroup_name all_hosts
alias all
hostgroup_members all_web_and_sched,cacheservers,prod_linux_server
s,weblinux-servers,windows-servers,!all-elbs
Re: how to migrate nagios from one server to another server
if i remove ! before !all-elbs,!all-rds
changed from
to
it works.
Previou admin added that.
does it mean exclude all that hosts? or anything else?
changed from
Code: Select all
define hostgroup {
hostgroup_name all_hosts
alias all
hostgroup_members !all-elbs,!all-rdsCode: Select all
define hostgroup {
hostgroup_name all_hosts
alias all
hostgroup_members all-elbs,all-rdsPreviou admin added that.
does it mean exclude all that hosts? or anything else?
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: how to migrate nagios from one server to another server
I understand. What I'm trying to say is that you can not NOT hostgroups in a hostgroup definition. For example:
is fine
is invalid.
I'm surprised it worked on your old system. I doubt it actually *worked*, it probably just passed validation silently even though it's not valid. Something similar can be done in services, but that is for definition objects "host_groups," not "hostgroup_members."
Code: Select all
hostgroup_members hostgroupCode: Select all
hostgroup_members !hostgroupI'm surprised it worked on your old system. I doubt it actually *worked*, it probably just passed validation silently even though it's not valid. Something similar can be done in services, but that is for definition objects "host_groups," not "hostgroup_members."