简体   繁体   中英

iisnode on windows 7 IIS 7.5 throwing 500.19 error

I have followed the steps mentioned on this github page. But even after doing everything as mentioned I am constantly getting an internal server error while trying to run the sample applications that is installed by the setupsamples.bat file which come with issnode package.

I have attached the screen shots and the related code file.

issnode主页似乎工作正常

你好世界崩溃

Here is the hello.js file

var http = require('http');

http.createServer(function (req, res) {
    res.writeHead(200, {'Content-Type': 'text/html'});
    res.end('Hello, world! [helloworld sample; iisnode version is ' +     process.env.IISNODE_VERSION + ', node version is ' + process.version + ']');
}).listen(process.env.PORT);  

And the web.config file

<configuration>
   <system.webServer>

    <!-- indicates that the hello.js file is a node.js application 
    to be handled by the iisnode module -->

    <handlers>
      <add name="iisnode" path="hello.js" verb="*" modules="iisnode" />
    </handlers>

  </system.webServer>
</configuration>

This is because you have a configuration at the server level that isn't overridable on the site level. Since you are adding a handler, I assume that it is the handler configuration that needs to be unlocked. You should be able to do that from the iis configuration program, or you can use the appcmd to unlock it.

You can read more about it here: http://www.iis.net/learn/get-started/planning-for-security/how-to-use-locking-in-iis-configuration

http://www.tomdupont.net/2012/10/how-to-unlock-configuration-section.html

Hope I'm not too late to the party. I had the same issue before. The most likely cause of this issue is that you did not install the IIS URL Rewriting Module. This module is not part of a standard IIS installation. You must install it explicitly from:

http://www.iis.net/downloads/microsoft/url-rewrite

just install the extension and you should be ok now

make sure handler mapping is read/write under feature delegation as bellow ScreanShot

在此输入图像描述

在此输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM