Ad Widget

Collapse

Sheduled report PDF blank or contains 404 page

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • PrimalMinister
    Junior Member
    • Sep 2021
    • 1

    #1

    Sheduled report PDF blank or contains 404 page

    I have set up the zabbix server and web service, both seem to be working fine. I am receiving the report in my email box with a PDF attached but the PDF is either blank or a 404 page. In my zabbix_server.conf I have the following:

    Code:
    WebServiceURL=http://localhost:10053/report
    If I curl the service on the server I get:

    Code:
    curl http://localhost:10053/report
    
    {"detail":"Method is not supported."}
    So it looks like the service is running, the problem seems to be with the Frontend URL. I have set this to various settings including:

    Code:
    http://localhost
    http://localhost:10050
    http://localhost/report
    http://localhost:10050/report
    https://subdomain.domain.com # With my real domain
    https://subdomain.domain.com:10050
    https://subdomain.domain.com/report
    https://subdomain.domain.com:10050/report
    All I get is a blank PDF or one with a 404 page, this really has me stumped, I have literally searched all 86 results on google for 'front end URL zabbix' and various other terms, I can find nothing.

    I hope someone can help, thanks.
  • Rudlafik
    Senior Member
    • Nov 2018
    • 144

    #2
    Our resolution is:

    1. Administration -> General -> Other: Fronend URL: https://Yours.DNS.adr

    2.Zabbix server config: WebServiceURL=http://Yours.DNS.adr:10053/report

    3.Web service config:
    TLSAccept=unencrypted
    IgnoreURLCertErrors=1

    Its work for us :-) Not blank PDF

    Comment


    • tom_minerd
      tom_minerd commented
      Editing a comment
      Worked for me as well. Actually not at first, but a reboot of the server may have helped.

    • Gianluca
      Gianluca commented
      Editing a comment
      Worked for me as well. Thank's
  • HISHORE N
    Junior Member
    • Mar 2022
    • 2

    #3
    I too have the same problem. If the issue solved help me to rectify this issue.

    Comment

    • aalmasan
      Junior Member
      • Mar 2023
      • 7

      #4
      Hi Guys I know this post is old but similar to my issue, anyone has any ideas?
      What am I missing?

      I have the same issue, its zabbix 6.2 server AWS image.
      Have a production server and a test one. I installed the web services same config as above but PDFs are blank one I get file not found and the new test server 404 page not found.
      It's 3 days witch no luck. I am using a certificate key to sign in ec2-user is this possibly the issue?

      login as: ec2-user
      Authenticating with public key "imported-openssh-key"
      VERSION="8.6"
      ID="ol"
      ID_LIKE="fedora"
      VARIANT="Server"
      VARIANT_ID="server"
      VERSION_ID="8.6"
      PLATFORM_ID="platform:el8"
      PRETTY_NAME="Oracle Linux Server 8.6"
      ANSI_COLOR="0;31"
      CPE_NAME="cpe:/o​racle:linux:8:6:server"
      HOME_URL="https://linux.oracle.com/"
      BUG_REPORT_URL="https://bugzilla.oracle.com/"

      ORACLE_BUGZILLA_PRODUCT="Oracle Linux 8"
      ORACLE_BUGZILLA_PRODUCT_VERSION=8.6
      ORACLE_SUPPORT_PRODUCT="Oracle Linux"
      ORACLE_SUPPORT_PRODUCT_VERSION=8.6

      I appreciate any help with it
      Thank you

      Comment

      • aalmasan
        Junior Member
        • Mar 2023
        • 7

        #5
        I have in the meantime installed a preconfigured Zabbix Server Appliance 6.2.7 and installed web services, google chrome.
        I have now root root access
        I can generate and send reports but still getting the same empty pdf reports "with file not found"

        What am I missing ? Any help appreciated

        Configured the zabbix-server.conf
        StartReportWriters=1
        and
        WebServiceURL=http://localhost:10053/report


        Frontend URL http:/localhost/zabbix/ui

        Configured zabbix-web-service.conf
        AllowedIP=127.0.0.1,::1
        TLSAccept=unencrypted
        IgnoreURLCertErrors=1

        no errors in the webservice log
        2023/03/06 11:30:21.142315 received report request from 127.0.0.1:51350
        2023/03/06 11:30:23.450840 writing response for report request from 127.0.0.1:51350
        Thank you for any help​

        Comment

        • aalmasan
          Junior Member
          • Mar 2023
          • 7

          #6
          Good news
          I just managed to find a workaround that works. I was using Nginx in all my installations.

          I swapped to Apache instead and it worked. It is possible that works with Nginx as well but not sure what exactly configuration is needed and where.
          When switching to apache the front end server gui login changes from http://192.168.2.101/ to http://192.168.2.101/zabbix/​
          Last edited by aalmasan; 11-03-2023, 17:06.

          Comment

          • plasticblender
            Junior Member
            • Aug 2023
            • 1

            #7
            In case someone is still having issues and is using nginx. I found out that chrome is requesting the report on port 80 and since I was using nginx default install the default_server config was listening on port 80 which returned a 404. Removing the default server in /etc/nginx/sites-enabled, adding "listen 80;" to /etc/nginx/sites--available/zabbix and restarting zabbix-server solved it for me. It was also important to not mix http and https in the following config parameters

            /etc/zabbix/zabbix-server.conf
            StartReportWriters=1
            WebServiceURL=http://localhost:10053/report

            /etc/zabbix/zabbix-web-service.conf
            AllowedIP=127.0.0.1
            TLSAccept=unencrypted
            IgnoreURLCertErrors=1

            Administration->General->Other
            Frontend URL http:/zabbix-server-ip

            Reports->Scheduled Reports->Create Report
            Owner -> Admin
            Period -> Previous day
            Cycle -> Daily
            Start time -> 00:00



            ​​

            Comment


            • JavierH
              JavierH commented
              Editing a comment
              I can't find these directories: /etc/nginx/sites-enabled ; /etc/nginx/sites--available/zabbix I am using NGINX
          Working...