user1147862
user1147862

Reputation: 4226

Diagnostics to find out why Azure Web Role doesn't start

I am trying to deploy a large web site to Azure as a Web Role. However, Azure on the Instances tab of the Azure dashboard, it tells me it suffers an error during start up, causing it to restart over and over again.

Where can I find log files that will tell me what specifically is going wrong? The manage.windowsazure.com site doesn't seem to have any.

Upvotes: 2

Views: 262

Answers (2)

kwill
kwill

Reputation: 10998

There are a series of 4 blog posts at http://blogs.msdn.com/b/kwill/archive/2013/08/09/windows-azure-paas-compute-diagnostics-data.aspx which will walk you through step by step how to troubleshoot a role startup failure including log file locations, etc.

Upvotes: 0

Sean Osterberg
Sean Osterberg

Reputation: 844

First, debug on your dev machine. Make sure you deployed the right .cscfg file, you don't have any broken connection strings, you're referencing the right version of the DLLs (the same as Azure's VMs) or are copying newer versions to Azure. If those fail, read this topic on WindowsAzure.com and the topics in this node on MSDN. The Hello World code sample also has a basic demonstration of diagnostics that should be helpful.

The basics of diagnostics in Windows Azure:

  • Must be manually enabled for each role by importing the Diagnostics module in your ServiceDefinition.csdef file
  • A storage location needs to be configured for the resulting logs in your ServiceConfiguration.cscfg file, such as the storage emulator, or a Windows Azure Storage account. Depending on the types of logs, they are stored in either blobs or tables.
  • You can either configure diagnostics collection programmatically or with a file that is read when your role starts and can be updated on-the-fly
  • You can set up and control how often diagnostics data is downloaded to your storage account (important because transactions/transfer/storage costs money), performance counters, or other metrics you need

Upvotes: 1

Related Questions