简体   繁体   中英

Weird Behavior Deploying Azure Cloud Service

I have a very weird issue deploying an azure cloud Service. I have 1 Web Role with 5 instances and 1 Cache Role with 2 instances.

When I deploy my MVC 5 WebRole from the Azure Portal, deploying starts on the first web instance, then it tells me that the "The role could not be started" due to an error and stops processing the other instances. I did an RDP to the failed instance and truly the MVC application throws an error that it can't find a certain view file "The layout page "..." could not be found at the following path", even though the view in the path specified does exist. So I did an iisreset and the application worked. after I manually fixed the issue the deployment continues to the next instance and the failed instance becomes "Ready".

Anyone has an idea why things don't deploy smoothly anymore or why an iisreset is necessary?

This is relatively recent, around a month.

My environment is:

  1. .NET Framework 4.5.1
  2. MVC 5
  3. Azure SDK 2.4 for VS 2013

Thanks for the help.

FINALLY!! I found the issue and fixed it.

I had a Local Storage Resources to store temporary files and local file caches for certain components, and was configured to reset on role restart. One of the components (Lucene.NET for azure) was locking the files in that local storage, causing the problem on deployment that needed to to IIS reset to release the lock.

I configured the component to cache the files on Windows temp storage instead of the Local Resource and things worked out.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM