Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure publish issues - Busy - Restarting - Busy - Cycling

Azure is giving me a headache.

I started off with a tutorial. Created a new MVC 3 project published it. Took about 9 mins then it was working fine on my production VM.

Then I tried to publish a project I've been working on (MVC 3). It has the following dependencies:
Service.dll
Domain.dll
Autofac.dll

It works fine when I debug using the emulator.
It works fine when I unzip the package and deploy it to another server.

But when I publish to Azure Production I get the following:
1:42:31 PM - Preparing deployment for Website with Subscription ID: ...
1:42:31 PM - Connecting...
1:42:35 PM - Verifying storage account '...'...
1:42:38 PM - Uploading Package...
1:44:46 PM - Creating...
1:45:56 PM - Created Deployment ID: ....
1:45:56 PM - Starting...
1:46:34 PM - Initializing...
1:46:34 PM - Instance 0 of role Website is in an unknown state
1:46:34 PM - Instance 1 of role Website is in an unknown state
1:47:06 PM - Instance 0 of role Website is creating the virtual machine
1:47:06 PM - Instance 1 of role Website is creating the virtual machine
1:47:37 PM - Instance 0 of role Website is starting the virtual machine
1:47:37 PM - Instance 1 of role Website is starting the virtual machine
1:50:13 PM - Instance 0 of role Website is in an unknown state
1:50:13 PM - Instance 1 of role Website is in an unknown state
1:50:44 PM - Instance 0 of role Website is busy
1:50:44 PM - Instance 1 of role Website is busy
1:54:31 PM - Instance 1 of role Website is restarting
1:55:02 PM - Instance 1 of role Website is busy
1:56:40 PM - Instance 1 of role Website is cycling
1:57:43 PM - Instance 0 of role Website is cycling

I've tried number of times. With no success.

Update

I forgot to mention that I have the facebook C# sdk DLLs

I've used trial and error to find that the Facebook.Web.Mvc dll is causing me issues. It has been included inside the bin folder but still no good.

like image 973
Chris Kolenko Avatar asked Jan 23 '12 03:01

Chris Kolenko


1 Answers

The Azure environment doesn't have all the MVC 3 assemblies. You need to make sure you reference them all in your project and set CopyLocal = true so that the assemblies get included in your Azure package. Azure will go through this infinite cycle if it can't find all the dependencies for your project.

The assemblies you need to reference are:

  • Microsoft.Web.Infrastructure
  • System.Web.Helpers
  • System.Web.MVC
  • System.Web.Razor
  • System.Web.WebPages
  • System.Web.WebPages.Deployment
  • System.Web.WebPages.Razor

One blog I saw also mentioned needing WebMatrix.Data, but I found I did not need this one in my project.

If you have any other assemblies you are referencing that are not part of the .NET Framework, you will also need set CopyLocal = true on those as well.

Also, make sure your Azure storage setting is NOT set to "Use development storage" when you deploy to Azure -- this will cause the same problem.

If the above doesn't solve the problem, check this site for some other possible causes.

like image 65
Brian Rogers Avatar answered Oct 03 '22 23:10

Brian Rogers