Azure – How to give full acess to a shared folder in workgroup – Windows Server 2012 R2

azurewindows-server-2012

I got into a situaltion where I have three VMs in azure which are part of same workgroup. I got a requirement whrere I need to copy files in a shared folder in one of the VMs and from the other two VMs via an ASP.NET application. These two VMs are webservers and accessed via load balancer. The problem here is that they are not in a domain.

I referred How to set shared files permission across a network? and accordingly created user on all three servers with same credentials and impersonated the asp.net application with same user but that is not behaving as expected in all scenarios. Although it does work in some situation for small files.

Fundamentally I find the provided solution is wrong because if we create local users with same credentials on multiple machines (even in a workgroup) then also that user should not be able to access the folder on different machine.

Please help in following two points

1- I have a local user with same credential on all three VMs which I used to login. I gave the full rights to the user on shared folder. I am able to browse the folder and do all operations(Create\Edit\Delete) from any of the VMs. So I think it should work as discussed above. Suggestion please.

2- Any other approach for to handle this scenario.

Best Answer

My recommendation is NOT to create a shared folder inside a VM, it will cause you headache in the long run, from your description also, it seems that you might even get the ability to get rid of a VM since you sound like you're only using it to host the shared folder.

Azure got you covered on this area with a service called "Azure File storage", it is basically shared folders created on top the Azure Storage, that will allow shared access to its content. you may use it just like any other shared folder on a network.

  • Authentication in this case is done using encrypted keys, so you don't have to create local users in order to connect the VMs.
  • Since the Azure File Storage is hosted on top of an Azure Storage, you actually get the SLA of the storage it self, unlike hosting the files in the VM.

You may read all about it here along with step by step documentation on how to create and configure the service: http://azure.microsoft.com/en-us/documentation/articles/storage-dotnet-how-to-use-files/

Related Topic