Support Questions

Find answers, ask questions, and share your expertise

How to Increase Ranger Admin Heap Size?

avatar
Super Collaborator

How can the heap size of the Ranger Admin service be increased? What is a good recommended value?

1 ACCEPTED SOLUTION

avatar
Rising Star

Preferred way is to create a file like ranger-admin-env00-java_mem.sh in /etc/ranger/admin/conf and have the following values:

JAVA_OPTS=" -XX:MaxPermSize=256m -Xmx1024m "

export JAVA_OPTS

In this way, even when Ranger is upgraded, your custom overrides are still there.

View solution in original post

3 REPLIES 3

avatar
Expert Contributor

What is the reason for increasing the heap? Are you seeing OOM errors due to too many users?

avatar

You can edit JAVA_OPTS property in below file. You can leave the default 1g. It should work fine.

In HDP 2.2:

/usr/hdp/2.2.x/ranger-admin/ews/start-ranger-admin.sh

In HDP 2.3:

/usr/hdp/2.3.x/ranger-admin/ews/ranger-admin-services.sh

avatar
Rising Star

Preferred way is to create a file like ranger-admin-env00-java_mem.sh in /etc/ranger/admin/conf and have the following values:

JAVA_OPTS=" -XX:MaxPermSize=256m -Xmx1024m "

export JAVA_OPTS

In this way, even when Ranger is upgraded, your custom overrides are still there.