How To Solve Issues Related to Log – MaxContentLength set to high value; resetting it to 100mb

Prevent Your Next ELK Incident

Try our free Check Up to test if your ES issues are caused from misconfigured settings

Fix Issue

Updated: Jan-20

In Page Navigation (click to jump) :
Troubleshooting Background       
Related Issues  
Log Context
About Opster

Opster Offer’s World-Class Elasticsearch Expertise In One Powerful Product
Try Our Free ES Check-Up   Prevent Incident

Troubleshooting background

To troubleshoot Elasticsearch log “MaxContentLength set to high value; resetting it to 100mb” it’s important to understand common problems related to Elasticsearch concepts: rest-high-level. See detailed explanations below complete with common problems, examples and useful tips.

Rest-high-level in Elasticsearch


Rest-high-level is built on top of low-level rest-client and is a method of communicating with Elasticsearch based on HTTP REST endpoints. This concept is majorly popular in the context of a Java-based Elasticsearch client. From day one, Elasticsearch supports transport clients for Java to communicate with Elasticsearch. In version 5.0, a low-level rest-client was released with lots of advantages over the existing transport client such as version independencies, increased stability, and lightweight JAR file libraries.

What it is used for

It is used for communicating with Elasticsearch HTTP REST endpoints in which marshalling and unmarshalling of response objects are handled by the Elasticsearch server itself.


To help troubleshoot related issues we have gathered selected Q&A from the community and issues from Github , please review the following for further information :

1 Github Issue Number 11244  

2Github Issue Number 2237  


Log Context

Log ”MaxContentLength[{}] set to high value; resetting it to [100mb]” classname is Netty4HttpServerTransport.java
We have extracted the following from Elasticsearch source code to get an in-depth context :

         this.pipeliningMaxEvents = SETTING_PIPELINING_MAX_EVENTS.get(settings);
        this.corsConfig = buildCorsConfig(settings);

        // validate max content length
        if (maxContentLength.getBytes() > Integer.MAX_VALUE) {
            logger.warn("maxContentLength[{}] set to high value; resetting it to [100mb]"; maxContentLength);
            deprecationLogger.deprecated(
                    "out of bounds max content length value [{}] will no longer be truncated to [100mb]; you must enter a valid setting";
                    maxContentLength.getStringRep());
            maxContentLength = new ByteSizeValue(100; ByteSizeUnit.MB);
        }






About Opster

Incorporating deep knowledge and broad history of Elasticsearch issues. Opster’s solution identifies and predicts root causes of Elasticsearch problems, provides recommendations and can automatically perform various actions to manage, troubleshoot and prevent issues.

Learn more: Glossary | Blog| Troubleshooting guides | Error Repository

Need help with any Elasticsearch issue ? Contact Opster

Did this page help you?