The Question
We have an Umbraco 13.5.2 site hosted in Azure webapps. The site was misconfigured and about once a month would crash with OutOfMemoryExceptions. We’ve fixed the configuration. What I’m hoping to get some insight into is how the misconfiguration could have resulted in OutOfMemoryExceptions. We are trying to figure out if there is more to the problem than just that misconfiguration.
Anyone have any ideas on why our misconfigured examine/lucene settings would result in OutOfMemoryExceptions? Until I’ve found some explanation about how the misconfiguration could cause this exception, I’m inclined to believe that there is a separate problem at play.
Thanks everyone!
The setup
We have a backend, CMS instance and a public scalable instance (not currently scaled out at all) both pointed to the same database. The site has periodically started crashing and won’t come up again without actually removing all traffic from the public site for a time. Recycling the app pool is not sufficient.
We have identified part of the problem being that our examine configuration was not correct for load balancing in Azure. Both the backend, CMS instance and the frontend, scalable instance had:
{
"Umbraco": {
"CMS": {
"Examine": {
"LuceneDirectoryFactory" : "SyncedTempFileSystemDirectoryFactory"
}
}
}
}
The frontend, scalable instance should have had
{
"Umbraco": {
"CMS": {
"Examine": {
"LuceneDirectoryFactory" : "TempFileSystemDirectoryFactory"
}
}
}
}
The Symptoms
The site would crash and we couldn’t fix it by just recycling the app pool. We actually had to route traffic away from the site for a time until the site had a chance to stabilize.
When we would review the Umbraco logs, we would see
- The site would restart mid day. We aren’t sure what triggered this yet
- The site would go through its regular boot process
- When the site would boot back up, it would replicate the indexes from the
%Home%
directory back to its%TEMP%
directory with no apparent errors. There are info level logs indicating this. - Around 1min later, the site would throw an
OutOfMemoryException
and restart - The cycle would repeat