0

I downloaded the latest iisnode from https://github.com/Azure/iisnode/releases (0.2.26 full)

I downloaded url rewrite module 2.1 from https://download.microsoft.com/download/1/2/8/128E2E22-C1B9-44A4-BE2A-5859ED1D4592/rewrite_amd64_en-US.msi

Installed both

Then I ran %programfiles%\iisnode\setupsamples.bat with adminitrative rights

Restarted my machine (just in case)

I went to http://localhost/node/

I get the following error on every link:

Error Code     0x80070021

Config Error       This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault="Deny"), or set explicitly by a location tag with overrideMode="Deny" or the legacy allowOverride="false".

Config File    \\?\C:\Program Files\iisnode\www\helloworld\web.config


Config Source:

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

I guess it's not accepting iisnode as a valid handler

Any idea?

2
  • is your issue resolved? Oct 15, 2019 at 9:04
  • 1
    Excelent, both methods worked like a charm, thanks a lot (sorry for the delay in answering)
    – opensas
    Oct 15, 2019 at 9:14

1 Answer 1

3

Browse to "C:\Windows\System32\inetsrv\config" and open notepad as administrator and open applicationHost.config file.

Find the section that showed up in the “config source” part of the error message page (typically “modules” or “handlers”).

Change the overrideModeDefault attribute to be “Allow”. The whole line now looks like:

<section name="modules" allowDefinition="MachineToApplication" overrideModeDefault="Allow" />"

OR

You could also try below setting:

  • open iis manager, select node.

enter image description here

  • from select section dropdown select "system.webserver/handlers" from action pane select unlock.

enter image description here

after doing changes restart the iis.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.