Call Us! 1-800-383-5193
Call Us! 1-800-383-5193
Call Us! 1-800-383-5193

Need Help?

Emergency Response Time custom

Our experts have had an average response time of 11.06 minutes in March 2021 to fix urgent issues.

We will keep your servers stable, secure and fast at all times for one fixed price.

Import Config Files From Nagios Core into Nagios XI

by | May 9, 2021

We Import Config Files From Nagios Core where we wish to import configurations from existing Nagios Core installations.

Importing configuration files automates setting up existing Hosts, Services, Hostgroups, etc in our Nagios XI installation.

As part of our Server Management Services, we assist our customers with several Nagios queries.

Today, let us see how to migrate and import Nagios Core configuration files into Nagios XI.


Import Config Files From Nagios Core into Nagios XI

Before importing, our Support Techs recommend that we use the Nagios XI config import prep tool.

Example Import

For example, we can import a command, hostgroup, host and service … in that order.

Here is a few example configs in the /usr/local/nagios/etc/cfgprep/orig/ directory:

define command {
command_name check_nrpeversion
command_line $USER1$/check_nrpe -H $HOSTADDRESS$

define hostgroup {
hostgroup_name Windows-Common
alias Windows-Common

define host {
use windows-server
host_name server01
hostgroups Windows-Common

define service {
use generic-service
hostgroup_name Windows-Common
service_description NSClient++ Version
check_command check_nrpeversion

Once we run the xiprepimport.php tool, the files will save into the /usr/local/nagios/etc/cfgprep/ directory. All the files will have the same name.

However, the windows_example_service.cfg will be empty and another file, _multiple_hosts.cfg will generate with its content.

These configs demonstrate the need to import the configurations in a specific order.

Navigate to the Core Config Manager (CCM)

There are different ways to access CCM. One way is to, Hover over the Configure button, then select Core Config Manager

Import Configuration Files

We access the Import Interface from the Import Config Files menu option under Tools.

Initially, we will have a popup message that explains the order in which we need to impost the configuration files.

It will command > hostgroup > host > service.

However, we are doing host and hostgroup in the opposite order. In our example, the host is added to a hostgroup. So it needs to exist first.

We can close the popup once we finish reading the message.

Here we can see a list of files available for import.

We can use CTRL or SHIFT on the keyboard to select multiple files to import. In this example, we will be importing the files one at a time.

The first file to import will be:


We can select the file and click the Import button.

Once done, we will receive a success message.

Every time, we ensure the import was a success. In CCM, navigate to Commands and search for check_nrpeversion.

Post Import Actions

Before Applying Configuration, it is best to validate that the configuration files are valid.

For that, in CCM, expand Tools and select Config File Management.

Click the Write Configs button to create/update the config files on the Nagios XI server.

Here, we can check the creation of the host and service config files and the updates of the existing hostgroups and commands config files.

Then we proceed to the Verify Files button.

If our output shows any CRITICAL error messages, the background color will be red.

We can resolve them by going to the respective configuration area in CCM. We retry the write/verify process until the verify is successful.

Apply Configuration

After the configuration, our Support Techs recommend that we use the Apply Configuration function. This will restart Nagios core with the new configuration.

To access this option we select the Apply Configuration menu item and click the Apply Configuration button.

This configuration feature will perform the following steps:

  • Export the database configuration to disk
  • Verify the configuration files
  • Restart Nagios Core
  • Create a new configuration snapshot

Another option is to use the Restart Nagios Core button on the Config File Management page.

However, this option will not create a snapshot like the Apply Configuration button.

Once the import completes, we require additional steps.

These steps include:

  • Upload missing plugins or event handlers to Nagios XI
  • Creating user accounts in Nagios XI

[Find it hard? We are happy to keep you going]



In short, we saw an effective method our Support Techs employ to Import Config Files From Nagios Core into Nagios XI.


Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.


var google_conversion_label = "owonCMyG5nEQ0aD71QM";


Submit a Comment

Your email address will not be published. Required fields are marked *

Privacy Preference Center


Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]


Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid


Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie


These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.