Page 1 of 2

Failed to create PDF Verify that your Nagios XI server

Posted: Tue Aug 28, 2018 8:48 am
by dimsum
Hi,

I got the error when export to pdf or jpg. everything works after upgrade to 5.5.2
Failed to create PDF
Verify that your Nagios XI server can connect to the URL:
http://localhost/nagiosxi/reports/avail ... 1&export=1
[root@localhost ~]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6

Help me, please.

Thank you.

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Tue Aug 28, 2018 2:53 pm
by ssax
What are you seeing in your /usr/local/nagiosxi/var/wkhtmltox.log?

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Tue Aug 28, 2018 2:53 pm
by ssax
Additionally, when accessing the site using the web browser are you using the IP or a dns name in the address bar?

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Wed Aug 29, 2018 9:03 am
by dimsum
No file.
tailf: stat failed /usr/local/nagiosxi/var/wkhtmltox.log: No such file or directory

I access with IP address it was a match of the program url.

Thanks.

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Wed Aug 29, 2018 3:18 pm
by tgriep
When you try and export a pdf of jpg, what error are you receiving?
Can you screen capture the error and post it here?

Can you run the following commands so we can verify that the tool that creates the files is installed in the server and that the version is correct.

Code: Select all

/usr/bin/wkhtmltoimage -V
/usr/bin/wkhtmltopdf -V
It should be this version 0.12.1.3 (with patched qt)

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Wed Aug 29, 2018 7:16 pm
by dimsum
Hi,

[root@localhost scripts]# wkhtmltopdf -V
wkhtmltopdf 0.12.5 (with patched qt)
[root@localhost scripts]# wkhtmltoimage -V
wkhtmltoimage 0.12.5 (with patched qt)

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Wed Aug 29, 2018 8:14 pm
by dimsum
Additional: /var/log/httpd/error_log

The switch --disable-smart-shrinking, is not support using unpatched qt, and will be ignored.The switch --no-outline, is not support using unpatched qt, and will be ignored.The switch --footer-spacing, is not support using unpatched qt, and will be ignored.The switch --footer-font-size, is not support using unpatched qt, and will be ignored.The switch --footer-right, is not support using unpatched qt, and will be ignored.The switch --footer-left, is not support using unpatched qt, and will be ignored.wkhtmltopdf: cannot connect to X server

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Thu Aug 30, 2018 9:54 am
by lmiltchev
I see that you have "http" in the program URL, but are you by chance using SSL on this server? The newer versions of wkhtmltopdf have issues with SSL, so you need to downgrade from 0.12.5 to 0.12.1.3 (and use "https" in the program URL).

Try running:

Code: Select all

cd /tmp/nagiosxi/subcomponents/wkhtmltox
./install
Check the version number after you are done with the install:

Code: Select all

wkhtmltopdf -V

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Thu Aug 30, 2018 10:17 am
by dimsum
I run the command.

Code: Select all

cd /tmp/nagiosxi/subcomponents/wkhtmltox
./install
but get the same version
[root@localhost wkhtmltox]# wkhtmltopdf -V
wkhtmltopdf 0.12.5 (with patched qt)
How can I remove the old version?

Thanks.

Re: Failed to create PDF Verify that your Nagios XI server

Posted: Thu Aug 30, 2018 11:25 am
by lmiltchev
My bad - sorry. I forgot to tell you that you needed to uninstall the package first.

Run:

Code: Select all

rpm -e wkhtmltox
to uninstall the package.

Then install the correct version by running:

Code: Select all

cd /tmp/nagiosxi/subcomponents/wkhtmltox
./install