search

[Fixed] #Sitecore RebuildSearchIndex|System.IO.IOException: Cannot overwrite

Posted on Updated on

Issue: Cannot overwrite index during quick search index rebuild via Sitecore Control panel .

Job started: RebuildSearchIndex|System.IO.IOException: Cannot overwrite: D:\SITECORE\data\indexes\__system\_b.fdt
at Lucene.Net.Store.FSDirectory.InitOutput(String name)
at Lucene.Net.Store.SimpleFSDirectory.CreateOutput(String name)
at Lucene.Net.Index.FieldsWriter..ctor(Directory d, String segment, FieldInfos fn)
at Lucene.Net.Index.StoredFieldsWriter.InitFieldsWriter()
at Lucene.Net.Index.StoredFieldsWriter.FinishDocument(PerDoc perDoc)
at Lucene.Net.Index.DocumentsWriter.WaitQueue.WriteDocument(DocWriter doc)
at Lucene.Net.Index.DocumentsWriter.WaitQueue.Add(DocWriter doc)
at Lucene.Net.Index.DocumentsWriter.FinishDocument(DocumentsWriterThreadState perThread, DocWriter docWriter)
at Lucene.Net.Index.DocumentsWriter.UpdateDocument(Document doc, Analyzer analyzer, Term delTerm)
at Lucene.Net.Index.IndexWriter.AddDocument(Document doc, Analyzer analyzer)
at Sitecore.Search.IndexUpdateContext.AddDocument(Document document)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddItem(Item item, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Index.Rebuild()
at Sitecore.Shell.Applications.Search.RebuildSearchIndex.RebuildSearchIndexForm.Builder.Build()|Job ended: RebuildSearchIndex (units processed: )

 

Rebuild_Quick_Search_Index_cannot_overide

Solution: The file is corrupted, so just delete the file, in my case “_b.fdt”.

Quick_Search_Indexes_file

.. and rebuild again.

Rebuild_Quick_Search_counting.png

 

Enjoy. ­čÖé

Advertisements

[Fixed] RebuildSearchIndex|System.ArgumentException: it doesn’t make sense to have a field that is neither indexed nor stored.

Posted on

Whilst rebuilding the quick search indexes in the control panel, I’ve encountered the issue below:

Job started: RebuildSearchIndex|System.ArgumentException: it doesn’t make sense to have a field that is neither indexed nor stored
at Lucene.Net.Documents.Field..ctor(String name, Boolean internName, String value_Renamed, Store store, Index index, TermVector termVector)
at Sitecore.Search.Crawlers.BaseCrawler.CreateDataField(String name, String value)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddSpecialFields(Document document, Item item)
at Sitecore.Search.Crawlers.DatabaseCrawler.IndexVersion(Item item, Item latestVersion, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddItem(Item item, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Crawlers.DatabaseCrawler.AddTree(Item root, IndexUpdateContext context)
at Sitecore.Search.Index.Rebuild()
at Sitecore.Shell.Applications.Search.RebuildSearchIndex.RebuildSearchIndexForm.Builder.Build()|Job ended: RebuildSearchIndex (units processed: 39449)

it doesnt make sense to have a field that is neither index.png

Solution:

Find the items with the greater length than 120 and rename those items in Sitecore content editor.

SELECT [ID]
,[Name]
,[TemplateID]
,[MasterID]
,[ParentID]
,[Created]
,[Updated]
FROM [dbo].[Items]
WHERE LEN([NAME]) > 120

Note: 100 is the default MAX item length specified in web.config.

Check_item_name_length_greater_than_120.png

Thanks to this post by Chaturanga ranatunga

Alternatively, if the result is too many, then you might want to increase the value of the setting MaxItemNameLength to 200 in the \Website\web.config instead.

<setting name="MaxTreeDepth" value="20" />
<!-- MAX ITEM NAME
Specifies the maximum length of an item name.
Default value: 100
-->
<setting name="MaxItemNameLength" value="1000" />

Remember: Please do not forget to revert back the value if needed.

[Fixed] RebuildSearchIndex|System.Threading.LockRecursionException: Recursive read lock acquisitions not allowed in this mode.

Posted on Updated on

While rebuilding the Search Indexes.

Issue:

Job started: RebuildSearchIndex|System.Threading.LockRecursionException: Recursive read lock acquisitions not allowed in this mode.
at System.Threading.ReaderWriterLockSlim.TryEnterReadLockCore(TimeoutTracker timeout)
at System.Threading.ReaderWriterLockSlim.TryEnterReadLock(TimeoutTracker timeout)
at System.Threading.ReaderWriterLockSlim.TryEnterReadLock(Int32 millisecondsTimeout)
at Sitecore.Search.IndexUpdateContext..ctor(ILuceneIndex index)
at Sitecore.Search.Index.Rebuild()
at Sitecore.Shell.Applications.Search.RebuildSearchIndex.RebuildSearchIndexForm.Builder.Build()|Job ended: RebuildSearchIndex (units processed: )

Screenshot:

Rebuild_Search_Indexes

Solution:

In the Sitecore.Forms.config, there’s a settings:


<!-- CONNECTION STRING
Sets the name of the connection string
-->
<setting name="WFM.ConnectionString" value="reporting" />

Make sure that it is equivalent in the connectionstring.config WFFM connectionstring.


<add name="reporting" connectionString="Data Source=11.2.3.456,1433;Database=sitecore_analytics;Integrated Security=true" /> 

Working rebuild index.JPG