404 error with IIS 7.0

iis, iis-7

Solution

Have you checked the following:

- Your DNS 'A' record for 'files' is pointing to the correct IP address

- If your server is using a shared IP address across multiple sites have you configured a HTTP host header?

- Is there a mime type set for the `.txt` extension?

- Have you made any changes to the Handler Mappings for the site? e.g. mapped the `.htm` extension to say the ASP ISAPI filter and accidentally removed the StaticFile handler?

- Can you serve other static content such as `.jpg`, `.gif`, `.pdf` etc?

Problem

I have a text file that I am trying to browse to using the browser `http://files.mydomain.com/test.txt` and I get a: ``` HTTP Error 404.0 - Not found ``` I double checked and the text file does exist. When I add a `test.htm` file, I have no issues. Can someone help? Something tells me it's security issue.

Original source