2. Configuring EMA : Examples of Modifying the Nagios EMA Configuration : Add an Extra Host and Installation to EMA Manually
 
Share this page                  
Add an Extra Host and Installation to EMA Manually
Edit files under...nagios/etc/objects.
1. Copy an existing hostname.cfg file to a new hostname.cfg file and edit the contents to set the name and address. For example:
cp myhost1.cfg myhost2.cfg
2. Create a subdirectory with the same name as the new host by copying an existing directory. For example:
cp -r myhost1 myhost2
3. In the new directory, edit host.cfg and change the name and host_name. Also, make sure that the _HOSTPLUGINS points to a plugins directory ($II_SYSTEM/ingres/iiema/plugins) that exists on the new host. The plugins directory contains the scripts for monitoring CPU, memory, and disk that EMA calls.
4. Edit any installation.XX.cfg files to match existing installations on your new host, replacing the old installation with the new. Make sure _II_SYSTEM and _PLUGINS are correct too.
5. Add the public SSH key .../nagios/etc/ssh/id_rsa.pub to the authorized_keys file for Ingres on the target host:
docker exec -it ema ssh-copy-id -i /usr/local/nagios/etc/ssh/id_rsa ingres@myhost2
6. Restart Nagios:
docker exec ema /etc/init.d/nagios restart