Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Dan Curtis 3 posts 73 karma points notactivated
    Mar 14, 2017 @ 17:37
    Dan Curtis
    0

    Azure load balanced site(s) crash on start

    Hi all,

    Having a bit of a strange issue. Here's the current setup:

    • Azure App Service with two instances for front end traffic
    • Azure deployment slots to deploy new versions of the site in parallel, then swap after the new site warms up.
    • Examine indexes use useTempStorage="LocalOnly" for examine indexes as we had issues using sync mode (presuming this was due to the deployment slot trying to write to the indexes in App_Data at the same time).
    • Examine indexes use RebuildOnAppStart="true" so that the new site creates it's indexes
    • Umbraco version 7.5.2

    After deploying, only one of the server seems to work. The other throws an error and never really 'wakes up'. Touching the web.config seems to resolve the issue, but obviously not ideal.

    Here's a trimmed version of the logs on start:

    Umbraco 7.5.2 application starting on <MACHINEID>
    Load Xml from file...
    [ScheduledTasks] Tasks cancelled, terminated
    Failed to load Xml from file. System.IO.DirectoryNotFoundException: Could not find a part of the path 'D:\local\Temporary ASP.NET Files\....\UmbracoData\umbraco.config'.
    Save Xml to file...
    Saved Xml to file.
    No last synced Id found, this generally means this is a new server/install. The server will build its caches and indexes, and then adjust its last synced Id to the latest found in the database and maintain cache updates based on that Id.
    Starting rebuild of index <Custom event at start of index rebuild>
    
    Application shutdown. Details: BinDirChangeOrDirectoryRename_shutDownMessage=Change Notification for critical directories.bin dir change or directory renameHostingEnvironment initiated shutdownChange Notification for critical directories.bin dir change or directory renameChange Notification for critical directories.bin dir change or directory renameChange Notification for critical directories.bin dir change or directory renameHostingEnvironment caused shutdown_shutDownStack=   at System.Environment.GetStackTrace(Exception e, Boolean needFileInfo)   at System.Environment.get_StackTrace()   at System.Web.Hosting.HostingEnvironment.InitiateShutdownInternal()   at System.Web.Hosting.HostingEnvironment.InitiateShutdownWithoutDemand()   at System.Web.HttpRuntime.ShutdownAppDomain(String stackTrace)   at System.Web.HttpRuntime.OnCriticalDirectoryChange(Object sender, FileChangeEvent e)   at System.Web.FileChangesMonitor.OnCriticaldirChange(Object sender, FileChangeEvent e)   at System.Web.DirectoryMonitor.FireNotifications()   at System.Web.Util.WorkItem.CallCallbackWithAssert(WorkItemCallback callback)   at System.Web.Util.WorkItem.OnQueueUserWorkItemCompletion(Object state)   at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context(Object state)   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)   at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()   at System.Threading.ThreadPoolWorkQueue.Dispatch()   at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()
    

    Trying to hit the homepage of the site after the deploy results in an 500 error, and the following in the logs:

    An unhandled exception occurred
    System.Web.HttpUnhandledException (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.NullReferenceException: Object reference not set to an instance of an object.
       at umbraco.UmbracoDefault.OnPreInit(EventArgs e)
       at System.Web.UI.Page.PerformPreInit()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       at System.Web.UI.Page.HandleError(Exception e)
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       at System.Web.UI.Page.ProcessRequest()
       at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context)
       at System.Web.UI.Page.ProcessRequest(HttpContext context)
       at ASP.default_aspx.ProcessRequest(HttpContext context)
       at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    

    Hitting any other pages on the site returns a 404 "The resource you are looking for has been removed, had its name changed, or is temporarily unavailable."

    Any ideas please?

Please Sign in or register to post replies

Write your reply to:

Draft