After restarting my Seafile Docker setup, the Elasticsearch container will no longer start - it goes in a restart loop because of:
java.lang.IllegalStateException: failed to obtain node locks, tried [[/usr/share/elasticsearch/data]] with lock id [0]; maybe these locations are not writable or multiple nodes were started without increasing [node.max_local_storage_nodes] (was [1])?
Likely root cause: java.nio.file.AccessDeniedException: /usr/share/elasticsearch/data/nodes/0/node.lock
java.lang.IllegalStateException: failed to obtain node locks, tried [[/usr/share/elasticsearch/data]] with lock id [0]; maybe these locations are not writable or multiple nodes were started without increasing [node.max_local_storage_nodes] (was [1])?
I’ve tried deleting the file that’s mounted as /usr/share/elasticsearch/data/nodes/0/node.lock
, but it doesn’t make any difference! I’v also checked that after stopping the Docker services there are no other Java processes running.
I noticed all Elasticsearch files are owned by user 101 - is that correct?
Any ideas on how to resolve this?