Increase RLIMIT-MEMLOCK (ulimit). – How to solve related issues

Opster Team

Feb-20, Version: 1.7-8.0

Before you begin reading this guide, we recommend you run Elasticsearch Error Check-Up which analyzes 2 JSON files to detect many errors.

Briefly, this error message usually indicates that Elasticsearch has hit the memory limit that has been set on the system for locked memory, which is a type of memory that is not allowed to be swapped to disk. To resolve this issue, the memory limit needs to be increased by updating the “RLIMIT_MEMLOCK” parameter in the ulimit configuration. This can be done by editing the /etc/security/limits.conf file and adding the following line: “* hard memlock unlimited”.

To easily locate the root cause and resolve this issue try AutoOps for Elasticsearch & OpenSearch. It diagnoses problems by analyzing hundreds of metrics collected by a lightweight agent and offers guidance for resolving them.

This guide will help you check for common problems that cause the log ” Increase RLIMIT-MEMLOCK (ulimit). ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: bootstrap.

Log Context

Log “Increase RLIMIT_MEMLOCK (ulimit).” classname is
We extracted the following from Elasticsearch source code for those seeking an in-depth context :

                                 "\t" + user + " hard memlock unlimited"
                    logger.warn("If you are logged in interactively; you will have to re-login for the new limits to take effect.");
            } else {
                logger.warn("Increase RLIMIT_MEMLOCK (ulimit).");
    static String rlimitToString(long value) {


How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?

Analyze your cluster & get personalized recommendations

Skip to content