Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

RavenDB EsentOutOfLongValueIDsException

Tags:

c#

ravendb

esent

The following error is intermittently thrown when attempting to add or update a document: "Microsoft.Isam.Esent.Interop.EsentOutOfLongValueIDsException: Long-value ID counter has reached maximum value. (perform offline defrag to reclaim free/unused LongValueIDs)"

I've attempted to perform this offline defrag according to https://ravendb.net/docs/article-page/3.5/csharp/users-issues/recovering-from-esent-errors. I stopped the RavenDB service, navigated to the Databases folder in Adminstator command prompt and ran "esentutl /d DatabaseName". I then get the following error: "Access to source database 'DatabaseName' failed with Jet error -1032. Operation terminated with wrror -1032 after 20.31 seconds." I have also tried to restart the server with RavenDB not set to start on start-up. I still get error -1032 when attempting to defrag.

Is performing the defrag operation the correct action? If so, what process(es) would I need to stop in order for those files to not be in use?

Thanks!

like image 276
Varuna Avatar asked Jun 12 '17 15:06

Varuna


1 Answers

The solution was to run compact on raven. Raven studio > Manage Your Server > Compact. Compacting takes the database down, so I performed it on the replicated servers one at a time.

like image 164
Varuna Avatar answered Oct 05 '22 04:10

Varuna