I am trying the NagiosXi for the first time and importing our configs over from our existing Nagios Core to Xi. I created some config files and followed instructions to import them using the prep tool.
I am getting the following error in the GUI as shown in the attached snapshot.
This happens when I try to do this:
[root@nagiosxi1-eq etc]# pwd
/usr/local/nagios/etc
[root@nagiosxi1-eq etc]# grep -r nagioswrk1-eq *
I can't find the nagioswrk1-eq host. I am guessing the error is coming from the database somewhere.
How can I fix this in the future. There are a lot of config files I need to import and most of them have custom scripts.
Please advice.
Thanks
# mukarram
Code: Select all
[root@nagiosxi1-eq etc]# tree cfgprep/
cfgprep/
├── 8x8-linux-hostgroups.cfg
├── 8x8-linux-hosts.cfg
├── 8x8-linux-services.cfg
├── _empty_host.cfg
├── _multiple_hosts.cfg
├── netmon1-uk.cfg
├── netmon1-uk-hostgroups.cfg
├── netmon1-uk-hosts.cfg
├── netmon1-uk-services.cfg
└── orig
├── 8x8-linux-hostgroups.cfg
├── 8x8-linux-hosts.cfg
├── 8x8-linux-services.cfg
├── netmon1-uk-hostgroups.cfg
├── netmon1-uk-hosts.cfg
└── netmon1-uk-services.cfg
1 directory, 15 files
[root@nagiosxi1-eq cfgprep]# cat orig/8x8-linux-hosts.cfg
########################
## 8x8-HOSTS.CFG ##
########################
##################
# HOSTS TEMPLATE #
##################
define host{
name 8x8-host
alias 8x8-hosts
check_command check_ping
max_check_attempts 1
contact_groups sys-ops
notification_options d,u,r
notification_period 24x7
notification_interval 5
notifications_enabled 1
event_handler_enabled 1
flap_detection_enabled 1
process_perf_data 1
retain_status_information 1
retain_nonstatus_information 1
register 0
}
define host{
host_name nagios-wkr-eq
address 192.168.131.95
use 8x8-host
}
# EOF
[root@nagiosxi1-eq cfgprep]# cat orig/8x8-linux-hostgroups.cfg
############################
## 8x8-HOSTGROUPS.CFG ##
############################
define hostgroup {
hostgroup_name 8x8-linux
alias 8x8 servers @ SV2
members nagios-wkr-eq
}
#EOF
[root@nagiosxi1-eq cfgprep]# cat orig/8x8-linux-services.cfg
###########################
## UK1-SERVICES.CFG ##
###########################
######################
# SERVICE DEFINITION #
######################
define service{
name 8x8-svc
active_checks_enabled 1
check_period 24x7
normal_check_interval 5
retry_check_interval 5
max_check_attempts 2
contact_groups sys-ops
notification_options w,u,c,r
notification_period 24x7
notification_interval 1440
notifications_enabled 1
check_freshness 7
is_volatile 0
event_handler_enabled 1
flap_detection_enabled 1
obsess_over_service 1
parallelize_check 1
passive_checks_enabled 1
process_perf_data 1
retain_nonstatus_information 1
retain_status_information 1
register 0
}
##############
# CHECK PING #
##############
define service{
service_description Check Ping
check_command check_ping
hostgroup_name 8x8-linux
use 8x8-svc
contact_groups sys-ops
}
################
# MEMORY CHECK #
################
define service{
service_description Check mem
check_command check_nrpe!check_mem_linux
_joomlaurl http://betazoid.8x8.com/alarms/350-check-mem-alarms
hostgroup_name 8x8-linux
use 8x8-svc
contact_groups sys-ops
}
####################
# CHECK DISK USAGE #
####################
define service{
service_description Check disk
check_command check_nrpe!check_disk
_joomlaurl http://betazoid.8x8.com/alarms/377-problem-disk-space
hostgroup_name 8x8-linux
use 8x8-svc
contact_groups sys-ops
}
###############
# CHECK LOAD #
###############
define service{
service_description Check load
check_command check_nrpe!check_load
_joomlaurl http://betazoid.8x8.com/alarms/419-nagios-check-load
hostgroup_name 8x8-linux
use 8x8-svc
contact_groups sys-ops
}
##############
# CHECK NTP #
##############
define service{
service_description NTP
check_command check_nrpe!check_ntp
_joomlaurl http://betazoid.8x8.com/alarms/328-ntp
hostgroup_name 8x8-linux
use 8x8-svc
contact_groups sys-ops
}
####
# CHECK TURN
####
##define service{
## service_description TURN
## check_command check_turn
## _joomlaurl http://betazoid.8x8.com/alarms/371-taking-turn-servers-out-of-rotation
## host_name 8x81-uk
## use 8x8-svc
## max_check_attempts 1
##}
# EOF