Monday, April 29, 2013

Journey to the Cloud with Windows Azure - Scenario III - Windows Azure Virtual Machines

We covered Azure Cloud Services and Azure Websites in the earlier posts.  Now, lets take another customer scenario, which is as below:

Scenario III:
A customer in hospitalization sector has around 300 virtual machines, some of these on Windows Server 2008 Operating system and some on open source platforms, such as Linux, Ubantu. There are around 200+ applications running on these servers. He also has some internal Intranet based portals running on SharePoint Server 2010. He has no plan of changing anything with respect to the applications, and his main challenge is IT Infrastructure procurement cost and management of these servers. He is looking at both cost optimization, at the same time wants high availability and performance of his applications.

The real power of cloud computing is the flexibility it offers when it comes to the kind of offering that we would like to manage.  The above scenario requires basically infrastructure with more control over the machines, with cost optimization. This is exactly where Azure Infrastructure as a Service helps. With Azure IaaS, the customer can have full control of virtual machine on cloud, with implicit features of Load balancing and High availability.

Similarly, administrators and even certain Developers who want much control of the deployment environment particularly in cases where there needs to be integration with other components, can leverage the advantages of Azure IaaS. 

In the above case, IaaS offers the flexibility to power up virtual machines of specific operating system, configuration, and platform image from the portal. Another cool thing about Azure IaaS is that even open source platforms such as Linux and Ubantu are supported. There are also images for SharePoint Server 2013 and BizTalk Server that can be used.

How to deploy Azure Virtual Machines:
Lets assume a case where we need a Windows Server 2012 or Windows Server 2008 R2 edition running on the cloud. We can simply login to the portal and choose the configuration required and have a Virtual Machine running in few minutes. The VM provisioned can be logged in using a RDP (Remote Desktop Protocol), similar to how we connect to any server on-premises.

Here below is a sample screen of the virtual machine offerings, available in Quick Create
Azure Virtual Machine Images

Sometimes, we will have specific requirements like, to run a Virtual Machine that has SQL Server installed, or a Virtual Machine with BizTalk or SharePoint Server.  These are resource intensive products and having them run on the Cloud powered by the Virtualization makes more sense than having the required hardware and servers locally.
Windows Azure IaaS offers Platform Images in the Gallery that one can choose and have it up running.  The example screen below shows the available platform images.

Not just that, you can also choose the region where you would like to have these running.  Also, make them part of an Availability Set and Affinity Groups where you would like to host them in combination with other services, for a lesser network latency.
All of these in configurable screens to choose the optimum configuration/settings for our Virtual Machines.
Azure Virtual Machine Operating System Gallery

We will explore more on Virtual Machines in the subsequent posts.

Trivia: IaaS Virtual Machines use Windows Azure Blob Storage for storing the virtual hard disk, so you would need to create a Storage Account when creating a Virtual Machine.

Saturday, April 27, 2013

Journey to the Cloud with Windows Azure - Scenario II - Windows Azure Websites

Let’s continue from the earlier post on moving to the cloud. If you haven't checked out the previous post, you can find that here.

Scenario II:
The retail customer also has a lot of legacy applications built using .NET 2.0, .NET 1.1, ASP etc.,   While he has usage for these applications, he doesn’t have plans to migrate them to the latest versions of the framework.  Neither does he have the resources to do that, nor does he feel the necessity.  These are typically applications like Performance Management, Rewards Portal, Attendance etc., which are important but not mission critical.  And the existing technologies used then suffice the very purpose.  There are also a few open source portal applications built in Joomla and Drupal with MySQL that need to be maintained. However, managing servers for these applications is a nightmare and he would ideally  want them to be hosted in Windows Azure.

Going by our earlier post, in order to migrate an app to Azure Cloud Services, it has to be at the minimum in .NET 3.5, hence that is ruled out.

So which Azure offering best suits this scenario?

Azure Websites offer the best solution for this case. 

Azure Websites offer a fast and easy way to deploy ASP.NET 2.0 and older versions as well as ASP Applications to Virtual Machines running IIS on Windows Azure.
Another cool thing about Azure Websites is that even portals built using open source platforms such as WordPress, Joomla!, Drupal, DotNetNuke and Umbraco and MySQL database.

Azure Websites offer Free, Shared & Reserved instances to choose based upon the needs.  When one signs up for a FREE Azure account, they get to host upto 10 websites for free.  Gradually as the demand for power increases, one can switch to Shared or Reserved instances.  
If you need a comparison of the Free vs. Shared vs. Reserved instance, check out

Technically FREE and Shared are similar except that Shared provides more performance for the website when hosted in Shared vs. hosting it in FREE.  The model also uses pay-as-you-go billing after 5GB Bandiwdth.  For a more detailed comparison, check out

Websites also provide additional components such as MySQL Data Storage.  You can also use Windows Azure SQL Database for storing your data.

The biggest advantage is that Websites support FTP Deployment.  So, the customer needs to just configure the FTP Ports and then publish the files. Check this article on FTP Publishing with Windows Azure Websites

If you are creating or have an ASP.NET Application that you would want to deploy on Azure Websites, its just 3 steps.
1.       Create the website in Azure portal.
2.       Download the publish profile
3.    Publish the Web Project and provide the publish profile location in the wizard and complete the deployment

For a beginner level how-to article on Azure Websites, check out 

For advanced scenarios, check out 

So, the customer now has a quick solution to have his legacy web apps run on Azure using Azure Websites option.
You can read more about Azure Websites here.

Trivia: An Azure Website hosted in FREE and Shared Mode are the same except the capacity and the load that can be handled is higher in Shared Mode. 

Thursday, April 25, 2013

Journey to the Cloud with Windows Azure - Scenario I - Azure Cloud Services

One of the responsibilities in my new job is to help customers adopt and migrate to Windows Azure.  A majority of our customers choose Windows Azure as the cloud platform for optimizing costs while improving the performance and scalability of their apps.
While it would be great to architect an app ground up for the Azure platform, real life customers have a lot of their existing apps that need to be migrated. 

Typical customers’ on premise applications are web applications developed in .NET 2.0, .NET 3.5 or .NET 4.0 running SQL Server as the back end.  Some of the apps also have middleware services built using Web Services or WCF Services. 

There can never be a complete architecture without integration of existing LOB Applications.  Not surprisingly, most of these apps have integration with their internal AD, LDAP or other authentication subsystems. 

Most of these apps were developed in days where the organization had lesser man power, more time to manage and fewer demands for these systems. With the increase in employee workforce, more and more demand for these applications, the decision to move to cloud becomes all the more important.
But the biggest question customer’s face is how does one go about re-architecting these systems for Windows Azure? 

In the following series of posts we will see where each of the components fit. We'll delve through different scenarios and also on which Azure offering best fits the scenario.

Scenario I
A Retail customer has several of his web applications written using .NET Framework with SQL Server as backend. The applications are enterprise applications which are multi-tiered, with several scheduled jobs that are run in backend. The application is architected well using Best Practises prescribed by Microsoft.
The following are some of the top challenges he is facing currently and evaluating the options for moving to cloud:
1. The web applications are being used by customers world-wide and the performance becomes a concern many times, during Promotional offers.
2. The customers using the applications are increasing by time and its becoming difficult to increase the hardware for scaling out the applications.
3. Managing IT operations costs is becoming huge and this needs to be optimized

Which Azure offering best suits this scenario?

With this scenario, we see the first and foremost component to be migrated are   Web Applications – typically built using ASP.NET 3.5 or ASP.NET 4.0 in the recent past using Visual Studio 2008 or Visual Studio 2012.  This looks a straight forward candidate for Windows Azure Cloud Services.

Windows Azure Cloud Services offers Virtual Machines or what we call as Web Roles that run your ASP.NET Applications on the cloud with little bit of additional packaging and configuration.
The scheduled jobs and other start up tasks that the customer runs are taken care by what are called as Worker Roles, which are basically Windows Services that are run in Virtual Machines.

The "How" part:

For migration to cloud using Cloud Services, all you need is Visual Studio and the Windows Azure SDK (a free download toolkit that can be downloaded from here).  In case you are fine with command line utilities, you can even use the Windows Azure Powershell commandlet to compile and package your application to deploy in cloud services.  

You can download windows azure command line utilities from here.

As per the scenario in discussion,  you have an ASP.NET Application which reads data from SQL Server Database or any other Service.  There are also some scheduled jobs that need to be migrated. Both these applications ("Projects" in terms of Visual Studio) can be migrated by adding a Cloud Project Template (available in Visual Studio 2010/Visual Studio 2012).  You can even simulate the cloud platform using the Emulator that ships along with the Windows Azure SDK.  So, the first time you add the cloud project template and run the application locally, it would open up the emulator where you can see how, in the cloud environment the web roles would be provisioned.  Is this not awesome? Having seen how difficult it is with other cloud providers to simulate a "cloud-like" environment and debug in local machine, Windows Azure is definitely a boon!

Finally publishing to Azure is as simple as a right-click -> Publish from Visual Studio

In the spirit of DRY (do not repeat yourself - keeping things in a central place), I am going to provide the resource available in for a step by step detail on migrating existing ASP.NET Applications to Cloud Services:

To sum this post, if you have an ASP.NET Application written using .NET 3.5 and above, the logical choice to port to Azure would be is to use a Cloud Service Project.

Moreover, Cloud Service Project offers the flexibility of using Remote Desktop to remote login and manage the virtual machine, in addition to setting up preconfigured installers that are required for the application (installing a reporting component or any dependant assembly).
Finally, if you want to migrate a three-tier application with Web Services/WCF Service in a separate Service or having them on-premise etc., then Windows Azure Cloud Service is your best bet.

Subsequent posts will concentrate on other scenarios that will best fit for Azure Websites and other Cloud Components.

Trivia: A Web Role can have multiple web applications hosted and a web application can be hosted in multiple web roles.