Hello,
and sorry but it seems I messed up Icingaweb2 on my working Debian setup.
I had everything worked for few months.
Yesterday I had a “brilliant” idea to install gitlab-ee next to Icinga on the same server.
Right know I know it will be better to solve gitlab via Docker container.
So what happened (OS: Debian Stretch)
working status (without backup, my bad)
It was installed by guide following with php7.3 FPM with Apache few month ago, all working.
Yesterday:
installed gitlab-ee + set the external url to gitlab.domain.cz
I realized right after installation its on the same port 80 (Icinga on Apache and new Gitlab on nginx)
Uninstalled gitlab-ee to prevent it from to have apache and nginx together.
icingaweb has stopped working, restarts didnt helped, and it seems that installation of gitlab somehow corrupted apache.
So I went through:
backup /usr/share/icingaweb2 folder
apt-get remove/purge of apache2 icingaweb2 icingacli
manualy deleted /etc/apache2 folder
reboot
apt-get install apache2
apt-get install icingaweb2
apt-get install icingacli
while trying to install icingaweb2 and icingacli it went into errors like this:
root@control_machine:/home/bmcom# apt-get install icingaweb2 icingacli
Reading package lists… Done
Building dependency tree
Reading state information… Done
icingacli is already the newest version (2.7.1-1.stretch).
icingaweb2 is already the newest version (2.7.1-1.stretch).
The following packages were automatically installed and are no longer required:
libconfig-inifiles-perl libjemalloc1 php-htmlpurifier sgml-base xml-core
Use ‘apt autoremove’ to remove them.
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
3 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up icingaweb2 (2.7.1-1.stretch) …
apache2_invoke rewrite: no action - module was disabled by local admin
dpkg: error processing package icingaweb2 (–configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of icingaweb2-module-doc:
icingaweb2-module-doc depends on icingaweb2 (= 2.7.1-1.stretch); however:
Package icingaweb2 is not configured yet.
dpkg: error processing package icingaweb2-module-doc (–configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of icingaweb2-module-monitoring:
icingaweb2-module-monitoring depends on icingaweb2 (= 2.7.1-1.stretch); however:
Package icingaweb2 is not configured yet.
dpkg: error processing package icingaweb2-module-monitoring (–configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
icingaweb2
icingaweb2-module-doc
icingaweb2-module-monitoring
E: Sub-process /usr/bin/dpkg returned an error code (1)
When separating them it helped and install is complete.
But the next step from the guide for Debian went here:
icingacli setup token create
Found invalid module in enabledModule directory “/etc/icingaweb2/enabledModules”: “/etc/icingaweb2/enabledModules/setup” points to non existing path “false”
The ‘setup’ module does not provide any CLI commands
So I manualy removed the not working link for module setup
But
icingacli module install setup
ERROR: Icinga\Exception\IcingaException in /usr/share/php/Icinga/Cli/Command.php:154 with message: Not implemented yet
Right now the web page looks like this:
Warning : Uncaught ErrorException: require_once(Zend/Loader/Autoloader.php): failed to open stream: No such file or directory in /usr/share/php/Icinga/Application/ClassLoader.php:273 Stack trace: #0 /usr/share/php/Icinga/Application/ClassLoader.php(273): Icinga\Application\ApplicationBootstrap->Icinga\Application{closure}(2, ‘require_once(Ze…’, ‘/usr/share/php/…’, 273, Array) #1 /usr/share/php/Icinga/Application/ClassLoader.php(273): require_once() #2 /usr/share/php/Icinga/Application/ClassLoader.php(291): Icinga\Application\ClassLoader->requireZendAutoloader() #3 [internal function]: Icinga\Application\ClassLoader->loadClass(‘Zend_Controller…’) #4 /usr/share/php/Icinga/Web/Request.php(14): spl_autoload_call(‘Zend_Controller…’) #5 /usr/share/php/Icinga/Application/ClassLoader.php(303): require(‘/usr/share/php/…’) #6 [internal function]: Icinga\Application\ClassLoader->loadClass(‘Icinga\Web\Requ…’) #7 /usr/share/php/Icinga/Application/EmbeddedWeb.php(85): spl_autoload_call(‘Icinga\Web\Requ…’) #8 /usr/ in /usr/share/php/Icinga/Application/ClassLoader.php on line 273
Fatal error : Icinga\Application\ClassLoader::requireZendAutoloader(): Failed opening required ‘Zend/Loader/Autoloader.php’ (include_path=‘/usr/share/icingaweb2/library/vendor:.:/usr/share/php’) in /usr/share/php/Icinga/Application/ClassLoader.php on line 273
Its similar to Icingaweb2 post-installation Zend Loader error
Can anyone please point me into the right direction? Icinga daemon works and collects data from monitored satelites/clients.
Is is possible to clean it up and install just Icingaweb2 again?
From what I remember the installation is super easy, just few commands when the system was freshly installed.
After it will be solved for sure making snapshot a backing up everything before I will do next operations on the server.
Thanks in advance.