Category Archives: Sitecore Azure

Sitecore Azure AppInsights CloudRoleName

If you’re planning to use Azure Application Insights for Sitecore, you’ll quickly found that the Application Map report is showing quite an unusual repots.

appinsights-ootb

The mismatched number of instances reported aside, the server name being reported isn’t what I expected.

From inspecting the processor in the initialize pipeline from Sitecore, I can see the following.

This doesn’t quite match what the Microsoft documentation suggested. And I can confirm by going to the logs captured in App Insights that the cloud_RoleName value is not passed at all.

The fix is quite simple, just use the following code to register the right CloudRoleName

Soon after I can see the right role displayed in the App Insights Application Map Dashboard.

appinsights-configured

Now I have better visibility on the application dependencies and which area of my application that can be further optimized for performance.

Note: If you’re using Sitecore Experience Commerce, you’ll need to make some changes with the same approach in order to set the value for CloudRoleName as well.

Issues encountered with Sitecore Azure Module

I was playing around with Sitecore Azure Module last week and would like to share my experience to get the site up and running.

I am using Sitecore 8.0 version, WFFM and EXM modules. Obviously you would need the Sitecore Azure module to help you setup the content editing and content deliry farm.

  • Sitecore 8.0 rev. 160115 (8.0 Update-7)
  • Sitecore WFFM rev. 151127 (Update-6)
  • Sitecore EXM  3.1 rev. 151213 (3.1 Update-2)
  • Sitecore Azure 8.0 rev. 150522

The target Azure setup would be

  • 1CM and 1CD server in the same data center, in my case I create the farms in the Singapore data center as it’s the closest one for me
  • Sharing the same databases for CM and CD; core, master, web, reporting. In the case of CD it will not have a reference to master and reporting
  • xDB cloud will not be used, instead MongoDB databases will be created using the free 500MB databases from http://mongolab.com

Before proceeding you would need an Azure Subscription in order to be able to create the necessary VM/Cloud Service, if you’re like me and just want to try out the Sitecore Azure Module you can sign up for a free trial for one month.

Installation

In the installing Sitecore Azure Module article above, it also explain about how to deploy to Azure to setup a Editing Farm and Delivery Farm which seems to be easy and straightforward. However I encountered some issues while trying to deploy to Azure.

Issues when deploying

Error saying that the storage account already exist in Azure

Solution:

 

The storage account service name must be unique in Azure across subscriptions, meaning that it has to be unique not only for you and for other subscriptions in the Azure as well. To fix this you can go to /sitecore/system/Modules/Azure/[project_name]/[region_name]/Editing01/Storages/Default and update the Service Name field.

 

Error saying that the database server already exist

Solution:

In the /sitecore/system/Modules/Azure/CampaignManagement-Evaluation/Southeast Asia/Editing01/Sql01 “Server Name” field empty the value. And then clean the unused Azure SQL database server.

 

Error saying that the vmsize does not exist

Solution:

This is because the vm tier name has been changed by Microsoft, which originally was D3 is now has been updated to Standard_D3. To fix this you would need to update the /App_Config/AzureVendors/Microsoft.xml

 

With the free trial subscription you might encounter an issue when the Sitecore Azure Module tries to create the database in SQL Database S2 tier

Solution:

To fix this you can temporarily change the /sitecore/system/Modules/Azure/[project-Name]/[region_name]/Editing01/Sql01/Set01/[database_name] Tier field and change it to “Basic – Basic”. This could also be caused by the database size Sitecore Azure Module requested to be created is not supported by the free trial subscription, I haven’t tested this however if you would like to try it yourself then update the /App_Config/AzureVendors/Microsoft.xml change the

to something smaller, say 100GB or 10GB

 

Another issue when trying to create the Cloud Service

Solution:

This issue seems to be related to the siteStorageSize configuration in /App_Config/AzureVendors/Microsoft.xml. I was trying to create a D3 instance which has the default size of 180GB, reducing the value to 10GB or more seems to do the trick

 

Some reference links that might helps: