Hi,
I'm running ElasticSearch 0.11.0 with three machines and about 30G of
disk usage. Yesterday, this dropped to 12G and I'm seeing errors:
java.io.IOException: directory '/mnt/elasticsearch/work/warp/nodes/0/
indices/mau
ritius-comments/3/index' exists and is a directory, but cannot be
listed: list() returned null
at
org.elasticsearch.index.store.fs.NioFsStore.(NioFsStore.java:50)
while locating org.elasticsearch.index.store.fs.NioFsStore
while locating org.elasticsearch.index.store.Store
for parameter 5 at
org.elasticsearch.index.gateway.IndexShardGatewayService.(IndexShardGatewayService.j
ava:76)
while locating
org.elasticsearch.index.gateway.IndexShardGatewayService
Caused by: java.io.IOException: directory '/mnt/elasticsearch/work/
warp/nodes/0/indices/mauritius-comments/3/inde
x' exists and is a directory, but cannot be listed: list() returned
null
at
org.apache.lucene.store.FSDirectory.listAll(FSDirectory.java:234)
at
org.apache.lucene.store.FSDirectory.listAll(FSDirectory.java:245)
at org.elasticsearch.index.store.support.AbstractStore
$StoreDirectory.(AbstractStore.java:122)
I suspect the number of open files which is 16k now, is too low:
java.io.IOException: Too many open files
at sun.nio.ch.ServerSocketChannelImpl.accept0(Native Method)
at
sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:
163)
at
org.elasticsearch.common.netty.channel.socket.nio.NioServerSocketPipelineSink
$Boss.run(NioServerSocket
PipelineSink.java:245)
at
org.elasticsearch.common.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:
108)
at
org.elasticsearch.common.netty.util.internal.IoWorkerRunnable.run(IoWorkerRunnable.java:
46)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1110)
at java.util.concurrent.ThreadPoolExecutor
$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:636)
Health seems to be fine:
$ curl -XGET 'http://localhost:9300/_cluster/health?pretty=true'
{
"status" : "green",
"timed_out" : false,
"number_of_nodes" : 8,
"active_primary_shards" : 10,
"active_shards" : 20,
"relocating_shards" : 0,
"initializing_shards" : 0,
"unassigned_shards" : 0
}
My problem is: how do I recover the data? It seems to be on the
machines but is mostly unaccessible. Optimizing show the following
interesting error:
[2010-10-26 10:49:58,314][DEBUG][action.admin.indices.optimize] [Nova-
Prime] [mauritius-comments][1], node[14f7b134-368e-4ad5-9c27-
b1cdcd15fba8], [R], s[STARTED]: Failed to execute
[org.elasticsearch.action.admin.indices.optimize.OptimizeRequest@195bed9d]
org.elasticsearch.transport.RemoteTransportException: [Headknocker]
[inet[/10.235.38.207:9301]][indices/optimize/shard]
Caused by:
org.elasticsearch.index.engine.OptimizeFailedEngineException:
[mauritius-comments][1] Optimize failed
at
org.elasticsearch.index.engine.robin.RobinEngine.optimize(RobinEngine.java:
461)
at
org.elasticsearch.index.shard.service.InternalIndexShard.optimize(InternalIndexShard.java:
386)
at
org.elasticsearch.action.admin.indices.optimize.TransportOptimizeAction.shardOperation(TransportOptimizeAction.java:
108)
at
org.elasticsearch.action.admin.indices.optimize.TransportOptimizeAction.shardOperation(TransportOptimizeAction.java:
50)
at
org.elasticsearch.action.support.broadcast.TransportBroadcastOperationAction
$ShardTransportHandler.messageReceived(TransportBroadcastOperationAction.java:
399)
at
org.elasticsearch.action.support.broadcast.TransportBroadcastOperationAction
$ShardTransportHandler.messageReceived(TransportBroadcastOperationAction.java:
392)
at org.elasticsearch.transport.netty.MessageChannelHandler
$3.run(MessageChannelHandler.java:195)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1110)
at java.util.concurrent.ThreadPoolExecutor
$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:636)
Caused by: java.io.IOException: background merge hit exception:
_6i8:C66898 _kpg:C105747 _aw9:C17593 _kpe:C151833 _kxw:C20226 into
_kxy [optimize] [mergeDocStores]
at
org.apache.lucene.index.IndexWriter.optimize(IndexWriter.java:2359)
at
org.elasticsearch.index.engine.robin.RobinEngine.optimize(RobinEngine.java:
455)
... 9 more
Caused by: java.lang.ArrayIndexOutOfBoundsException
And that's all. Any help is greatly appreciated.