Calling IIS7 Admins!
Author
Discussion

judas

Original Poster:

6,206 posts

281 months

Monday 1st March 2010
quotequote all
Having a real problem making some configuration changes to our IIS7 server.

I'm trying to get the server to send ASP script error messages to remote browsers. I've done all the obvious stuff: set the 'Send Errors to Browser' setting to 'True' in the Debugging section of the ASP features. Errors will now show on localhost sessions, but I need it to work for remote connections too. After extensive Googling I found the setting that needs changing in the IIS_schema.xml file and an appcmd to change it

system.web httpErrors -errorMode:DetailLocalOnly  - needs changing to -erromode:Detailed

%windir%\system32\inetsrv\appcmd.exe set config -section:system.webServer/httpErrors -errorMode:Detailed


When this script is run at the command prompt with Adminstrator privileges it returns the following message:
stupid script said:
Applied configuration changes to section "system.webServer/httpErrors" for "MACHINE/WEBROOT/APPHOST" at configuration commit path "MACHINE/WEBROOT/APPHOST"
The problem is the change doesn't appear to take. The section of the IIS_schema.xml file is still saying 'DetailedLocalOnly' and there appears to be no way to edit the XML file directly even with Administrator privileges (yes, yes - I know that's the whole idea tongue out).

I really need to get remote script error messages working!

Any help gratefully received smile

Zeek

882 posts

226 months

Monday 1st March 2010
quotequote all
Restarted the IIS service after making the config change?

mackie1

8,168 posts

255 months

Monday 1st March 2010
quotequote all
Classic ASP or ASP.Net?

judas

Original Poster:

6,206 posts

281 months

Monday 1st March 2010
quotequote all
Classic ASP in this case. Tried restarting IIS after changes; stopping IIS, making the change and restarting...

Weird thing was that remote error reporting was working on other sites. Think I may have found a problem in the web.config files that could be the cause.

Zeek

882 posts

226 months

Monday 1st March 2010
quotequote all
Just make sure you have turned off 'friendly' http error messages in the browser (If you're using IE)...

judas

Original Poster:

6,206 posts

281 months

Monday 1st March 2010
quotequote all
Yup - it was a dodgy setting in the web.config.

Thanks folks smile