side-by-side configuration issure in an windows azure virtual machine

729 views Asked by At

I'm doing a experiment on purpose of making a executable program work on windows azure.

First i tried to make it work using remote desktop with windows azure roles(ref http://msdn.microsoft.com/en-us/library/windowsazure/gg443832.aspx), I copied my exe into the remote desktop, and also some dlls, then I use "regsvr32.exe" to register these dlls, then the problem came: "side by side configuration is incoreect".

I know how to resolve this problem when it is in my own computer(just make sure the right dependencies are in the "winsxs" directory ), but now it's in the remote desktop using windows azure roles, and I have no permission to add the right dependencies into the winsxs directory. so here I came to ask for some help, thanks in advance!

PS: I can't change these dlls referenced by my exe.

1

There are 1 answers

4
AvkashChauhan On BEST ANSWER

I would say that the problem could be only because a few of the reference DLL are not in the Azure VM so when you deploy your package (EXE + DLL) you need to be sure you all the components and they are registered in the system. It sure is good that you can log into Azure VM using RDP and test how your deployment works however the best would be to deploy your package through a web/worker and in your can a worker role seems good fit.

You still need to dig further to find out why EXE did not work and if you provide more details about the libraries and process, we may help but above info is very less to provide suggestions.

To solve such problem here is what you should do:

  1. Create a zip file and include all the reference DLL/ EXE, static file needed for your application
  2. Create a Worker role and add this zip file as content and set its property Copy local to true.
  3. Add a CMD Batch file to your Azure Project and write all the steps as below:

    3.1. Unzip the files to a local folder 3.2. Register all the DLL using Regsvr32 process 3.3. Setup your exe as ProgramEntryPoint into ServiceDefinition.csdef

Using your EXE as ProgramEntryPoint, worker role host process will start it and monitor it, the setting looks like as below:

<Runtime executionContext="limited">
 <EntryPoint>
   <ProgramEntryPoint commandLine="your_exe_name.exe" setReadyOnProcessStart="true" />
 </EntryPoint>
</Runtime>

Once you have above settings, you can deploy the Azure Package and then RDP to Azure VM and test if your application has any problem.