Community Articles

Find and share helpful community-sourced technical articles.
Labels (1)

PROBLEM: Some users may be associated to many groups causing a very long list of groups to be passed through the Rest APIs headers in Ranger and KMS.

ERROR:

error log from /var/log/ranger/kms/kms.log

2016-12-01 14:04:12,048 INFO Http11Processor - Error parsing HTTP request header 
Note: further occurrences of HTTP header parsing errors will be logged at DEBUG level. 
java.lang.IllegalArgumentException: Request header is too large 
at org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:515) 
at org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:504) 
at org.apache.coyote.http11.InternalInputBuffer.parseHeader(InternalInputBuffer.java:396) 
at org.apache.coyote.http11.InternalInputBuffer.parseHeaders(InternalInputBuffer.java:271) 
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1007) 
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:625) 
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316) 
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) 
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) 
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) 
at java.lang.Thread.run(Thread.java:745) 
2016-12-01 14:04:12,074 INFO Http11Processor - Error parsing HTTP request header 
Note: further occurrences of HTTP header parsing errors will be logged at DEBUG level. 
java.lang.IllegalArgumentException: Request header is too large 
at org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:515) 
at org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:504) 
at org.apache.coyote.http11.InternalInputBuffer.parseHeader(InternalInputBuffer.java:396) 
at org.apache.coyote.http11.InternalInputBuffer.parseHeaders(InternalInputBuffer.java:271) 
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1007) 
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:625) 
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316) 
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) 
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) 
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) 
at java.lang.Thread.run(Thread.java:745) 

ROOT CAUSE: Rest API calls being passed with large headersizes in this case users with large amount of groups that exceed the webservers maxHttpHeaderSize.

SOLUTION:

In Ambari go to Ranger Admin->config->Advanced Tab->Custom ranger-admin-site->Add Property. Put ranger.service.http.connector.property.maxHttpHeaderSize in Key field and provide the required value for maxHttpHeaderSize attribute in Value field.

Save the changes and then go to Ranger KMS->config->Advanced Tab->Custom ranger-kms-site->Add Property. Put ranger.service.http.connector.property.maxHttpHeaderSize in Key field and provide the required value for maxHttpHeaderSize attribute in Value field.

Save the changes and restart all Ranger and Ranger KMS services.

1,428 Views
Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.
Version history
Last update:
‎12-27-2016 07:51 PM
Updated by:
Contributors
Top Kudoed Authors