Deploy exe on a worker role

Hello,
I want to deploy my c++ exe on a worker role. My exe takes 2 argument PathOfinput.txt and PathOfoutput.txt . When I run my web app locally it works And I obtained the output.file in the right path That I already gave it as an argument to my exe.
The problem is when I publish my service on cloud I was not able to locate my output.txt. Do I need to add code to upload output.txt to localstorage account?
Is it possible to run the exe on cloud and use my local computer for the storage of input.txt and output.txt??
I will be grateful if you respond me as soon as possible
thanks.

Hi,
As far as I know, we usually not upload file to azure worker role, if the worker role instance scale to two instances or more, we will failed to read these uploaded files, I would suggest you use azure storage to do this.
Best Regards,
Jambor
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.

Similar Messages

  • Deploy Files In Azure Worker Role

    I have a worker role that uses the MAF framework. That means I need to add assemblies that my project do not reference directly, and these files need to be in a specific folder structure(http://msdn.microsoft.com/en-us/library/bb384201.aspx).
    I had the same scenario with a web role and was able to achieve this because when you package a web role, it can copy every file found in the project folder. So I had a BeforeBuild event that would copy all the files to my bin folder for my web app, and all
    the files in there were packaged in my azure package.
    The same thing does not apply to worker roles. Before the build I create the folder structure in the bin\config folder, I can see the structure there, but the files do not get copied in the azure package at the end. I know the usual way to achieve this is
    to add a reference to those dll and set them to copy local, but that won't place the files in the required folder structure.
    Another way around would be to add custom code that would load those files from azure storage, and copy them when the role is starting, but that means I need to make extra steps everytime I deploy, and make sure that the storage is updated at the same time
    of my package. I was wonedring if there was any other way to achieve this. I cannot believe that this is completely unsupported. I did not create a custom framework for my add-ins, I am usign the one provided by Microsoft with the .NET framework, so I really
    hope there is a way to add those files to the azure package.
    Thanks, Louis

    Here is what I dened up doing to achieve this:
    Make a copy of the Microsoft.WindowsAzure.targets file found in the MSBuild folder to your Azure project folder. (C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\Windows Azure Tools\1.6 was the folder for me)
    Modify the filed you just copied to comment a part that would delete any "oprhan" file that does not belong to the role it is building. Without removing this, the file will get deleted automatically because it will detect that the project does not need it.
    <ItemGroup>
          <OrphanedWorkerFiles Include="$(IntermediateWorkerOutputPath)**\*.*" Exclude="@(WorkerFiles->'$(IntermediateWorkerOutputPath)%(TargetPath)')" />
        </ItemGroup>
        <Delete Files="@(OrphanedWorkerFiles)" ContinueOnError="true" />
    That can be found on line 2864 with version 1.6 of the Azure SDK. Comment it out or remove it.
    Modify the ccproj file of your Azure project to point to that file instead fo the original one. The import should now look like this: <Import Project="$(ProjectDir)Microsoft.WindowsAzure.targets" />
    You can then add a <Target Name="BeforeBuild"></Target> node in that ccproj file, or add before build events in that project that will copy the required file to this folder: $(ProjectDir)obj\$(ConfigurationName)\[Azure role], and replace [Azure
    role] by the name of the role you want to copy these files to.
    Once you've done that, you can rebuild your solution, and any files copied during your before build event will be included in your final azure package.
    Cheers!

  • Starting Worker role

    Hi all,
    I created a cloud service. and I deployed my exe on the worker role. When I do publish the worker role run just there I see the new files added to my storage container. When I access to the website url after the publish It does not work. I see my web page
    but in the storage container nothing added or updated.
    here is my code
    using System;
    using System.Collections.Generic;
    using System.Diagnostics;
    using System.IO;
    using System.Linq;
    using System.Net;
    using System.Threading;
    using System.Threading.Tasks;
    using Microsoft.WindowsAzure;
    using Microsoft.WindowsAzure.Diagnostics;
    using Microsoft.WindowsAzure.ServiceRuntime;
    using Microsoft.WindowsAzure.Storage;
    using Microsoft.WindowsAzure.Storage.Auth;
    using Microsoft.WindowsAzure.Storage.Blob;
    namespace WorkerRole1
    public class WorkerRole : RoleEntryPoint
    private readonly CancellationTokenSource cancellationTokenSource = new CancellationTokenSource();
    private readonly ManualResetEvent runCompleteEvent = new ManualResetEvent(false);
    public override void Run()
    Trace.TraceInformation("WorkerRole1 is running");
    // For information on handling configuration changes
    // see the MSDN topic at http://go.microsoft.com/fwlink/?LinkId=166357.
    string accountName = "xxxxx";
    string accountKey = "xxxxx";
    TextWriter tw = new StreamWriter("LogFile.txt");
    var appRoot = Path.Combine(Environment.GetEnvironmentVariable("RoleRoot") + @"\", @"approot");
    var appRootexe = Path.Combine(appRoot, @"Solve.exe");
    var appRootinput = Path.Combine(appRoot, @"inputOnCloud.txt");
    var appRootoutput = Path.Combine(appRoot, @"outputOnCloud.txt");
    var arguments = appRootinput + " " + appRootoutput;
    StorageCredentials creds = new StorageCredentials(accountName, accountKey);
    CloudStorageAccount account = new CloudStorageAccount(creds, useHttps: true);
    CloudBlobClient client = account.CreateCloudBlobClient();
    CloudBlobContainer sampleContainer = client.GetContainerReference("sondesoncloud");
    sampleContainer.CreateIfNotExists();
    tw.WriteLine(DateTime.Now);
    tw.WriteLine("This is a LogFile \n");
    tw.WriteLine("Create the container \n");
    sampleContainer.SetPermissions(new BlobContainerPermissions()
    PublicAccess = BlobContainerPublicAccessType.Container
    CloudBlockBlob blob1 = sampleContainer.GetBlockBlobReference("finalinputonazure.txt");
    using (Stream input = new FileStream(appRootinput, FileMode.Create))
    blob1.DownloadToStream(input);
    tw.WriteLine("Download the input file from the storage account \n");
    tw.WriteLine("Run the solver \n");
    // CALL THE SOLVER
    // Process.Start(appRootexe, arguments);
    Process myProcess = new Process();
    myProcess.StartInfo.FileName = appRootexe;
    myProcess.StartInfo.Arguments = arguments;
    if (System.Environment.OSVersion.Version.Major >= 6)
    myProcess.StartInfo.Verb = "runas"; // Run the exe as administrator
    myProcess.StartInfo.CreateNoWindow = true;
    myProcess.Start();
    myProcess.WaitForExit();
    tw.WriteLine("Finish running successfully \n");
    tw.Close();
    CloudBlockBlob blob3 = sampleContainer.GetBlockBlobReference("LogFile.txt");
    using (Stream file = System.IO.File.OpenRead("LogFile.txt"))
    blob3.UploadFromStream(file);
    CloudBlockBlob blob2 = sampleContainer.GetBlockBlobReference("ResultsOnCloud.txt");
    // blob2.Properties.ContentType = "ResultsOnCloud/text";
    using (Stream file = System.IO.File.OpenRead("outputOnCloud.txt"))
    blob2.UploadFromStream(file);
    public override bool OnStart()
    // Set the maximum number of concurrent connections
    ServicePointManager.DefaultConnectionLimit = 12;
    bool result = base.OnStart();
    Trace.TraceInformation("WorkerRole1 has been started");
    return result;
    public override void OnStop()
    Trace.TraceInformation("WorkerRole1 is stopping");
    this.cancellationTokenSource.Cancel();
    this.runCompleteEvent.WaitOne();
    base.OnStop();
    Trace.TraceInformation("WorkerRole1 has stopped");
    private async Task RunAsync(CancellationToken cancellationToken)
    // TODO: Replace the following with your own logic.
    while (!cancellationToken.IsCancellationRequested)
    Trace.TraceInformation("Working");
    await Task.Delay(1000);
    I want to create then a http client (c++) which access my service via the website url. and this is not possible because of this problem.
    Please I need your help, I am new to cloud.
    Thanks.

    Hi S.Marzuki,
    >>And it works fine this time. did this charge me extra money?
    Yes, if the VM always is running, Azure platform will charge it by hours.
    Another way, You could code some function in your web role to manage the worker role status, you could use the Mangement API to change the worker role status (http://msdn.microsoft.com/en-us/library/ee460808.aspx
    ). Also, you could see this thread(https://social.msdn.microsoft.com/forums/azure/en-us/a5e3411e-4cf1-439c-a927-965970b8b439/start-and-stop-worker-role-programmatically
    Regards,
    Will
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • 'Not running in a hosted service or the Development Fabric' exception on deployed Worker role

    We are getting this exception after a worker role has been operating fine in production for several weeks.  Once this exception starts getting reported, it will keep getting it every time the worker role tries to access anything with the Diagnostics:
    Not running in a hosted service or the Development Fabric
    Note that the role is full trust, and as I mentioned this in in production on the Azure servers, NOT in debug.  The worker role itself does some dynamic compilation, for which it needs to start a new AppDomain.  It appears that the exception is
    coming from the spawned AppDomain when it occurs.  The exception itself is triggered on a simple Trace.TraceInformation call.
    What could cause this?
    What can we do to recover from this?

    We are getting this exception after a worker role has been operating fine in production for several weeks.  Once this exception starts getting reported, it will keep getting it every time the worker role tries to access anything with the Diagnostics:
    Not running in a hosted service or the Development Fabric
    Note that the role is full trust, and as I mentioned this in in production on the Azure servers, NOT in debug.  The worker role itself does some dynamic compilation, for which it needs to start a new AppDomain.  It appears that the exception is
    coming from the spawned AppDomain when it occurs.  The exception itself is triggered on a simple Trace.TraceInformation call.
    What could cause this?
    What can we do to recover from this?
    Hi,
    I have tested this situation in Windows Azure platform and i can not reproduce your exception message, my test code in follwoing MSDN samples and i deploy it in Production status.
    The MSDN article (include Appdomain code snippets)
    http://msdn.microsoft.com/en-us/library/system.appdomain.aspx .
    Base on my understand, the "Not running in a hosted service or the Development Fabric" error message occur when Azure Emulator or Azure development fabirc, because you create a new appdomain in WorkRole, and it may cause permission errors, a similar
    posts by my research:
    https://social.msdn.microsoft.com/Forums/en-US/windowsazuretroubleshooting/thread/50987285-58ac-484e-b604-725fe01a3325
    If you still have some problems, please inform me. Thank you.
    Please mark the replies as answers if they help or unmark if not. If you have any feedback about my replies, please contact
    [email protected]
    Microsoft One Code Framework

  • How to deploy worker role to Azure cloud via portal

    Hi
    I have two worker roles in my VS Project and I need them to be running on Azure cloud. I have created the storage accounts, the worker roles are using Queues, that I created using c# code.
    I looked up some articles and they say I have to create a hosted services from top left corner, but I don't see any hosted service link on my portal. (I am thinking the new version of Azure Portal does not have hosted service link, probably been replaced
    with something else but I don't know what it is)
    Can someone please help me what to do after I create a package and have the config and package files in app.publish folder. How to deploy the  worker roles in cloud using the Portal
    Thanks
    -Sarah

    Hi,
    >>I looked up some articles and they say I have to create a hosted services from top left corner
    As far as I know, cloud service was called hosted service in old azure platform, see below old platform screenshot.
    About deploy your application to cloud service, please refer to
    http://azure.microsoft.com/en-us/documentation/articles/cloud-services-how-to-create-deploy/ for more detail information.
    Best Regards,
    Jambor
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How to develop and deploy multiple worker roles in single azure cloud services?

    I am Manikandan, From Myeasydocs.com.
    We have developed our application as web projects.  Now we are going to move to azure cloud services, i have successfully migrated our application in cloud services and it worked fine. I am having difficulties with back ground task. i have nearly 12
    schedule tasks in our applications. I need assist on creating multiple worker role creation and deployment.
    Is there is any site on explaining the worker role process in details?
    Thanks in advance .. !!

    Hi,
    In Worker role, Applications hosted within worker roles can run asynchronous, long-running or perpetual tasks independent of user interaction or input. It is a service component that is useful for generalized development, and may perform background processing
    for a web role. A worker role is frequently used for long-running tasks that are non-interactive, but you can host any type of workload.
    I suggest you to follow the below article which explains about Creating and Deploying of Web Roles and Worker Roles in Azure Cloud Service using Visual Studio.
    https://msdn.microsoft.com/en-us/magazine/jj618299.aspx
    Hope this helps !
    Regards,
    Sowmya

  • Deploy windows azure worker role

    Hi,
       I've created a simple azure worker role which executes few things in the database continuously and I need to deploy this worker role to azure portal. how can i deploy an azure worker role to azure portal.
    thanks,
    Snegha

    Hi robdmoore67,
        I deployed my worker role using the below option
    Deploy using Visual Studio by linking your Visual Studio to your subscription, right-clicking the cloud project and selecting Publish; see this link for more info: http://msdn.microsoft.com/en-us/magazine/jj618299.aspx
    deployment went success but my worker role is not running on the background i guess.
    this is my below code on workerrole.cs
         public override void Run()
                // This is a sample worker implementation. Replace with your logic.
                Trace.TraceInformation("WorkerRole entry point called", "Information");
                while (true)
                    _myService = new MYService();
                    _myService .Start();
                     Trace.TraceInformation("Working", "Information");
            public override bool OnStart()
                // Set the maximum number of concurrent connections
                ServicePointManager.DefaultConnectionLimit = 12;
                // For information on handling configuration changes
                // see the MSDN topic at http://go.microsoft.com/fwlink/?LinkId=166357.
                return base.OnStart();
    but this works fine when i try to debug locally. Kindly let me know if there is any mistake.
    kind regards,
    Snegha
      

  • Is it possible to do Continuous deployment for azure cloud services(website,web and worker roles) using VSO Release management?

    Hi,
    I am trying to do continuous deployment using visual studio online and release management for Azure cloud services. But not able to find the way to do it(with the help of different blogs, those are describing using VM only).
    I tried using Release management visual studio extension also. But no Luck.
    Please help me if it is possible to do continuous deployment using release management.
    Thanks,
    Phani

    Hi,
     Please refer to the following Forum Thread with similar question which has been answered. Let us know if this helps.
     https://social.msdn.microsoft.com/Forums/en-US/9d8322f6-36e5-4cca-a982-d420d34d2072/realease-management-deployment-to-azure-websites-webworker-roles?forum=tfsbuild
    Regards,
    Nithin Rathnakar

  • Unexpected recycling of worker role

    Hi all
    I've deployed a worker role to Azure and it ran smoothly from February 3rd to February 25th.
    On February 26th, the worker role was "silently" recycled.
    I would like to understand what happened and if there are scheduled recycling operations or specific conditions triggering a recycle.
    The VM was operating normally for both CPU and memory. I couldn't find any error in Event viewer or in stored diagnostics.
    This is the only useful message (WAHostBootstrapper.log):
    [00002252:00003224, 2015/02/26, 03:52:06.491, INFO ] Sending shutdown notification to client DiagnosticsAgent.exe (2248).
    [00002252:00003224, 2015/02/26, 03:52:06.491, INFO ] Sending shutdown notification to client WaWorkerHost.exe (2904).
    Thanks
    Francesco

    Hi Francesco,
    Is your worker role instances in recycling status currently? Which region did you host your  cloud service?
    I saw some mantance log about cloud service /VM from Azure Status dashboard (http://azure.microsoft.com/en-us/status/#history ):
    Virtual Machines \ Service Management and Cloud Services \ Service Management - West Europe - Advisory
    This incident has now been mitigated. From 26 FEB, 2015 23:00 to 27 FEB, 2015 08:15 UTC a subset of customers using Cloud Services \ Service Management and Virtual Machines \ Service Management in West Europe might have seen failures when attempted to
    create new VMs or to restart their existing VMs.
    If you always have this issue, please let me know.
    Regards,
    Will
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • JRE7Update25 Deployment Properties File Not Working And Cant Disable Next Gen Plugin

    Good Day
    Our organisation needs to deploy JRE7U25 to over 4000 workstations. Our desktops are running the following Windows and IE combinations:
    WinXP 32 Bit/IE7
    WinXP 32 Bit/IE8
    Win7 32 Bit/IE8
    Win7 32 Bit/IE9
    Win7 64 Bit/IE8
    Win7 64 Bit/IE8
    We use the 32bit JRE installer across all environments and all IE browsers use 32Bit IE. On all of our environments the Deployment.properties and config files no longer work due to what appears to be a bug in the JRE7U25 installer. Our deployment files are as follows:
    Deployment.config
    deployment.system.config=C:\WINDOWS\Sun\Java\Deployment\deployment.properties
    deployment.system.config.mandatory=true
    Deployment.properties
    deployment.security.level=MEDIUM
    deployment.security.level.locked=
    deployment.javaws.autodownload=NEVER
    deployment.javaws.autodownload.locked=
    deployment.security.mixcode=HIDE_RUN
    deployment.security.mixcode.locked=
    deployment.console.startup.mode=HIDE
    deployment.console.startup.mode.locked=
    Both files are being copied to the following location:
    C:\Windows\Sun\Java\Deployment
    After the installer runs and deployment files are copied to the workstation the deployment.properties and config files look like this:
    Deployment.config
    deployment.system.config=C:\WINDOWS\Sun\Java\Deployment\deployment.properties
    deployment.system.config.mandatory=true
    Deployment.properties
    #System Deployment Properties
    #Mon Jul 01 12:29:20 CAT 2013
    deployment.security.level=MEDIUM
    I have tried changing the deployment.config file as follows in an attempt to fix this to no avail:
    1. deployment.system.config=C:\\WINDOWS\\Sun\\Java\\Deployment\\deployment.properties
        deployment.system.config.mandatory=true
    2. deployment.system.config=C:\\WINDOWS\\Sun\\Java\\Deployment\\deployment.properties
        deployment.system.config.mandatory=false
    3. deployment.system.config=C:\WINDOWS\Sun\Java\Deployment\deployment.properties
        deployment.system.config.mandatory=true
    4. deployment.system.config=C:\WINDOWS\Sun\Java\Deployment\deployment.properties
        deployment.system.config.mandatory=false
    5. deployment.system.config=file\:C\:/WINDOWS/Sun/Java/Deployment/deployment.properties
    None of the above mentioned works. So all our required settings in the deployment.properties file are being overwritten when opening the Java console? Our other major problem is that Changing the registry key to 0 in order to disable the next generation plugin does not disable the next generation plugin in Jre at the usual location as it worked for us machine wide (across multiple profiles for JRE6U29):
    [HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Plug-in\10.25.2]
    "UseNewJavaPlugin"=dword:00000000
    ^^I have observed on a fresh install of JRE7U25 that the above mentioned registry key no longer exists in this version so a computer wide disablement of this option is no longer possible via the registry.
    On our 32Bit and 64bit machines running the 32 bit JRE 7U25 client when we disable the next generation plugin it keeps enabling itself again. Even when we run the javacpl.exe to run as administrator by changing the compatibility settings and disabling the next generation plugin it enables itself again. This is a huge problem for us because our company Oracle web based applications need this plugin to be disabled in order to run the apps properly.
    These are major obstacles for our deployment as we desperately require assistance or any advice in addressing these issues as there appear to be numerous bugs with the JRE7U25 release. Thank you in advance.
    Update 7 July 2013:
    I have observed that if you have the following options in your Deployment.config file it doesn't allow our java webstart apps which use jnlp extensions to run.
    1. deployment.system.config=C:\\WINDOWS\\Sun\\Java\\Deployment\\deployment.properties
        deployment.system.config.mandatory=true
    2. deployment.system.config=C:\\WINDOWS\\Sun\\Java\\Deployment\\deployment.properties
        deployment.system.config.mandatory=false
    3. deployment.system.config=C:\WINDOWS\Sun\Java\Deployment\deployment.properties
        deployment.system.config.mandatory=true
    4. deployment.system.config=C:\WINDOWS\Sun\Java\Deployment\deployment.properties
        deployment.system.config.mandatory=false
    The jnlp file association is also broken on Windows XP workstations with JRE7U25. We are having to manually associate the .jnlp file extension with javaws.exe on workstation for Web start apps or else users cannot lauch JRE whn clicking on .jnlp links.
    The only Deployment.config syntax which allows our Webstart applications to run is as follows:
    deployment.system.config=file\:C\:/WINDOWS/Sun/Java/Deployment/deployment.properties
    What a mess!

    I don't have an answer to the problem, but I am having problems with the system level deployment.properties file and IE9 on Windows 7 32/64bit.
    Starting with version 13, the IE plugin seems to igonore the system level deployment.properties file in favor of the user level deployment.properties file. When I open the Java Control Panel, the settings are correct per the system deployment.properties file. Currently to get the Java Plugin to work reliably in IE9 I have to set the following:
    _JAVA_OPTIONS = -Djava.net.preferIPv4Stack=true
    Disable caching
    Set the proxy to Direct Connection.
    If I set the _JAVA_OPTIONS as an environment variable and the other two in the system deployment.properties file, Firefox works fine, but IE wont load either of the Java tests. If I removed the system deployment.properties files and configure the user deployment.properties file, both IE and Firefox work fine.
    I find it interesting that if I set the configuration through the control panel, then apply the system deployment.propteries file, the user deployment.properties file reverts to defaults when the system file is removed.

  • How to move worker roles to VM?

    I've developed an app that has 3 worker roles and a web role.  The client has decided that they want to put this on a VM.  I understand how to handle the web role but I am unclear how I convert the worker roles.  I've searched but I can't
    find anything that directly guides me on what's needed.  Does anyone know of a link that would show me how to convert over?

    The easiest way to develop a Windows Service in my opinion is using
    Topshelf.
    You can convert your Worker Role code across pretty easily by
    calling the Run code from the WhenStarted event, the OnStop code from the WhenStopped event and the OnStart code from the constructor of your service class.
    Alternatively, you can
    inherit the ServiceControl interface and implement the Start and Stop methods.
    Deploying the service is easy too. Simply get the built files from your console app (a Topshelf service is simply a console app) and
    invoke the app (e.g. PowerShell script) with the install parameter, then again with the start parameter.

  • VS 2013 crashes on opening Worker Role configuration

    After creating a cloud project using Azure SDK for .NET 2.4 then Visual Studio 2013 (update 3) crashes when I attempt to edit the Role Configuration via the UI by double clicking the [Cloud Project] -> Roles -> [Worker Role Name] in Solution Explorer.
    The event details as text looks like this.
    Application Error
    Log Name: Application
    Source: Application Error
    Date: 12-09-2014 10:33:59
    Event ID: 1000
    Task Category: (100)
    Level: Error
    Keywords: Classic
    User: N/A
    Computer: [removed].[removed].com
    Description:
    Faulting application name: devenv.exe, version: 12.0.30723.0, time stamp: 0x53cf6f00
    Faulting module name: KERNELBASE.dll, version: 6.1.7601.18409, time stamp: 0x53159a86
    Exception code: 0xe0434352
    Fault offset: 0x0000c42d
    Faulting process id: 0x1f54
    Faulting application start time: 0x01cfce63c98e92fb
    Faulting application path: C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe
    Faulting module path: C:\Windows\syswow64\KERNELBASE.dll
    Report Id: 8a86cb32-3a57-11e4-857a-0026b9e0fb6f
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
    <System>
    <Provider Name="Application Error" />
    <EventID Qualifiers="0">1000</EventID>
    <Level>2</Level>
    <Task>100</Task>
    <Keywords>0x80000000000000</Keywords>
    <TimeCreated SystemTime="2014-09-12T08:33:59.000000000Z" />
    <EventRecordID>213664</EventRecordID>
    <Channel>Application</Channel>
    <Computer>[removed].[removed].com</Computer>
    <Security />
    </System>
    <EventData>
    <Data>devenv.exe</Data>
    <Data>12.0.30723.0</Data>
    <Data>53cf6f00</Data>
    <Data>KERNELBASE.dll</Data>
    <Data>6.1.7601.18409</Data>
    <Data>53159a86</Data>
    <Data>e0434352</Data>
    <Data>0000c42d</Data>
    <Data>1f54</Data>
    <Data>01cfce63c98e92fb</Data>
    <Data>C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe</Data>
    <Data>C:\Windows\syswow64\KERNELBASE.dll</Data>
    <Data>8a86cb32-3a57-11e4-857a-0026b9e0fb6f</Data>
    </EventData>
    </Event>
    .NET Runtime
    Log Name: Application
    Source: .NET Runtime
    Date: 12-09-2014 10:33:59
    Event ID: 1026
    Task Category: None
    Level: Error
    Keywords: Classic
    User: N/A
    Computer: [removed].[removed].com
    Description:
    Application: devenv.exe
    Framework Version: v4.0.30319
    Description: The process was terminated due to an unhandled exception.
    Exception Info: System.AggregateException
    Stack:
    at System.Runtime.CompilerServices.AsyncMethodBuilderCore.<ThrowAsync>b__4(System.Object)
    at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
    at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
    at System.Windows.Threading.DispatcherOperation.InvokeImpl()
    at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(System.Object)
    at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
    at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
    at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
    at System.Windows.Threading.DispatcherOperation.Invoke()
    at System.Windows.Threading.Dispatcher.ProcessQueue()
    at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
    at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
    at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
    at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
    at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
    at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
    at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
    <System>
    <Provider Name=".NET Runtime" />
    <EventID Qualifiers="0">1026</EventID>
    <Level>2</Level>
    <Task>0</Task>
    <Keywords>0x80000000000000</Keywords>
    <TimeCreated SystemTime="2014-09-12T08:33:59.000000000Z" />
    <EventRecordID>213663</EventRecordID>
    <Channel>Application</Channel>
    <Computer>[removed].[removed].com</Computer>
    <Security />
    </System>
    <EventData>
    <Data>Application: devenv.exe
    Framework Version: v4.0.30319
    Description: The process was terminated due to an unhandled exception.
    Exception Info: System.AggregateException
    Stack:
    at System.Runtime.CompilerServices.AsyncMethodBuilderCore.&lt;ThrowAsync&gt;b__4(System.Object)
    at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
    at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
    at System.Windows.Threading.DispatcherOperation.InvokeImpl()
    at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(System.Object)
    at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
    at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
    at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
    at System.Windows.Threading.DispatcherOperation.Invoke()
    at System.Windows.Threading.Dispatcher.ProcessQueue()
    at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
    at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
    at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
    at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
    at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
    at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
    at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)
    </Data>
    </EventData>
    </Event>
    Just prior to the crash...
    ...it seems like VS 2013 is attempting to log me in to a company server (active directory?). Regardless of my action (providing my login credentials or cancelling the login) VS 2013 then proceeds to crash.
    My other computers
    On my private laptop that connects to the internet via a private internet connection, the same type of project loads the configuration page w.o. issues (same VS and SDK configuration).
    Others have this issue as well
    There is also a thread about this on SO, although without a solution:
    Visual Studio 2013 crashes when opening up service configuration for edit
    Can anybody provide any help about how to solve this, please?
    Br,
    Claus

    Hi Will
    Thanks for your answer - I have added my findings below:
    The problem apparently stems from the authentication process.
    If you are using your company email as username on Azure, the inherent domain name will cause the authentication method to redirect you to your company's Active Directory.
    The problem can be solved by choosing a different email as username on Azure.
    The problem can also be replicated by setting up a website with authentication using Azure Active Directory. During login through Azure AD, the exact moment you enter the domain name in your username, the login screen redirects you from the Azure AD to the
    AD at sts.[email domain name] - and consequently, the login fails. Using a different username the Azure AD authentication works flawlessly.
    Br,
    Claus

  • Autoscaling Application block for Azure worker role console app not working. Get error as The HTTP request was forbidden with client authentication

    I have written a console application to test the WASABi(AutoScaling Application Block) for my worker role running in azure. The worker role processes the messages in the queue and I want to scale-up based on the queue length. I have configured and set the
    constraints and reactive rules properly. I get the following error when I run this application.
    [BEGIN DATA]{}
        DateTime=2013-12-11T21:30:02.5731267Z
    Autoscaling General Verbose: 1002 : Rule match.
    [BEGIN DATA]{"EvaluationId":"4f9f7cb0-fc0d-4276-826f-b6a5f3ea6801","MatchingRules":[{"RuleName":"default","RuleDescription":"The default constraint rule","Targets":["AutoscalingWebRole","AutoscalingWorkerRole"]},{"RuleName":"ScaleUpOnHighWebRole","RuleDescription":"Scale
    up the web role","Targets":[]},{"RuleName":"ScaleDownOnLowWebRole","RuleDescription":"Scale down the web role","Targets":[]},{"RuleName":"ScaleUpOnHighWorkerRole","RuleDescription":"Scale
    up the worker role","Targets":[]},{"RuleName":"ScaleDownOnLowWorkerRole","RuleDescription":"Scale down the worker role","Targets":[]},{"RuleName":"ScaleUpOnQueueMessages","RuleDescription":"Scale
    up the web role","Targets":[]},{"RuleName":"ScaleDownOnQueueMessages","RuleDescription":"Scale down the web role","Targets":[]}]}
        DateTime=2013-12-11T21:31:03.7516260Z
    Autoscaling General Warning: 1004 : Undefined target.
    [BEGIN DATA]{"EvaluationId":"4f9f7cb0-fc0d-4276-826f-b6a5f3ea6801","TargetName":"AutoscalingWebRole"}
        DateTime=2013-12-11T21:31:03.7516260Z
    Autoscaling Updates Verbose: 3001 : The current deployment configuration for a hosted service is about to be checked to determine if a change is required (for role scaling or changes to settings).
    [BEGIN DATA]{"EvaluationId":"4f9f7cb0-fc0d-4276-826f-b6a5f3ea6801","HostedServiceDetails":{"Subscription":"psicloud","HostedService":"rmsazure","DeploymentSlot":"Staging"},"ScaleRequests":{"AutoscalingWorkerRole":{"Min":1,"Max":2,"AbsoluteDelta":0,"RelativeDelta":0,"MatchingRules":"default"}},"SettingChangeRequests":{}}
        DateTime=2013-12-11T21:31:03.7516260Z
    Autoscaling Updates Error: 3010 : Microsoft.Practices.EnterpriseLibrary.WindowsAzure.Autoscaling.ServiceManagement.ServiceManagementClientException: The service configuration could not be retrieved from Windows Azure for hosted service with DNS prefix 'rmsazure'
    in subscription id 'af1e96ad-43aa-4d05-b3f1-0c9d752e6cbb' and deployment slot 'Staging'. ---> System.ServiceModel.Security.MessageSecurityException: The HTTP request was forbidden with client authentication scheme 'Anonymous'. ---> System.Net.WebException:
    The remote server returned an error: (403) Forbidden.
       at System.Net.HttpWebRequest.GetResponse()
       at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
       --- End of inner exception stack trace ---
    Server stack trace: 
       at System.ServiceModel.Channels.HttpChannelUtilities.ValidateAuthentication(HttpWebRequest request, HttpWebResponse response, WebException responseException, HttpChannelFactory`1 factory)
       at System.ServiceModel.Channels.HttpChannelUtilities.ValidateRequestReplyResponse(HttpWebRequest request, HttpWebResponse response, HttpChannelFactory`1 factory, WebException responseException, ChannelBinding channelBinding)
       at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
       at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)
       at System.ServiceModel.Dispatcher.RequestChannelBinder.Request(Message message, TimeSpan timeout)
       at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
       at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs)
       at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
       at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
    If anyone know why I am getting this anonymous access violation error. My webrole is secured site but worker role not.
    I appreciate any help.
    Thanks,
    ravi
      

    Hello,
    >>: The service configuration could not be retrieved from Windows Azure for hosted service with DNS prefix 'rmsazure' in subscription id **************
    Base on error message, I guess your azure service didn't get your certificate and other instances didn't have certificate to auto scale. Please check your upload the certificate on your portal management. Also, you could refer to same thread via link(
    http://stackoverflow.com/questions/12843401/azure-autoscaling-block-cannot-find-certificate ).
    Hope it helps.
    Any question or result, please let me know.
    Thanks
    Regards,
    Will 
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Guidance needed please for architecting a scheduled application process (Worker Role vs. VM Role)

    I'm close to putting all of the pieces together for an Azure Cloud Services solution that I want to build. 
    My goal is to build a .NET Library (or perhaps a Windows Service or even a Console Application) that will run once a day to execute dynamic queries against an Azure SQL DB. 
    There would be 1-x numbers of these query sets that will need to be run during the process, and after each query set an email will be sent out containing data from the query results (which shouldn't be terribly large or processor intensive) to an email
    recipient specific to that data set.  I plan on using an assigned Office 365 Mailbox as the sender account and email recipients would all be in the same Exchange organization. 
    I haven't decided on the emailing API yet, but it may require dependencies to be installed on Windows Server (e.g. the MAPI subsystem, AKA the Mail applet in Control Panel - so I can use Redemption which is a third-party replacement for the Outlook Object
    Model that doesn't require Outlook to be installed) unless I go with Exchange Web Services or the Office 365 REST APIs.
    So my main question is what's more appropriate, a VM or a Worker Role?
    Since the processing should only take 5-10 minutes to complete, I'd like to minimize the uptime of the VM or Worker Role and be able to turn it on when the scheduled time occurs, and turn it off when
    the processing is done.
    I'm also trying to understand how to fit in either the Azure Scheduler Service or the Windows Task Scheduler in the OS to auto-run my .NET application and/or Worker Role/VM.
    Any guidance would be appreciated!
    Eric Legault (MVP: Outlook)
    Co-author, Microsoft Office 2013 Professional Step-By-Step
    Try Outlook Touch!

    Hello Eric,
      There is currently no Option for automatically deploying an Azure Role, running it and then Shutting it down or Deleting it. That kind of functionality is possible using the
    Windows Azure service Management API which is used by  the Windows Azure PowerShell cmdlets.
    Regards,
    Nithin Rathnakar

  • Azure Worker Role reboots when adding instance of Web Role

    I have a Windows Azure cloud service with a Web Role and a Worker Role. I I have built a website that allows me to perform various management functions against the cloud service (stop/start, reboot instance, add instance, remove instance). All functions are
    performed via the web api. My issue is that when I add an instance of the web role, the worker role reboots. Note that this doesn't happen if I add an instance via the Azure portal. The code functions correctly in all other aspects. Any idea how to do this
    so that only the role being affected recycles instead of all roles recycling?
    My code:
     public void AddInstance()
            XDocument configDoc = this.GetDeploymentConfiguration();
            var ns = configDoc.Root.GetDefaultNamespace();
            configDoc.Root
                .Elements( ns + "Role" )
                .FirstOrDefault( r => r.Attribute( "name" ).Value.ToLower() == this.RoleName.ToLower() )
                .Element( ns + "Instances" )
                .Attribute( "count" )
                .Value = ( int.Parse( configDoc.Root
                               .Elements( ns + "Role" )
                               .FirstOrDefault( r => r.Attribute( "name" ).Value.ToLower() == this.RoleName.ToLower() )
                               .Element( ns + "Instances" )
                               .Attribute( "count" )
                               .Value ) + 1 ).ToString();
            string encodedString = Convert.ToBase64String( Encoding.UTF8.GetBytes( configDoc.ToString() ) );
            this.SetDeploymentConfig( encodedString );
        public XDocument GetDeploymentConfiguration()
            string uri = string.Format( this.servicePropertiesOperationFormat, this.subscriptionID, this.serviceName, "production", "" );
            ServiceManagementOperation operation = new ServiceManagementOperation( this.thumbprint, this.versionID );
            var xdoc= operation.Invoke( uri );
            var myelm = xdoc.Element( wa + "Deployment" ).Element( wa + "Configuration" );
            var mystring=  Encoding.UTF8.GetString( Convert.FromBase64String( myelm.Value ) );
            return XDocument.Parse( mystring );
        public string SetDeploymentConfig( string configurationFile )
            string uri = string.Format( this.servicePropertiesOperationFormat, this.subscriptionID, this.serviceName, "production", "/?comp=config" );
            ServiceManagementOperation operation = new ServiceManagementOperation( this.thumbprint, this.versionID );
            string payloadString = string.Format(
                @"<?xml version=""1.0"" encoding=""utf-8""?>
                <ChangeConfiguration xmlns=""http://schemas.microsoft.com/windowsazure"">
                        <Configuration>{0}</Configuration>
                </ChangeConfiguration>", configurationFile );
            XDocument payload = XDocument.Parse( payloadString );
            return operation.Invoke( uri, payload );

    Hi,
    From my experience, if you add one role instance, the whole cloud service will run in translating state, and this cloud service will stop to working, so maybe this is a future request.
    Best Regards,
    Jambor
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

Maybe you are looking for