Posts by yashal

This forum was archived to /woltlab and is now in read-only mode.

    Ok. Solved. Following are the steps I made to make icinga2 up and running in Amazon Linux AMI.

    Then, in the file $HOME/rpmbuild/BUILD/icinga2-2.6.3/etc/initsystem/CMakeLists.txt I substitute the line

    Code
    1. set(ICINGA2_SYSCONFIGFILE "${CMAKE_INSTALL_SYSCONFDIR}/sysconfig/icinga2" CACHE PATH "where to store configuation for the init system, defaults to /etc/sysconfig/icinga2")

    with

    Code
    1. if(NOT DEFINED ICINGA2_SYSCONFIGFILE)
    2. set(ICINGA2_SYSCONFIGFILE "${CMAKE_INSTALL_SYSCONFDIR}/sysconfig/icinga2" CACHE PATH "where to store configuation for the init system, defaults to /etc/sysconfig/icinga2")
    3. endif()

    Again, in the file $HOME/rpmbuild/BUILD/icinga2-2.6.3/etc/initsystem/icinga2.service.cmake I substitute the line

    Code
    1. ExecStartPre=@CMAKE_INSTALL_PREFIX@/lib/icinga2/prepare-dirs @ICINGA2_SYSCONFIGFILE@

    with

    Code
    1. ExecStartPre=@CMAKE_INSTALL_FULL_SBINDIR@/icinga2-prepare-dirs @ICINGA2_SYSCONFIGFILE@

    After all the steps mentioned above, I started the service icinga2 and it was perfectly up and running without any errors.


    Thank all for the guidelines and the support.

    Hi jat,


    exactly, it should run in /etc/init.d but it was not there, so, as your suggestion, I copied the icinga2 init script from the official repo.


    Running service icinga2 enable as well as service icinga2 start return the following statement:

    Could not fetch RunAsUser variable. Error 'critical/cli: Invalid group specified: icinga'. Exiting.

    I am also pretty sure I have not specified any user pr group either.


    Has anybody experienced anything similar?


    Thanks in advance for any help!

    Hi all,


    I have also followed the steps mentioned above (used by ghovat) on my AWS Linux Host.

    I solved the error from ghovat by:

    • renaming CHANGELOG.md with ChangeLog in the file icinga2.spec.
    • Copying the missing file check_nscp_api.cpp from the official repo inhttps://github.com/Icinga/icinga2/blob/master/plugins/check_nscp_api.cpp and renamed in check_nscp_api.


    After these changes, rpmbuild does not return any errors. However, icinga2 is not present in /etc/init.d/ and running service icinga2 start

    still returns icinga2: unrecognized service. So it seems not to be installed at all.


    Any tips?