Thruk with Shinken

  • Hi guys!


    I'm trying to install my first monitoring system, which is Shinken with Thruk as a graphic interface. I installed Shinken following the documentation, and it works well (I tried it with Shinken WebUI v1). Then I installed Thruk, still following the documentation(with rpm packages). Now, I can access to Thruk (myip/thruk) BUT I can't login myself. I tried the default id (thrukadmin/thrukadmin) but it didn't work. I also tried to follow this tuto (officiel Shinken website) and I created a new user, but it didn't work neither. I'm working on a CentOS release 6.7.


    After attempting to connect, I have this message written in thruk log file (/var/log/thruk/thruk.log) :

    Shell-Script
    1. [ERROR][Thruk] file error - cache failed to write passthrough.tt.ttc: Permission denied on passthrough.tt at /usr/share/thruk/lib/Thruk/Views/ToolkitRenderer.pm line 76.
    2. [ERROR][Thruk] internal server error
    3. [ERROR][Thruk] on page: http://localhost/thruk/cgi-bin/restricted.cgi
    4. [INFO][Thruk] login failed for shinken on /thruk/ from <ip>


    Did I do something wrong? And does somebody know what is "passthrough.tt.ttc"?

  • Did you just install the rpm packages? The ttc file is the compiled template file which will be created on the first request. It usually gets stored in the tmp folder which is /var/cache/thruk/ttc or somethink like that. Do you have selinux or anything like that enabled? Who owns the /var/cache/thruk folder. Is it writeable to the webserver user?

  • Hi Sni, and thank you for your answer!


    I also installed Livestatus and WebUI modules following the documentation. Apparently the WebUI works well (I can access it). I installed MySQL Database for the cache.


    SELinux is in enforcing mode (saw in /etc/selinux/config file). I know this could cause some troubles but I don't know if I can disable it without causing security issues (I'm in a professional environnement).


    The /var/cache/thruk is owned by apache user, who has all rights on it, but my Shinken and root users don't have any right on it.


    I found passthrough.tt.ttc file in /var/cache/thruk/ttc_48/usr/share/thruk/templates/ folder. I tried to do a chmod 777 on it (just to test). I still can't connect to Thruk, and I still have the same error message.


    EDIT :


    I just notice that my Thruk service is not running... But when I try to launch it (using "service thruk start" or "/etc/init.d/thruk start"), I have this message :


    Starting thruk.....failed
    Setting --timeout (timeout) to 15
    Setting --output-document (outputdocument) to -
    DEBUG output created by Wget 1.12 on linux-gnu.



    --2016-05-30 17:33:46-- http://localhost/thruk/cgi-bin/remote.cgi?startup
    Resolving localhost... ::1, 127.0.0.1
    Caching localhost => ::1 127.0.0.1
    Connecting to localhost|::1|:80... Closed fd 3
    failed: Connection refused.
    Connecting to localhost|127.0.0.1|:80... Closed fd 3
    failed: Connection refused.
    Releasing 0x00000000011b00d0 (new refcount 1).

    The post was edited 1 time, last by Lily ().