Troubleshooting

Troubleshooting may be needed when Qlik NPrinting does not behave as expected (for example, if the system responds with an error message that needs further investigation or does not respond at all when an error occurs).

Logs

The log messages produced by Qlik NPrinting provide important information that can be used to detect security incidents, operational problems, and policy violations.

Where are the log files stored?

Logs are stored in the %ProgramData%\Nprinting\Logs folder. The default location is C:\ProgramData\NPrinting\Logs.

How to change the log level

The log level is set to INFO by default. To change the log level to DEBUG or WARN, edit the following files with a text editor, and then restart the corresponding service:

  • C:\Program Files\NPrintingServer\NPrinting\Engine\Qlik.NPrinting.Engine.exe.config
  • C:\Program Files\NPrintingServer\NPrinting\Scheduler\Qlik.NPrinting.Scheduler.exe.config
  • C:\Program Files\NPrintingServer\NPrinting\WebEngine\Qlik.NPrinting.WebEngine.exe.config

Search for an entry such as <level value="INFO" />, and then change the value according to your needs.

Qlik NPrinting 17 license error

Possible cause  

The Qlik NPrinting 17 license was not activated. After installation, a message like the following is shown in the scheduler log file:

FATAL Qlik.NPrinting.Repo.Service.LicenseService - !!!!!!!!!!!!!!!! LICENSE VIOLATIONS DETECTED

FATAL Qlik.NPrinting.Repo.Service.LicenseService - The number of USERS exceeds the current license limit (1 found, but 0 allowed).

INFO Qlik.NPrinting.Scheduler.SchedulerHttpService - Scheduler service started successfully

INFO Qlik.NPrinting.Repo.Service.LicenseService - License expiration is close. Checking for license update...

ERROR Qlik.NPrinting.Repo.Service.SessionManager - Error within WithSession method of SessionManager.

ERROR Qlik.NPrinting.Repo.Service.SessionManager - Invalid License key

ERROR Qlik.NPrinting.Repo.Service.LicenseService - Qlik.NPrinting.Repo.ServiceException: Invalid License key

at Qlik.NPrinting.Repo.Service.LicenseService.UpdateLicense() in c:\Users\LED\Desktop\repo\opera\server\NPrinting\src\Repo\Service\LicenseService.cs:line 243

at Qlik.NPrinting.Repo.Service.LicenseService.AutoUpdateIfCloseToExpiration() in c:\Users\LED\Desktop\repo\opera\server\NPrinting\src\Repo\Service\LicenseService.cs:line 331

at Qlik.NPrinting.Repo.Service.SessionManager.<>c__DisplayClass7.<WithSession>b__6(ISession s) in c:\Users\LED\Desktop\repo\opera\server\NPrinting\src\Repo\Service\SessionManager.cs:line 57

at Qlik.NPrinting.Repo.Service.SessionManager.WithSession[T](Func`2 body, IsolationLevel isolationLevel, Boolean readOnly) in c:\Users\LED\Desktop\repo\opera\server\NPrinting\src\Repo\Service\SessionManager.cs:line 116

at Qlik.NPrinting.Repo.Service.LicenseService.<Start>b__5() in c:\Users\LED\Desktop\repo\opera\server\NPrinting\src\Repo\Service\LicenseService.cs:line 301

Proposed action  

Log into the web console as an administrative user at https://YourServer:4993, and then activate the license.

Qlik NPrinting Engine without QlikView Desktop license

Possible cause  

The Qlik NPrinting Engine needs QlikView Desktop installed, with a license activated for the Windows user that runs the service.

Proposed action  

Activate one of the following QlikView Desktop licenses:

  • Local license
  • Assigned CALs (by user name)

Qlik NPrinting does not work with dynamically-assigned CAL.

If you use assigned CALs, you need to connect the QlikView Desktop to the QlikView Server at least one time, at the beginning, using the same Windows user and computer as the Qlik NPrinting Engine service.

Do the following:

  1. Find Qv.exe in the installation path.
  2. Press and hold SHIFT, right-click Qv.exe, and then select Run as different user.
  3. Open a .qvw document in the QlikView Server by using qvp. This will bind the license.
  4. Close QlikView Desktop.
  5. Restart the Qlik NPrinting Engine service.

Check also that the engine is enabled.

Do the following:

  1. Open the Qlik NPrinting Web Console.
  2. Select Admin.
  3. Click Engine manager.
  4. The Enabled check box must be selected.

Qlik NPrinting Engine Offline status

Possible cause  

A Qlik NPrinting Engine always shows "Offline" status in the Engine manager page.

Proposed action  

Do the following:

  1. If an engine goes offline a few seconds after starting, check the nprinting_engine.log file stored on the computer. The text QlikView license violation detected means that you have to activate a QlikView Desktop license for the Windows user who runs the service.
  2. Check that the Qlik NPrinting Engine and the Qlik NPrinting Scheduler services and processes are running. A failure of the Qlik NPrinting Scheduler can cause the engine status to not be updated.
  3. If Qlik NPrinting Scheduler and Qlik NPrinting Engine are running on different computers, or if you provided a machine name or a fully qualified domain name (FQDN) to the Qlik NPrinting Engine installer (including localhost), check that port 5672 is open for inbound connections on the Qlik NPrinting Scheduler computer.
  4. If you used localhost for the machine name during the engine installation, open a command prompt (cmd.exe) and check that ping localhost works. Some DNS configurations prevent localhost from being resolved to the loopback network interface.
  5. Check that the machine name is correct in the Engine manager page. Do not use a fully qualified domain name (FQDN) or localhost.
  6. Check that the engine and scheduler logs do not show connection errors or other failures. If failures show, refer to their troubleshooting help to resolve the failure, then restart the services.

Qlik NPrinting Engine Error status

Possible cause  

The QlikView Desktop license for the Windows user who runs Qlik NPrinting services is not activated. An engine shows Error status in the Engine manager page. In case of single engine installation, reports are not produced.

Proposed action  

Activate the QlikView Desktop license for the Windows user who runs Qlik NPrinting services.

Also check the Qlik NPrinting log files to be sure that there are no other errors.

Troubleshooting RabbitMQ startup and connection problems

Possible cause  

If reports are not produced or engines never go to Online status, or if the scheduler service stops after about one minute from startup, the RabbitMQ service may be stopped.

The scheduler log shows a message like:

2016-01-21 16:45:58,404 FATAL:

*********************************************

Error: RabbitMQ message broker is unreachable

Shutting down scheduler service

*********************************************

2016-01-21 16:46:12,102 FATAL: Unable to start SchedulerService: exception of type System.AggregateException

One or more errors occurred.

Proposed action  

  1. Check that RabbitMQ service is running.
  2. If it is, open the Windows command line console (cmd.exe).
  3. In the command line move the RabbitMQ command prompt (sbin dir) by using the command cd "C:\Program Files (x86)\RabbitMQ Server\rabbitmq_server-3.5.4\sbin" (the path may be different, depending on the installation folder).
  4. Type the command rabbitmqctl.bat list_permissions and press Enter. The following lines must be displayed:

    Listing permissions in vhost "/" ...

    guest .* .* .*

    remote .* .* .*

If you see connection errors instead, refer to the Erlang cookie section in the RabbitMQ Clustering Guide. After fixing RabbitMQ errors, restart the Qlik NPrinting Scheduler, Qlik NPrinting Web Engine and Qlik NPrinting Engine services.

Connection timeouts and long running tasks

Possible cause  

In heavy loading scenarios, where several report generation tasks are being scheduled every second for a long time, and the tasks take perhaps a long time to complete, it is possible that all available connections to the PostgreSQL database are allocated, causing errors that are logged.

Proposed action  

Check the Qlik NPrinting Scheduler log file nprinting_scheduler.log. In case of database connection issues or timeouts during wait from pooled connections confirms limit problems. The maximum number of connections to the PostgreSQL database needs to be increased.

Do the following:

  1. Log into the computer where the Qlik NPrinting Scheduler service is running. The PostgreSQL database is located in this machine
  2. Open the C:\Program Files\PostgreSQL\9.xx\data folder.
  3. Open the postgresql.conf file with a text editor.
  4. Find the parameter max_connections. The parameter is set to 100 by default.
  5. Set max_connections to a greater value.
  6. Restart the Qlik NPrinting Scheduler service.

Connection status empty

Possible cause  

If the connection status is not shown in the Qlik NPrinting Web Console, consider that the connection status is set the first time the QlikView document is opened to generate the connection cache or a report. If you already started such a task on the connection, the task is queued and the status should be set soon.

Proposed action  

Typically, a status update takes 15-30 seconds after the first task is launched. Longer time can be necessary if other reports are already running on available engines.

Connection status Error

Possible cause  

The connection status is an error state if no engine can open the document for the connection.

Proposed action  

If you encounter problems when creating connections, perform the following steps.

  1. Check that local path and name of the .qvw file are correct. Remember to use full path including drive and file extension. Open QlikView Desktop, and then open the .qvw file by copying and pasting the path.
    It does not matter if the .qvw file is local, on a network folder, or on a server. You must be able to open the document from QlikView Desktop.
  2. If you are using a local connection and a local path to the document, the document has not been copied to the machine the engine is running on, but only on the scheduler machine or in another engine.
  3. If you are using a network path in the connection, be sure that the network share is reachable from the engine.
  4. Mapping a network drive is not supported; use a UNC (Universal Naming Convention) instead. For example, you must use \\ServerName\DocumentFolder\document.qvw.
  5. If you are using a server connection, be sure that the server path is correct. Remember to also include folders in the server path, if they are being used on the server.
  6. If you are using a server connection, be sure that the server is reachable from the engine machine.
  7. If you are using a server connection, be sure to use the same versions of both QlikView Server and QlikView Desktop installed in the engine computer. Opening the document manually in QlikView Desktop on the engine may be working correctly, but cache generation will fail in case of different versions.
  8. Make sure that QlikView Desktop has an active license for the Windows user who is running the engine service. Find the Qv.exe file in its installation path. Hold down SHIFT, and then right-click the file. Select Run as a different user, and then enter the credentials of the Qlik NPrinting Windows user. Make sure that the QlikView version used is not QlikView Personal Edition, which is not supported.
  9. If you have Windows Interactive Service Detection active, click View the message, and then check the status of QlikView open in session zero. Messages may contain useful information, such as a request to execute a macro in the source .qvw file.
  10. Check the logs in the %ProgramData%\NPrinting\Logs folder for errors.

Connection status is Warning and One or more engines are not working.

Possible cause  

A Warning connection status with the message One or more engines are not working happens in a multi-engine environment when the connection fails in one of the engines. Other engines may be working correctly on the same connection, or have not tried to open the connection yet.

Proposed action  

Check engine logs on the computers where they are installed to find which engine is failing.

Perform connection troubleshooting on the failing engine. Be sure that QlikView documents and network shares are accessible or QlikView Server are reachable from that particular machine.

Initial error in webengine log (parameterless constructor)

Possible cause  

An error, like the following, is visible in the Qlik NPrinting Web Engine log file nprinting_webengine.log:

2016-01-11 17:39:50,430 [19] ERROR Qlik.NPrinting.WebEngine.ExceptionHandling.GenericTextExceptionHandler - Unhandled exception in request:http://c4w07345.itcs.hpecorp.net:4996/npe/tasks/publish?count=5&orderBy=-lastUpdate&page=1.

Exception: An error occurred when trying to create a controller of type 'PublishReportTasksController'. Make sure that the controller has a parameterless public constructor.

Proposed action  

The error could appear when a not logged in user attempts to access the Qlik NPrinting Web Console. It should disappear after login.

It is due to a path in the home page that is not accessible by not logged in users. This error does not cause report creation failure.

Impossible scheduling plans

Possible cause  

The Qlik NPrinting Scheduler log file nprinting_scheduler contains an Impossible plan message like the following:

2016-01-04 13:04:50,033 [8] WARN Qlik.NPrinting.Scheduler.Service.LoadBalancer - Impossible plan connecting connections

cbd2 4073 WLoad #Req Startup Shutdown

39b7 0 0 3000 3 5000 500

327b 0 1 - - - -

4 4

This log message appears when optimization of the allocation of QlikView instances to different connection is impossible due to computation constraints.

Proposed action  

The message should disappear with the decrease of work queue in the engines.

If the message persists:

  1. Check that the number of requests, displayed in the #Req column, is decreasing.
  2. Check that Qlik NPrinting Engine is working correctly and is showing no failures.

If the number of requests is not decreasing or the Qlik NPrinting Engine is showing failures, restart the Qlik NPrinting Engine service.

Navigator stuck messages

Possible cause  

Messages like the following appear:

2015-12-02 18:13:58,935 [34] WARN Engine.Navigator.QlikView.QV11.QlikViewNavigator.[25064]::navigator=qlikview;documentpath=C:\nprinting\global\dashboard.qvw - QlikView CPU monitor: process seems stuck due to cpu usage of 76.05 % in 1238ms. Waiting for idle for 2000ms

2015-12-02 18:13:59,111 [34] WARN Engine.Navigator.QlikView.QV11.QlikViewNavigator.[25064]::navigator=qlikview;documentpath=C:\nprinting\global\dashboard.qvw - QlikView CPU monitor: process is stuck due to cpu usage of 65.00 % in 1414ms

2015-12-02 18:13:59,111 [34] WARN Engine.Navigator.QlikView.QV11.QlikViewNavigator.[25064]::navigator=qlikview;documentpath=C:\nprinting\global\dashboard.qvw - QlikView CPU monitor: process returned to normal a normal cpu usage of 12.06 % in 1302ms

These messages are produced by a health check on the QlikView process that is generating the report. In case of processing errors that cause excessive CPU usage, the process is monitored and terminated if it appears locked. The messages show two error states and a "back to normal usage" message, respectively.

Proposed action  

This situation is expected to correct itself. If the monitor shows normal usage, nothing is performed, otherwise QlikView is closed and reopened to allow further report generation. If error messages persist for the same document, check that connected QlikView documents are accessible by Qlik NPrinting Engine and contain no errors when open manually using QlikView.