Qlik Community

Knowledge

Search or browse our knowledge base to find answers to your questions ranging from account questions to troubleshooting error messages. The content is curated and updated by our global Support team

Announcements
IMPORTANT security patches for GeoAnalytics Server available to download: READ DETAILS

Advanced troubleshooting of the GRPC and or CEF Error Issues

cancel
Showing results for 
Search instead for 
Did you mean: 
Andre_Sostizzo
Digital Support
Digital Support

Advanced troubleshooting of the GRPC and or CEF Error Issues

NOTE: BEFORE PROCEEDING BELOW - Please check and validate minimum cipher requirements on the NPrinting and Qlik Sense server
 

==================================================================================

Charts should be exportable to an NPrinting report if in Qlik Sense:

  • Assistance/suggestions mode is disabled
  • The chart is a supported 3rd party extension and configured correctly as per specification (see "References" section)

Keep in Mind:

  • Certain Qlik Sense visualizations from the visualization bundle are not supportedSee compatibility matrix here: Creating a visualization using a custom object
  • For a listing of compatible, built-in Qlik Sense objects, check the compatibility matrix found in the following link to better understand specific Qlik Sense object limitations with NPrinting reporting. Working with Qlik objects

 

Environment

 

The information in this article is provided as-is and to be used at own discretion. Depending on tool(s) used, customization(s), and/or other factors ongoing support on the solution below may not be provided by Qlik Support.

Troubleshooting Steps:

  • Check that the internet options/proxy settings are cleared as per article NPrinting Issues to generate report and previews, connect to Qlik Sense apps, image and objects issu...
  • Check that NPrinting Engine and Server Internet Options are configured. See How to Configure NPrinting Server and NPrinting Engine computer Internet Options
  • Check that 'In' and 'Out' bound ports between the NPrinting server NPrinting engine and the Qlik Sense server are configured. Keep in mind that Ports 4997 and 443 must now also be configured since November 2018 release of NPrinting. (customers 'may' be missing these firewall exceptions during the upgrade process).
  • Check that ports 2727 and 15672 are not being used by any other process/program on the NPrinting server and engine computers. These ports are required for normal NPrinting operation. See Ports - Qlik NPrinting
  • Check that the Qlik Sense objects and or Qlik Sense visualization used in your NPrinting report are supported as per the "Keep in Mind" section above
  • Check if HTTP is used in the Proxy field of the NPrinting Connection to the Qlik Sense app in the 'Proxy Address' field. If yes, see article 
NPrinting Unexpected CEF rendering exception with HTTP connection...otherwise continue to the next points below
  • Check that the Qlik Sense Proxy default 'https://' listening port settings has not been changed.  Open the following link for more information: 
  • Check for the use of a Qlik Sense proxy 'prefix' in the QS QMC. If one exists, via the NP web console, the prefix must be added to the NP connection string ie: https://qlikserver1.qlik.com/qlik
  • If you have a version of NPrinting prior to June 2018 (April 2018 and lower versions), please upgrade to the most recent version of NPrinting to ensure that the following log file folder becomes available "reporting_web_renderer_logs" as well as to leverage the most recent performance enhancements, product defect fixes and improved logging information
Zip and upload C:\ProgramData\NPrinting\Logs\reporting_web_renderer_logs folder to your Qlik Support case.
  • Check the NP logs for 'Websocket' errors. If found check this article to resolve that issue. 
  • Abort all running Task and On Demand Task executions then reboot the NPrinting Server, NPrinting Engine computer and the Qlik Sense server at the first available opportunity and retest if the issue still persists. Ensure all services on each computer are up and running before retesting...this is critical
  • If the issue persists after checking all points above, please check the solutions in the resolutions section of this article.
  • It may be useful to Enable performance logging on the Qlik Sense server to verify if it is being heavily taxed while NPrinting reports and or report publish tasks etc are being executed. 

 

Resolutions:

  • Possible resolutions if the issue is not related to Chart Assistance or Unsupported 3rd party or incorrectly configured extensions:
  • Ensure your version of NPrinting is a current, supported version to leverage many defect fixes which need to otherwise be resolved manually in the steps below


Resolution 1 - Fully Qualified Domain Name path or some other parameter of the original Qlik Sense server certificates may have changed. Use the following article to resolve this issue:


! To ensure editing the correct file, please do the following before proceeding as directed below:
  • Open windows File Explorer
  • Click 'View' tab
  • In 'Show/Hide' area of the 'View' ribbon, Click checkbox "File Name Extensions" in order to show the full file name

 

Resolution 2 - GRPC error: Check NP CEF Engine log file: May be represented by the error: "The remote server returned an error: (401) Unauthorized"
(Internal JIRA defect reference: OP-8814)

  • Check that the path to the QMC proxy is the same as the connection path used in the NP connection proxy address path
Example Scenario 
- a customized configuration that uses a non-default url proxy address path is configured in the Qlik Sense environment. If so, this path must also be use in the NPrinting proxy address connection field within your NPrinting connection. In this example, 'default' is appended in this custom Qlik Sense proxy configuration
- "https://myqliksenseserver1.qliklocal.com/default/"
- In your 'customized configuration', if you use "https://myqliksenseserver1.qliklocal.com" in your NP connection 'proxy' address field, then you will receive the (401) unauthorized message in the NPrinting CEF log file. Your QS server in this instance is expecting 'default' in the connection string. (This is similar to ensuring that if you are using a 'Prefix' path in Qlik Sense, you must also use the prefix path in the NP connection 'proxy' address field.)
- in most cases, the typical path to the proxy address that should also be used in the NPrinting connection 'proxy' path is https://myqliksenseserver1.qliklocal.com. See the following to correctly configure your NPrinting Connections to Qlik Sense.  See Connecting to Qlik Sense apps.
  • You must also ensure that port 443 and port 4997 are not blocked in your environment as mentioned in the article description

 

Resolution 3: Switch to a Dedicated NPrinting Service Account or Upgrade to NPrinting June 2019 release or later.
! If you are running NPrinting June 2019 release or newer versions, this step can be skipped

If you are using the Qlik Sense ROOTADMIN account as the identity in your NPrinting connections, switch to the NPrinting service account as the identity for your NPrinting Connections. Ensure that your Dedicated NPrinting service account has a token assigned to it. Using the QS ROOTADMIN has been found to cause conflicts with concurrent Qlik Sense and NPrinting Tasks and other background executions.

If a dedicated NP service account is not available, you may need to configure one and perform the following configuration steps before using it:

  • Add the new NP service account to the local administrators group on the NPrinting server
  • Ensure the new service account is made to be ROOTADMIN on the Qlik Sense server (attempt to log on just once with the new service account to view the new account in the Qlik Sense QMC 'users' list
  • Assign a token (or analyzer license) to the new NPrinting service account
  • Log on to the NPrinting server with the NPrinting server service account and re-import the Qlik Sense certificates  Exporting and installing Qlik Sense certificates
  • Update the three NPrinting services to use the new NPrinting service account: NPrinting Engine, NPrinting Scheduler and NPrinting Web Engine
  • Update your NPrinting connection to use the new NPrinting service account 
  • Reload the metadata again and retest

ReferenceConnecting to Qlik Sense apps

*Note: that If the NPrinting Engine goes offline after switching the three NPrinting services, you will need to uninstall the NPrinting Engine software, delete the NPrinting Engine from the NP management console, then follow the steps in the following link to correctly reinstall and reconnect the NPrinting Engine Installing Qlik NPrinting Engine

If the above does not solve the issue, go to resolution 3. (The NPrinting Engine should be in an 'Online' state before proceeding to Resolution 3).


Resolution 4 - If the NPrinting Error logging or preview errors contain the message "CEF rendering exception - "Buffer cannot be Null" go to the following article for the solution: 

 

! Please make a backup copy your config file before proceeding to either steps 4 or 5 below, to ensure reliable rollback to original file if needed. Modifying this or any NPrinting configuration file incorrectly will lead to abnormal system operation and behavior. This change must be done with great care and attention*

Resolution 5 - If Resolution 1 and 2 above do not resolve the issue and all image export requirements are met, check and perform the steps below:

Part 1:
April 2020 NPrinting and earlier versions only (please see Part 2 of this resolution below for versions of NPrinting June 2020 and later)

  • Stop the NPrinting Engine and Scheduler services
  • Backup/make a copy of the Engine.config file in "C:\Program Files\NPrintingServer\NPrinting\Engine" on the NPrinting Engine machine. (You can open/edit this file in Notepad)
  • Open the Engine.config file
  • Search for these rows in the engine.config file:
Engine.config Default state:
 <!-- rendering timeout for the whole render method at the renderer -->
 <!-- <add key="webrenderer-remote-request-timeout-msec" value="60000" /> -->
 <!-- rendering timeout for a JavaScript render method at the renderer -->
 <!-- <add key="webrenderer-remote-request-js-timeout-msec" value="30000" /> --> Note that this value must be equal to or less than the 'rendering timeout for the whole render method at the renderer' value
  • Remove 'open' and 'close' comments  <!--    -->  syntax from the timeout-msec and js-timeout-msec .
  • The updated section above should appear as below. (This will increase time outs to 2 minutes (120,000 ms) timeouts of 1 minute (60,000 ms) and 30 seconds (30,000 ms) default timeout values respectively)
NP Engine.config Increased time out values (see example below):
<!-- rendering timeout for the whole render method at the renderer -->
<add key="webrenderer-remote-request-timeout-msec" value="120000" /> 
<!-- rendering timeout for a JavaScript render method at the renderer -->
<add key="webrenderer-remote-request-js-timeout-msec" value="120000" />

 

  • Save the changes in the Engine.config file. (Be sure that the extension is .config and not .config.txt)
  • Abort ALL "Running" status NPrinting Connection, NPrinting Publish Task and NPrinting On Demand executions
  • Restart all NPrinting services
  • Preview your NP report or run your NP Publish Task again

Part 2
June 2020 NPrinting and later versions

  • Stop the NPrinting Engine Service.
  • Open the renderer.config file in C:\Program Files\NPrintingServer\NPrinting\Scheduler. You may need to open the file in administrator mode.
  • Add (or modify if present) the following parameter:
    <add key="webrenderer-timeout-sec" value="120" />
    120 is the time in seconds for the timeout. It can be increased further if necessary.
  • Restart the NPrinting Engine service

Increasing these timeout values may lead to improved performance as NPrinting may simply need more time to execute tasks and report generation due to:

  • Complex report requirements
  • Network infrastructure stability and performance issues

Resolution 6 - If the NPrinting Error logging or preview errors contain the message "Connect Failed" 

  • The permanent fix is available in February 2020 release of NPrinting.
  • This issue is also resolved in two patches for following but we strongly advise to upgrade to the latest release of NPrinting
    • April NPrinting Engine Only 2019 release 
    • June NPrinting Engine Only 2019 release
    • NOTE: These patches are only available upon request
    • Patches not planned for any other versions. Please upgrade to the latest NP version to resolve this issue.

! If one of the resolutions paths above that required a config file change has worked for you, please note config file changes are not preserved during the upgrade process. Therefore, you will need to manually make the same config file updates following any future upgrades until otherwise directed. Product release notes available with each new version release download will advise of any such updates.

How to Enable 'Tracing'

If resolutions above have not resolved the issue, please perform the following steps and reproduce the issue one again in order to retrieve additional tracing information necessary for a deeper investigation. Then zip and upload the requested folder below up to the support case. 

June 2020 and newer versions - Enable CEF tracing

April 2020 and earlier versions - Enable CEF tracing

  • Stop Engine Service
  • Clear the contents of the log folder at C:\ProgramData\NPrinting\Logs\reporting_web_renderer_logs
  • Open engine.config (in the NPrinting engine installation folder) as a computer administrator
  • Add the following two lines just before the enclosing </appSettings> tag
  • <add key="webrenderer-args" value="-l=trace -grpc-addr=127.0.0.1:51051" />
  • <add key="webrenderer-mashup-qs" value="logging=net,ws" />
  • Save the file (ensure that the file is saved as engine.config, not engine.config.txt)
  • Restart NPrinting Engine service
  • Reproduce the issue
  • Zip the C:\ProgramData\NPrinting\Logs\reporting_web_renderer_logs folder and upload to your Qlik Support case.

 

Causes:

Possible causes of GRPC error

  • assistance/suggestions mode is enabled (it is currently on the road map to have this feature fully supported)
  • the chart is an unsupported 3rd party extension (map extensions for example). See article below regarding Qlik Sense extensions and how to enable them for image export.
  • In some cases, image web rendering default time while connected to Qlik Sense needs to be adjusted perhaps due to network latency or other network performance related issues
  • Communication between the NPrinting server and the Qlik Sense server is discovered to be problematic.
  • The Qlik Sense server itself could be overloaded and not responding to the NPrinting server in a timely manner.
  • When NPrinting is used in conjunction with Qlik Sense Deployments From September 2018 and higher where "HTTP" is used rather than "HTTPS", specific CEF or GRPC errors will be logged. See article Qlik NPrinting Unexpected CEF rendering exception with HTTP connection for more information.
  • Certificate mismatch as identified in article NPrinting Verification process does not capture certificate FQDN mismatch in turn resulting in GRPC ...
  • Invalid path used in the NP connection 'proxy' address path. Path used with the NP connection should be the same as the path used to open the QMC or QS Hub
  • QS and NP version requirement update due to new license model: In an nutshell, unless customers that upgrade Qlik Sense to the new Professional/Analyzer license model also upgrade to NPrinting June 2019 or higher, they will need to take the actions outlined in this article:
  • NPrinting normal operation fails after upgrade to Qlik Sense April 2019 Patch 1 
  • Error logging to look for NPrinting Logs: "Failed to open a resolver for connection" and "The remote server returned an error: (403) Forbidden"
  • To mitigate license allocation entirely (Token or New license model with Analyzer licenses) simply upgrade to NPrinting June 2019 or later releases.


Reference

Version history
Last update:
‎2022-03-08 05:59 AM
Updated by: