Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Default Documents sending 404 error even when configured in IIS

Posted on 2004-04-21
9
Medium Priority
?
537 Views
Last Modified: 2008-03-06
I have recently built a web server running IIS 5.0 on Windows 2000, but am having trouble getting the default documents (index.htm, default.asp, index.cfm, etc.) to be returned to the client's browser unless they're explicitly declared in the URL (http://www.foo.com/bar returns a 404 error while http://www.foo.com/bar/index.cfm works).  Each of these documents is listed in the "Documents" tab in the web site's properties settings under the heading "Enable Default Document" , and this option has been selected.  What other setting(s) should I check or modify to correct this problem?  
0
Comment
Question by:shooksm
  • 5
  • 4
9 Comments
 
LVL 5

Expert Comment

by:chaniewskim
ID: 10880809
It is possible to have specified default document for a website, but cleared for its subdirectory. In your case: you have default document 'index.cfm' listed in website properties, but not in /bar directory properties. Check it.

Also, check casing of filenames in website properties and on your file. This shouldn't be a case, because IIS ignores case, but better check than sorry.
0
 
LVL 9

Author Comment

by:shooksm
ID: 10881448
Good suggestion.  Checked out the offending sub folders and they are set with the same default documents.  Any other ideas?
0
 
LVL 5

Expert Comment

by:chaniewskim
ID: 10881618
No idea. Is that 404 or 403?
0
NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

 
LVL 9

Author Comment

by:shooksm
ID: 10881693
404, which is strange as directory browsing is disabled so you would think you would get a 403 error if it could not find a default doc.
0
 
LVL 5

Expert Comment

by:chaniewskim
ID: 10881710
Is that problem only with index.cfm or with index.htm is the same?
0
 
LVL 9

Author Comment

by:shooksm
ID: 10881862
Wow, just tried index.htm, index.asp, index.cfm, default.htm, default.asp and default.cfm and none of them worked even though they are all set as default documents.  Is there any way to determine what file IIS is saying doesn't exist?
0
 
LVL 5

Accepted Solution

by:
chaniewskim earned 2000 total points
ID: 10881889
Try to look into logs

C:\WINDOWS\system32\LogFiles\W3SVC1\exyymmdd.log
0
 
LVL 5

Expert Comment

by:chaniewskim
ID: 10881943
OK, check also:

- if your wwwroot or bar directory does not have 'hidden' attribute set
- extended status code, if it is shown:
404.0 - (None) – File or directory not found.
404.1 - Web site not accessible on the requested port.
404.2 - Web service extension lockdown policy prevents this request.
404.3 - MIME map policy prevents this request.

If nothing of this give you any additional hints, then check if default document works for root URL (http://www.foo.com/)

And, tell mi what is your /bar folder. Where is it placed - in wwwroot? Is it virtual directory?
There are sometimes problems when you have a physical folder in wwwroot and also virtual directory of the same name created in IIS. Check if it is the case here.
0
 
LVL 9

Author Comment

by:shooksm
ID: 10887977
Sure enough.  Checked the log file and found a URLScan program we have that filters out known exploits was causing it to redirect requests from "http://www.foo.com/bar" to "http://www.foo.com/bar/." thus causing the 404 error.  Disabling the URLScan app allows us to use the default documents again, now we just need to play around with the URLScan rules and figure out.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Logparser is the smartest tool I have ever used in parsing IIS log files and there are many interesting things I wanted to share with everyone one of the  real-world  scenario from my current project. Let's get started with  scenario - How do w…
If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question