Forums / Extensions / eZ Find / Solr - index error - write.lock
Johann Lemaitre
Thursday 09 April 2009 6:11:14 am
hi.
i'm trying to index content and documents (pdf) with ezFind.I've configure my fiel attribute as searchable ans i've uploaded PDF document through admin interface, but i cannot make it work.
I've installed pdftotex in my server and its working. When I publish the content, i've several times the newt stacktrace : 9 avr. 2009 14:55:11 org.apache.solr.core.SolrCore execute INFO: [] webapp=/solr path=/update params={} status=500 QTime=1004 9 avr. 2009 14:55:11 org.apache.solr.common.SolrException log GRAVE: org.apache.lucene.store.LockObtainFailedException: Lock obtain timed out: SingleInstanceLock: write.lock at org.apache.lucene.store.Lock.obtain(Lock.java:85) at org.apache.lucene.index.IndexWriter.init(IndexWriter.java:1140) at org.apache.lucene.index.IndexWriter.<init>(IndexWriter.java:938) at org.apache.solr.update.SolrIndexWriter.<init>(SolrIndexWriter.java:116) at org.apache.solr.update.UpdateHandler.createMainIndexWriter(UpdateHandler.java:122) at org.apache.solr.update.DirectUpdateHandler2.openWriter(DirectUpdateHandler2.java:167) at org.apache.solr.update.DirectUpdateHandler2.commit(DirectUpdateHandler2.java:354) at org.apache.solr.update.processor.RunUpdateProcessor.processCommit(RunUpdateProcessorFactory.java:77) at org.apache.solr.handler.XmlUpdateRequestHandler.processUpdate(XmlUpdateRequestHandler.java:226) at org.apache.solr.handler.XmlUpdateRequestHandler.handleRequestBody(XmlUpdateRequestHandler.java:123) at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:131) at org.apache.solr.core.SolrCore.execute(SolrCore.java:1204) at org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:303) at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:232) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:285) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:502) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:835) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:641) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:208) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:378) at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:226) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)
Any ideas ?
Johann
Thursday 09 April 2009 6:55:22 am
I've reinstall my ezfind extension and my stacktrace has disappeared. I don't the origin of my problem Doesn't matterJohann
Paul Borgermans
Monday 13 April 2009 8:33:46 am
This means a previous process crashed without being able to release the write lock to the Solr index or there is still one running.
With normal start/stop of Solr this should not happen
Though Solr can be configured to agressively remove the lock, best is to determine the cause
Paul
eZ Publish, eZ Find, Solr expert consulting and training http://twitter.com/paulborgermans
Gediminas Morkevicius
Wednesday 09 September 2009 4:06:45 am
I had same issue, in my case i edited /extension/ezfind/java/solr/conf/solrconfig.xml
and I changed two settings in it. <lockType>single</lockType> to <lockType>simple</lockType> and<unlockOnStartup>false</unlockOnStartup> to <unlockOnStartup>true</unlockOnStartup>
it should not harm your system, it simply unlocks the files on startup, and changes the lock type.dont forget to restart solr after changes in config