In the Qlik.Sense.Logging.log file, any of the following is registered:
[Qlik.Logging.Service.exe] Qlik.Logging.Service [ERROR] - DevartLogDatabase::Connect failed! Exception: No connection could be made because the target machine actively refused it 172.16.16.101:4432 ... [ERROR] - Failed to retrieve settings from database. Error: ["DevartLogDatabase::Connect failed!\nException:\n\tNo connection could be made because the target machine actively refused it 172.16.16.101:4432\n"]
... [Qlik.Logging.Service.exe] Qlik.Logging.Service [ERROR] - Failed to initialize database. ["DevartLogDatabase::Connect failed!\nException:\n\tNo connection could be made because the target machine actively refused it 172.16.16.101:4432\n"]
May also see the following:
Qlik.Logging.Service [ERROR] - DevartLogDatabase::Connect failed! Exception: No such host is known
Qlik Sense Enterprise on Windows, February 2019 and later
1. The Qlik Sense Server postgreSQL is not listening on the correct IP address
2. The connection string to the QLogs database has not been updated with the new server hostname
For Cause 1 above:
Modify the listen_addresses setting in the postgres.conf file to listen on the address mapped to the new hostname.
Note: Make sure to make a backup copy of postgres.conf before modifying it to contain either a wildcard (e.g "*", as shown on image below) or the new hostname (e.g: the server's FQDN).
The file is found under the following path on the Central node:
Verify the hostname is showing in the connection string as shown on the image below, and per II.1 below.
Make sure CentralizedLoggingEnabled is true, and start the Qlik Logging Service in services.msc.
II. Change the hostname: Connection String Editor
Change the hostname with the Qlik Sense "connection string editor"
1. Check the Connection string set in: C:\ProgramData\Qlik\Sense\Log\QlikCentralizedLogging.config
To do this, use QlikSenseUtil.exe
Go to %Program Files%\Qlik\Sense\Repository\Util\QlikSenseUtil.
Open QlikSenseUtil.exe as Admin (right-lick > run as administrator).
In QlikSenseUtil.exe > connect to the database with your superuser password then select "Connection String Editor".
In the file path to config file, place C:\ProgramData\Qlik\Sense\Log\QlikCentralizedLogging.config
Compare the host set in the connection string with the current FQDN of the server
If the hostname is different, first backup file C:\ProgramData\Qlik\Sense\Log\QlikCentralizedLogging.config before making any change
2. Try to modify the hostname in your connection string, and hit the save button.
Make sure your file has been changed by clicking the "read" button afterwords.
3. In case your Connection string cannot be changed please try III.
III. Change the hostname: Config file changes
Change the hostname by editing QlikCentralizedLogging.config
Note that this solution is a workaround in case point II. did not work, By applying this change the centralize logging connection string will be set in clear text and will be no longer encrypted. Make sure to let the customer aware about this.
Backup file C:\ProgramData\Qlik\Sense\Log\QlikCentralizedLogging.config before making any change
Edit QlikCentralizedLogging.config as follows
Copy the current connection string in a text editor, by using the QlikSenseUtil.exe . Please refer to II.1) to do this
open file C:\ProgramData\Qlik\Sense\Log\QlikCentralizedLogging.config
Find and remove "<connectionStrings configProtectionProvider="DataProtectionConfigurationProvider"> " all the way to " </connectionStrings>"
Replace with with the connection string you saved in a., corrected with the new server FQDN