iisnode error 500 when running as an application of an existing asp.net site

2

I am trying to run the samples of iisnode as an application in an existing ASP.Net MVC web site and I'm encountering problems.

IIS is version 7.5 on Windows 2008 R2

The samples are located in \program files\iisnode\www\

I have set up two ways to access the iisnode samples :

  • as a separate web site on port 82, pointing to \program files\iisnode\www\ . When I navigate to http://localhost:82/helloworld/hello.js , this works fine and, in return, I get

Hello, world! [helloworld sample; iisnode version is 0.2.7, node version is v0.8.22]

  • as a "node" application pointing to the same \program files\iisnode\www\ in my Asp.net Web Forms + MVC website when I navigate to http://localhost/node/helloworld/hello.js , I get a HTTP 500 error :

    • Module iisnode
    • Notification ExecuteRequestHandler
    • Handler iisnode
    • Error Code 0x8007000d

One amazing thing is that http://localhost/node/helloworld/hello.js won't work until I navigate to http://localhost:82/helloworld/hello.js. Then http://localhost/node/helloworld/hello.js will start to work ! ... If I do a iisreset then it won't work anymore... (until I navigate to http://localhost:82/...).

I must add that, for testing purpose, web site and application share the same Application Pool, which runs as Local System, Enable32BitApplication = false, .Net Framework 4.0, integrated.

The web site was added for testing purpose after unsuccesful attempts with the application. So I don't think the problem comes from a conflict. Both use anonymous authentication, no impersonation.

With trace activated, I can grasp the following error message

iisnode failed to initialize a new node.exe process

Seems like the website is able to activate the node.exe process, where the application can not. And that, once activated by the web site, the node.exe process is available for the application in the shared application pool.

Can someone point me in the right direction so that I will be able to use iisnode as an application in my existing website ?

asp.net
node.js
iis-7.5
iisnode
asked on Stack Overflow Sep 11, 2013 by jbl

1 Answer

3

In case this might help someone, I finally found out that the problem was in the way I referenced my external appSettings file in my root ASP.NET web.config.

The external appSettings.config file was referenced this way :

  <appSettings configSource=".\conf\appSettings.config" />

Until now, it was working well, and I never encountered problems with ASP.NET sub applications.

My iisnode sub application ceased producing HTTP 500 errors as soon as I removed the leading .\ in the configSource path :

  <appSettings configSource="conf\appSettings.config" />
answered on Stack Overflow Sep 13, 2013 by jbl

User contributions licensed under CC BY-SA 3.0