import error of services

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
iannonea
Posts: 3
Joined: Mon Sep 07, 2015 3:50 am

import error of services

Post by iannonea »

Hi team,
I'm continuing to import all the cfg's file from Nagios 3.0.6 to NagiosXI.
Following these steps: commands -> timeperiods -> contacttemplates -> contacts -> contactgroups ->
hosttemplates -> hosts -> hostgroups -> servicetemplates -> services -> servicegroups
I got : commands -> timeperiods -> contacttemplates -> contacts -> contactgroups ->
hosttemplates -> hosts -> hostgroups
Now I'm blocked for the last step: services cfg.
When we import services.cfg for some reasons the import tool do not import correctly all the informations.

Original file contains:

Code: Select all

define service {
host_name       DB-TEST-CHECKS
service_description     TSTTBCDBS01 ASM TNSPING
use     tm-s2-service
check_command   dbchecks_nrpe!dbchecks_tnsping!tsttbcdbs01_ASM
}
file created by Nagios after "tool-->Import Config Files":

Code: Select all

define service {
        service_description             TSTTBCDBS01 ASM TNSPING
        use                             tm-s2-service
        check_command                   dbchecks_nrpe!dbchecks_tnsping!tsttbcdbs01_ASM
        register                        1
        }
As you can see the host_name line disappeared and the import tool filed with:
Error: Service has no hosts and/or service_description (config file '/usr/local/nagios/etc/services/DB-TEST-CHECKS.cfg', starting on line 997)

Do you have some suggestions?

Regards

Armando
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: import error of services

Post by tgriep »

We have a document that will help you convert the Nagios 3.0.6 files so they can be imported in to XI. Take a look at it and see if that helps you out.
https://assets.nagios.com/downloads/nag ... p-Tool.pdf

Can you go in to Core Config Manager > Hosts on the XI system and verify that the host called "DB-TEST-CHECKS" exists?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked