Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iisnode encountered an error when processing the request

I'm trying to check angularjs app with a server side written in node js and this is an error i get when i run in by webmatrix

iisnode encountered an error when processing the request.

HRESULT: 0x2 
HTTP status: 500 
HTTP reason: Internal Server Error 

You are receiving this HTTP 200 response because system.webServer/iisnode/@devErrorsEnabled configuration setting is 'true'.

In addition to the log of stdout and stderr of the node.exe process, consider using debugging and ETW traces to further diagnose the problem.

The node.exe process has not written any information to stderr or iisnode was unable to capture this information. Frequent reason is that the iisnode module is unable to create a log file to capture stdout and stderr output from node.exe. Please check that the identity of the IIS application pool running the node.js application has read and write access permissions to the directory on the server where the node.js application is located. Alternatively you can disable logging by setting system.webServer/iisnode/@loggingEnabled element of web.config to 'false'.

Does somebody know how to fix it?

like image 788
Tuvia Khusid Avatar asked Jun 04 '14 03:06

Tuvia Khusid


People also ask

What does IIs node error when processing the request mean?

What is “iisnode encountered an error when processing the request” error The IIS node error generally triggers while accessing a Node.js site. A typical error message includes an internal server error with the following format. This typically happens when the application pool doesn’t have enough permissions to write to the current folder.

What is the HTTP status of iisnode?

node.js - iisnode encountered an error when processing the request. HTTP status: 500 - Stack Overflow iisnode encountered an error when processing the request.

What is iisnode error HRESULT?

iisnode encountered an error when processing the request. HRESULT: 0x2 HTTP status: 500 HTTP subStatus: 1001 HTTP reason: Internal Server Error This is a fairly simple node/express application which we cannot get to run under iisnode.

Why can’t I run this application under iisnode?

This is a fairly simple node/express application which we cannot get to run under iisnode. We are seeing errors in the ETW trace such as: iisnode request processing failed for reasons unrecognized by iisnode iisnode was unable to establish named pipe connection to the node.exe process


2 Answers

Your application pool doesn't seem to have enough permissions to write to the current folder.

  1. You can either edit the permissions to give the IIS_IUSRS group write permissions to that folder

  2. Go into the advanced settings menu and under Process Model -> Identity change the user account to a user that already has write permissions.

like image 162
jdelibas Avatar answered Sep 25 '22 16:09

jdelibas


It looks like your iisnode cannot write its log file, perhaps because it does not have write permissions. If you have access to to the server then you can check inside the app's folder for an iisnode folder, that is where iisnode tries to write its logs by default.

Until you get this log info you are stuck because the 500 error you are seeing only tells you that the error has occurred on the server somewhere. You need the logs to give you the info you need to proceed.

The only other alternative is to run the whole thing locally and use something like node-inspector (I use grunt-node-inspector) to debug into the nodeJS code to see what is happening.

like image 25
biofractal Avatar answered Sep 23 '22 16:09

biofractal