The Qlik Sense License Service fails to start.
The log files read:
{"caller":"main.go:616","level":"error","message":"failed to create message queue client: pq: relation \"sensemq\" does not exist"
The sensemq table is missing in the Postgres database QSMQ.
If the table exists, it is missing properties.
For instructions on how to connect to the database, see How To Connect To And Modify The PostgreSQL Database Used For Qlik Sense Repository.
Resolution:
If the table is not found, restarting the services won't generate the table again nor repairing the installation. The simplest way is to rerun the configuration script
- Back up the QSMQ database. See Backup and restore Qlik Sense Enterprise on Windows.
- If a QSMQ table already exists drop the QSMQ database and recreate a new one using template0. If not continue with step 3 immediately.
dropdb -h localhost -p 4432 -U postgres QSMQ
createdb -h localhost -p 4432 -U postgres -T template0 QSMQ
Reference: Restoring a Qlik Sense Site
- Start a PowerShell prompt in administrator mode and run:
cd C:\ProgramData\Qlik\Sense\QSMQ\scripts
.\SetupDatabase.ps1 -databaseHost localhost -databasePort 4432 -databaseUser qliksenserepository -databaseUserPassword Password
The output will show:
Creating database schema for database 'QSMQ'
Applying database schema version 1
Environment:
Qlik Sense Enterprise on Windows