2

I am new to Microsoft Azure and working on a MVP for a client. I am able to successfully deploy my ASP.NET MVC web app to a Web Role. The issue I'm facing is that Azure Web Role seems to recycle itself and revert to the deployment package. This leads to rollback of manual changes done (if any) after the deployment (like I allow user to upload profile images and am storing them in file system).

Is this the expected behavior? If not, when can I look from debugging purposes?

Looking for any help possible.

Manoj Garg
  • 21
  • 1
  • Perhaps Azure Web Roles is not the right platform for your needs. Try looking into Web Applications - these are perfect for running MVC – trailmax Jun 07 '17 at 13:08
  • @trailmax - Or... the OP needs to follow the guidance of web roles, which are stateless virtual machines, with a ton of guidance written about them, and how to properly deploy apps. – David Makogon Jun 07 '17 at 15:38

1 Answers1

3

Is this the expected behavior? If not, when can I look from debugging purposes?

It is expected behavior. Azure Fabric Controller is responsible for managing the Virtual Machines in which your WebRole runs. It takes care of patching the VM and do other maintenance related work on that VM. It is also responsible for taking out faulty VMs and replace them with brand new VMs. When the replacement happens, Fabric Controller will create the new VM based on the last deployment package.

You should not be making any changes manually after VM hosting WebRole has been created, these are Stateless VMs. Any changes you make to VM will be rolled back if Fabric Controller decides to recycle the VM. Please note that these changes do persist if the VM is simply rebooted.

Gaurav Mantri
  • 128,066
  • 12
  • 206
  • 241