开发者

Azure - error on starting with multiple web role projects

开发者 https://www.devze.com 2023-02-01 03:33 出处:网络
If I have more than one webroles(projects, not instances) in my application, I get this error: (I only get it if I attach a web role. It works fine wit as many worker roles projects as I want)

If I have more than one webroles(projects, not instances) in my application, I get this error: (I only get it if I attach a web role. It works fine wit as many worker roles projects as I want)

Microsoft Visual Studio

Windows Azure Tools for Microsoft Visual Studio

There was an error att开发者_开发技巧aching the debugger to the IIS worker process for URL 'http://127.0.0.1:5100/' for role instance 'deployment(21).CloudPOC.WebRoleToHostDataService.0'. Unable to start debugging on the web server. The web server is not configured correctly. See help for common configuration errors. Running the web page outside of the debugger may provide further information.

Click Help for more information.

OK

What is wrong here? I can't understand it and I need a webservice project!


Make sure you are starting the Azure project rather than the Web Project itself. You might have set the Web Role as the startup project, and if you do that you'll find that IIS runs the Web App rather than the Azure Dev Fabric, meaning any Dev Fabric specific stuff (like config settings per role) aren't available causing problems.

What you're meant to do is let the Azure Dev Fabric (Compute Simulator) fire up all your roles for you, and it'll also work out if it needs to open a web browser etc.

So right click on the Azure Cloud project, set that as the Startup Project, and try again.

Hope that helps, Andy

EDIT thought of something else!

Make sure your web.config is compiling to allow debug="true". If you have added a new WebSite to your solution, it won't be so by default:

<system.web> <compilation debug="true" targetFramework="4.0" />


I had similar issue which got resolved with following steps.

  1. Make sure you have correct version of .net framework 4.0 is intalled. (.Net Framework 4.0.30319 is the latest version)

  2. Uninstall if there isany other .Net 4.0 framework in present on your system by going to Add And Remove programs.

  3. Go to %windir%\Microsoft.NET\Framework64 physical location and remove unwanted .Net framework 4.0 folder


I've also had this problem and it happened when I upgraded my app to 4.0... I ran without debugging and got the following error:

There is a duplicate 'system.web.extensions/scripting/scriptResourceHandler' section defined

and after researching that error, I found this: http://forums.asp.net/t/1571308.aspx/1

which says there's currently a bug w/ vs2010 and 4.0... I took the answers recommendation and commented out the extensions section and it worked for me... Another possible solution.

0

精彩评论

暂无评论...
验证码 换一张
取 消