# Error: shield.authc.esnative

**URL:** <https://discuss.elastic.co/t/error-shield-authc-esnative/64081>\
**Category:** Elasticsearch\
**Tags:** elastic-stack-security\
**Created:** [October 27, 2016, 2:12am UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081 "2016-10-27T02:12:35Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![piyush](https://avatars.discourse-cdn.com/v4/letter/p/ecb155/32.png) [@piyush](https://discuss.elastic.co/u/piyush)\
**Post date:** [October 27, 2016, 2:12am UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/1 "2016-10-27T02:12:35Z")

</div>

Hi Jai,  
Please help resolving below error:

Moreover, i am very much interested to know how elasticsearch nodes are interacting with each other after shield implementation? how they are getting authenticated?  
[2016-10-26 18:46:33,047][WARN][shield.transport] [es-master-node] Received response for a request that has timed out, sent [19495ms] ago, timed out [4495ms] ago, action [cluster:monitor/nodes/stats[n]], node [{es-data-node-4}{HD4dxgp2ScaNs6bQEpChUw}{_._..11.98}{_._..11.98:9300}{master=false}], id [133069]  
[2016-10-26 19:00:09,681][DEBUG][action.search] [es-master-node] [767] Failed to execute query phase  
RemoteTransportException[[es-data-node-2][_._..1.50:9300][indices:data/read/search[phase/query+fetch/scroll]]]; nested: SearchContextMissingException[No search context found for id [767]];  
Caused by: SearchContextMissingException[No search context found for id [767]]  
at org.elasticsearch.search.SearchService.findContext(SearchService.java:613)  
at org.elasticsearch.search.SearchService.executeFetchPhase(SearchService.java:542)  
at org.elasticsearch.search.action.SearchServiceTransportAction$SearchQueryFetchScrollTransportHandler.messageReceived(SearchServiceTransportAction.java:416)  
at org.elasticsearch.search.action.SearchServiceTransportAction$SearchQueryFetchScrollTransportHandler.messageReceived(SearchServiceTransportAction.java:413)  
at org.elasticsearch.transport.TransportRequestHandler.messageReceived(TransportRequestHandler.java:33)  
at org.elasticsearch.shield.transport.ShieldServerTransportService$ProfileSecuredRequestHandler.messageReceived(ShieldServerTransportService.java:180)  
at org.elasticsearch.transport.RequestHandlerRegistry.processMessageReceived(RequestHandlerRegistry.java:75)  
at org.elasticsearch.transport.netty.MessageChannelHandler$RequestHandler.doRun(MessageChannelHandler.java:300)  
at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37)  
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)  
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)  
at java.lang.Thread.run(Thread.java:745)  
[2016-10-26 19:00:09,682][ERROR][shield.authc.esnative] [es-master-node] error occurred while checking the native users for changes  
Failed to execute phase [query\_fetch], all shards failed; shardFailures {RemoteTransportException[[es-data-node-2][_._..1.50:9300][indices:data/read/search[phase/query+fetch/scroll]]]; nested: SearchContextMissingException[No search context found for id [767]]; }  
at org.elasticsearch.action.search.SearchScrollQueryAndFetchAsyncAction.onPhaseFailure(SearchScrollQueryAndFetchAsyncAction.java:155)  
at org.elasticsearch.action.search.SearchScrollQueryAndFetchAsyncAction.access$300(SearchScrollQueryAndFetchAsyncAction.java:41)  
at org.elasticsearch.action.search.SearchScrollQueryAndFetchAsyncAction$1.onFailure(SearchScrollQueryAndFetchAsyncAction.java:142)  
at org.elasticsearch.action.ActionListenerResponseHandler.handleException(ActionListenerResponseHandler.java:46)  
at org.elasticsearch.transport.netty.MessageChannelHandler.handleException(MessageChannelHandler.java:212)  
at org.elasticsearch.transport.netty.MessageChannelHandler.handlerResponseError(MessageChannelHandler.java:202)  
at org.elasticsearch.transport.netty.MessageChannelHandler.messageReceived(MessageChannelHandler.java:136)  
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70)  
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)  
at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791)  
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296)  
at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:462)  
at org.jboss.netty.handler.codec.frame.FrameDecoder.callDecode(FrameDecoder.java:443)  
at org.jboss.netty.handler.codec.frame.FrameDecoder.messageReceived(FrameDecoder.java:303)  
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70)  
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)  
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:559)  
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268)  
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255)

Thanks & Regards

---

<div class="post-metadata">

**Author:** ![cjcenizal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cjcenizal/32/11216_2.png) [@cjcenizal](https://discuss.elastic.co/u/cjcenizal)\
**Post date:** [October 28, 2016, 11:00pm UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/2 "2016-10-28T23:00:30Z")

</div>

Hi Piyush,

It's been a couple of days, and I just wanted to check in and see if you still need help with this error?

Thanks,  
CJ

---

<div class="post-metadata">

**Author:** ![piyush](https://avatars.discourse-cdn.com/v4/letter/p/ecb155/32.png) [@piyush](https://discuss.elastic.co/u/piyush)\
**Post date:** [October 28, 2016, 11:12pm UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/3 "2016-10-28T23:12:55Z")

</div>

Yes please.

ELK stack is in production and i disabled shield for now, due to this error.

---

<div class="post-metadata">

**Author:** ![jaymode](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jaymode/32/50103_2.png) [@jaymode](https://discuss.elastic.co/u/jaymode)\
**Post date:** [November 1, 2016, 1:13pm UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/4 "2016-11-01T13:13:37Z")

</div>

Hey @piyush , are you using ldap or active directory with unmapped\_groups\_as\_roles?

---

<div class="post-metadata">

**Author:** ![piyush](https://avatars.discourse-cdn.com/v4/letter/p/ecb155/32.png) [@piyush](https://discuss.elastic.co/u/piyush)\
**Post date:** [November 1, 2016, 4:12pm UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/5 "2016-11-01T16:12:18Z")

</div>

Active Directory and it's true. PFA my configuration:

shield:  
authc:  
realms:  
ccsad:  
type: active\_directory  
order: 0  
domain\_name: _.com  
url: ldap://_.com:389  
unmapped\_groups\_as\_roles: true

---

<div class="post-metadata">

**Author:** ![jaymode](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jaymode/32/50103_2.png) [@jaymode](https://discuss.elastic.co/u/jaymode)\
**Post date:** [November 1, 2016, 4:52pm UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/6 "2016-11-01T16:52:41Z")

</div>

Can you try with unmapped\_groups\_as\_roles disabled? That should resolve the issue; we'll be fixing this in a upcoming patch release.

---

<div class="post-metadata">

**Author:** ![piyush](https://avatars.discourse-cdn.com/v4/letter/p/ecb155/32.png) [@piyush](https://discuss.elastic.co/u/piyush)\
**Post date:** [November 4, 2016, 8:28pm UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/7 "2016-11-04T20:28:46Z")

</div>

It worked, Thanks Jay.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 1:41pm UTC](https://discuss.elastic.co/t/error-shield-authc-esnative/64081/8 "2017-07-06T13:41:27Z")

</div>


