Posted on 10/05/2025 10:34:24
Hi guys,
We are experiencing a recurring issue with Index builds.
It happened rather often, although we cannot reproduce it manually.
Sometimes we get this error:
10:29:01.141: Product index builder experienced a fatal error.. System.Exception: Lock file already present: D:\dynamicweb.net\Solutions\dynamicweb\altexpim.cloud.dynamicweb-cms.com\files\System\Indexes\PIM\PIM\D\write.lock created: (05/10/2025 08:28:26) ---> Lucene.Net.Store.LockObtainFailedException: Lock obtain timed out: NativeFSLock@D:\dynamicweb.net\Solutions\dynamicweb\altexpim.cloud.dynamicweb-cms.com\files\System\Indexes\PIM\PIM\D\write.lock at Lucene.Net.Store.Lock.Obtain(Int64 lockWaitTimeout) at Lucene.Net.Index.IndexWriter.Init(Directory d, Analyzer a, Boolean create, IndexDeletionPolicy deletionPolicy, Int32 maxFieldLength, IndexingChain indexingChain, IndexCommit commit) at Lucene.Net.Index.IndexWriter..ctor(Directory d, Analyzer a, Boolean create, MaxFieldLength mfl) at Dynamicweb.Indexing.Lucene.LuceneIndexWriter.Open(Boolean openForAppend) --- End of inner exception stack trace --- at Dynamicweb.Indexing.Lucene.LuceneIndexWriter.Open(Boolean openForAppend) at Dynamicweb.Ecommerce.Indexing.ProductIndexBuilder.Build(IIndexWriter writer, Tracker tracker)
Sometimes we get this error:
Product index builder experienced a fatal error.. System.Exception: Lock file is NOT present: D:\dynamicweb.net\Solutions\dynamicweb\altexpim.cloud.dynamicweb-cms.com\files\System\Indexes\PIM\PIM\D\write.lock. Time in ms taken in Open: 2008, writer timeout ms: (2000) ---> Lucene.Net.Store.LockObtainFailedException: Lock obtain timed out: NativeFSLock@D:\dynamicweb.net\Solutions\dynamicweb\altexpim.cloud.dynamicweb-cms.com\files\System\Indexes\PIM\PIM\D\write.lock at Lucene.Net.Store.Lock.Obtain(Int64 lockWaitTimeout) at Lucene.Net.Index.IndexWriter.Init(Directory d, Analyzer a, Boolean create, IndexDeletionPolicy deletionPolicy, Int32 maxFieldLength, IndexingChain indexingChain, IndexCommit commit) at Lucene.Net.Index.IndexWriter..ctor(Directory d, Analyzer a, Boolean create, MaxFieldLength mfl) at Dynamicweb.Indexing.Lucene.LuceneIndexWriter.Open(Boolean openForAppend) --- End of inner exception stack trace --- at Dynamicweb.Indexing.Lucene.LuceneIndexWriter.Open(Boolean openForAppend) at Dynamicweb.Ecommerce.Indexing.ProductIndexBuilder.Build(IIndexWriter writer, Tracker tracker)
I have tried all kinds of solutions. Adding the write.lock file, removing it, deleting Index files, and trying to run it again but no solution worked. The only solution is to delete the build completely and add a new one with a different name and location.
it is true that we are running on an old Dw solution (9.13.12) but we don't have the option to upgrade as the solution is highly customized.
I am wondering if anybody faced a similar issue and figured out a solution for it.
Thank you,
Adrian