KNOWLEDGE BASE

Error "fatal error: OutOfMemory encountered: java heap space" and View Recommendations Backgrounder Task Fails


Published: 30 Oct 2019
Last Modified Date: 26 Nov 2019

Issue

After upgrading to Tableau Server 2019.4, when the backgrounder task for View Recommendations runs, an OutOfMemory error may be encountered for large sites approaching 5000 or more users.

The following error message may appear:
 
"A fatal error has been detected by the Java Runtime Environment:

Internal Error (debug.cpp:308), pid=30560, tid=0x0000000000002e38
fatal error: OutOfMemory encountered: Java heap space

JRE version: OpenJDK Runtime Environment (8.0_232-b02) (build 1.8.0_232-b02-b02)
Java VM: OpenJDK 64-Bit Server VM (25.232-b02 mixed mode windows-amd64 compressed oops)"

Environment

Tableau Server 2019.4

Resolution

Run the following commands in the TSM CLI:

tsm configuration set --key backgrounder.vmopts --value "-XX:+UseConcMarkSweepGC -Xmx1024m -Xms256m -XX:+CrashOnOutOfMemoryError -XX:-CreateMinidumpOnCrash"

This command changes the default amount of memory available to the backgrounder from 512MB to 1GB. 

Cause

The View Recommendations trainer builds a model based on usage data. For larger sites with many users, content, and usage activities, the Recommendations trainer will require more memory in order to complete the training activity. Increasing the available space for backgrounder resolves the problem.
 
Did this article resolve the issue?