Switch on logging on info level? See if that gives some more information on what content and what property Find has problem parsing...
Looks like it's trying to do a string format on some field which doesn't work as expected.
Let's hope someone recognize the problem otherwise I guess a support issue. If they can't fix it I would use conventions to remove half of the content types from index and repeat until you find the content type and property that is messing up the index. Binary search...
Hi,
you could add more logging for Find by adding a new log appender to EPiServerLog.Config:
<appender name="findRollingLogFileAppender" type="log4net.Appender.RollingFileAppender"> <file value="App_Data\Find.log" /> <appendToFile value="true" /> <datePattern value=".yyyyMMdd.'log'" /> <rollingStyle value="Date" /> <threshold value="Debug" /> <layout type="log4net.Layout.PatternLayout"> <conversionPattern value="%date %level [%thread] %type.%method - %message%n" /> </layout> </appender> <logger name="EPiServer.Find"> <level value="DEBUG" /> <appender-ref ref="findRollingLogFileAppender" /> </logger>
This way, you should get debug logging with information which shows you witch content id's are being indexed, something like:
Starting indexing of batch with the following Content:5,6,9,13,16,40,44,47,179,182,186
Then you could set reduse the batch size of the content indexer and set the numbers of thread to 1 to make it easier to spot the possible IDs that are causing the issue:
ContentIndexer.Instance.ContentBatchSize = 5; ContentIndexer.Instance.MaxThreads = 1;
Hey mate,
Long time no see :)
I have similar issue and after digin down found the problem in below:
EPiServer.Find.Cms.ContentIndexer.ReIndex()
catch (Exception ex) { if (Enumerable.Count<IContent>(content) == 1) { Interlocked.Increment(ref numberOfBatchErrors); string format = "{0}: An exception occurred while indexing content {1]: {2} {3}"; ContentIndexer._logger.Error((object) string.Format(format, (object) Environment.MachineName, (object) Enumerable.ElementAt<IContent>(content, 0).get_ContentLink(), (object) ExceptionExtensions.ExplainIndexException(ex), (object) string.Empty), ex); statusAction(new ContentIndexer.ReIndexStatus() { Message = string.Format(format, (object) Environment.MachineName, (object) ExceptionExtensions.ExplainIndexException(ex), (object) "(see log for more information)"), IsError = true }); }
As you can see "{1]" is a problem. So this bit of code report the content index error and need to carry one when the reporting is finished. But it throw and exception and just stop. I ran services started with "Remove" in admin area and problem goes away. But this is just shortcut but there is a ticket with EPiServer to resolve that bit of code.
A previous bug was reported for this issue. For your reference, the bug is #FIND-138
Hey Trung
I can't find this bug no. from the bug list, do you have any ETA for this? Is there any alternative for fixing this issue?
Thanks
Hey Aria
HAHA, yes, long time no see, we should have a catch up :)
Regarding to this issue, which remove task did you run to fix this issue? I ran all 4 remove jobs with no luck.
Hey mate,
The best way I found is to attached debugger and catch the exception and find the ContentID manually if those 4 tasks didn't help. Actually empty deleted content and then running service helps sometimes. I heared that the fix will be included in EPiServer.Find 11.1.2 (currently 11.1.1.4013). So if you can wait the release I belive will come soon.
Regards,
Aria
Hey mate
Thanks for your quick response.
Does VS allow you attach debugger to episerver find index job?
Regards,
Vincent
Just give a try, but nothing happened :(
I am chating to epi support online right now.
Do you have resharper or something else that let you debug into their code?
Just make sure you check the checkboxes for VS->Debug->Excpetion (VS2013) -> Common Language Runtime -> Both checkboxex (Thrown, User-Unhandled). Attach the debugger to IIS process (could be more than one). Adn then re-run the index.
I'm using dotPeek which is quite faster than anything else. You can setup it via here https://confluence.jetbrains.com/display/NETCOM/dotPeek+Symbol+Server+and+PDB+Generation.
The problem is in "EPiServer.Find.Cms.ContentIndexer.ReIndex()" if you search for
"{0}: An exception occurred while indexing content {1]: {2} {3}"
you can find it. that "]" is wrong and need to be change to "}"! That is it! If you recompile and sign the DLL you can ready to go ;)
Hi Guys....
Is there any update on this?.... I'm going to raise it as a bug again as I can't see it in the bug tracker and it hasn't been fixed as of EPiServer Find 11.1.2
I've obvioulsy a combination of content errors that triggers this exception, which then crashes and stops the indexer.....
2016-04-03 12:26:34,814 WARN [365] EPiServer.Find.Cms.ContentIndexer.ReIndex - SIMONWIN8: An exception occurred during reindex operation. System.AggregateException: One or more errors occurred. ---> System.FormatException: Input string was not in a correct format.
at System.Text.StringBuilder.AppendFormat(IFormatProvider provider, String format, Object[] args)
at System.String.Format(IFormatProvider provider, String format, Object[] args)
at EPiServer.Find.Cms.ContentIndexer.IndexBatch(IEnumerable`1 content, Action`1 statusAction, Int32& numberOfContentErrors, Int32& indexingCount)
at EPiServer.Find.Cms.ContentIndexer.IndexBatch(IEnumerable`1 content, Action`1 statusAction, Int32& numberOfContentErrors, Int32& indexingCount)
at EPiServer.Find.Cms.ContentIndexer.<>c__DisplayClass12.<ReIndex>b__9(IEnumerable`1 currentBatch, ParallelLoopState loopstate)
at System.Threading.Tasks.Parallel.<>c__DisplayClass32`2.<PartitionerForEachWorker>b__30()
at System.Threading.Tasks.Task.InnerInvokeWithArg(Task childTask)
at System.Threading.Tasks.Task.<>c__DisplayClass11.<ExecuteSelfReplicating>b__10(Object param0)
--- End of inner exception stack trace ---
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at System.Threading.Tasks.Task.Wait()
at System.Threading.Tasks.Parallel.PartitionerForEachWorker[TSource,TLocal](Partitioner`1 source, ParallelOptions parallelOptions, Action`1 simpleBody, Action`2 bodyWithState, Action`3 bodyWithStateAndIndex, Func`4 bodyWithStateAndLocal, Func`5 bodyWithEverything, Func`1 localInit, Action`1 localFinally)
at System.Threading.Tasks.Parallel.ForEachWorker[TSource,TLocal](IEnumerable`1 source, ParallelOptions parallelOptions, Action`1 body, Action`2 bodyWithState, Action`3 bodyWithStateAndIndex, Func`4 bodyWithStateAndLocal, Func`5 bodyWithEverything, Func`1 localInit, Action`1 localFinally)
at System.Threading.Tasks.Parallel.ForEach[TSource](IEnumerable`1 source, ParallelOptions parallelOptions, Action`2 body)
at EPiServer.Find.Cms.ContentIndexer.ReIndex(Action`1 statusAction, Func`1 isStopped)
---> (Inner Exception #0) System.FormatException: Input string was not in a correct format.
at System.Text.StringBuilder.AppendFormat(IFormatProvider provider, String format, Object[] args)
at System.String.Format(IFormatProvider provider, String format, Object[] args)
at EPiServer.Find.Cms.ContentIndexer.IndexBatch(IEnumerable`1 content, Action`1 statusAction, Int32& numberOfContentErrors, Int32& indexingCount)
at EPiServer.Find.Cms.ContentIndexer.IndexBatch(IEnumerable`1 content, Action`1 statusAction, Int32& numberOfContentErrors, Int32& indexingCount)
at EPiServer.Find.Cms.ContentIndexer.<>c__DisplayClass12.<ReIndex>b__9(IEnumerable`1 currentBatch, ParallelLoopState loopstate)
at System.Threading.Tasks.Parallel.<>c__DisplayClass32`2.<PartitionerForEachWorker>b__30()
at System.Threading.Tasks.Task.InnerInvokeWithArg(Task childTask)
at System.Threading.Tasks.Task.<>c__DisplayClass11.<ExecuteSelfReplicating>b__10(Object param0)<---
This issue is still present in EPiServer Find 11.1.2 and I created a new bug #FIND-919 for this issue. The bug has been fixed by our product devs. It will then go through the QA process before releasing in nuget feed. For now you can follow its status through our public bug list http://world.episerver.com/support/bug-list/bug/FIND-919
Had the same problem in:
EPiServer.Find.Cms, Version=11.1.3.4160
on in file EPiServer.Find.Cms.ContentIndexer.IndexBatch method there is line:
string format = "{0}: An exception occurred while indexing content {1]: {2} {3}";
that kills whole reindex job
will check later versions if they are fixed
I can confirm that it is fixed in:
"EPiServer.Find.Cms" version="11.1.5.4342"
Hi
When I ran find index on my commerce site, I received the following error, I have already spent a few hours, but still couldn't figure out what caused this.