Deprecated: Return type of Requests_Cookie_Jar::offsetExists($key) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Cookie/Jar.php on line 63

Deprecated: Return type of Requests_Cookie_Jar::offsetGet($key) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Cookie/Jar.php on line 73

Deprecated: Return type of Requests_Cookie_Jar::offsetSet($key, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Cookie/Jar.php on line 89

Deprecated: Return type of Requests_Cookie_Jar::offsetUnset($key) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Cookie/Jar.php on line 102

Deprecated: Return type of Requests_Cookie_Jar::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Cookie/Jar.php on line 111

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetExists($key) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 40

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetGet($key) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 51

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetSet($key, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 68

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetUnset($key) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 82

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /www/webvol14/so/emm9jypq7227iqw/linuxkitchen.com/public_html/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 91
Prebacivanje stare konfiguracije u noviju verziju Nagios-a – Linux, Windows, Heklanje, Kuhinja

Prebacivanje stare konfiguracije u noviju verziju Nagios-a

E pa pošto sada servis kao takav radi, treba prebaciti i konfiguraciju sa starog servera.
Gde se nalaze razni fajlovi
Kod moje stare konfiguracije (Nagios 3.2) konfiguracioni fajlovi su bili u /etc/nagios folderu.
Ako se instalira Nagios 4.0.2 kako sam stavila u mom predhodnom postu, konfiguracioni fajlovi su u : /usr/local/nagios/etc.
Plug-in-ovi i PL skripte na Nagios 4.0.2 su u /usr/local/nagios/libexec folderu.
Koje konfiguracione fajlove treba kopirati
Iz /etc/nagios u /usr/local/nagios/etc :
command-plugins.cfg
commands.cfg
contactgroups.cfg
contacts.cfg
hosts.cfg
ncsa.cfg
send_ncsa.cfg
services.cfg
Iz /var/nagios u /usr/local/nagios/var :
objects.cache
Posle prebacivanja konfiguracionih fajlova, restartovati servis, i obavezno pratiti log u /usr/local/nagios/var!!
Koje konfiguracione fajlove treba izmeniti
Fajl /usr/local/nagios/etc/nagios.cfg, i šta se u njemu menja :
…..
cfg_file=/usr/local/nagios/etc/objects/timeperiods.cfg
cfg_file=/usr/local/nagios/etc/objects/templates.cfg
cfg_file=/usr/local/nagios/etc/hosts.cfg
cfg_file=/usr/local/nagios/etc/commands.cfg
cfg_file=/usr/local/nagios/etc/services.cfg
cfg_file=/usr/local/nagios/etc/contacts.cfg
cfg_file=/usr/local/nagios/etc/contactgroups.cfg
…..
nagios_group=nagcmd
Šta nedostaje, pa treba dodati
Pa i pored instalacije standardnih plug-in-ova, verovatno će nedostajati gomila PL skripti i drugih provera. Treba ih jednostavno samo kopirati sa starog servera (tamo su u folderu /usr/lib/nagios/plugins) na novi server, u folder : /usr/local/nagios/libexec.

Na kraju
Posle prebacivanja konfiguracionih fajlova i njihove izmene, restartovati servis, i obavezno pratiti izlaz komande kao i log fajl /usr/local/nagios/var/nagios.log i debug log fajl /usr/local/nagios/var/nagios.debug!!
Gledati na sajt Nagios servisa, da li se sve provere odvijaju kako treba.