views:

2206

answers:

3

In IIS 6, I am trying to deploy a Web Site project from Visual Studio 2008. This site has a sub-folder with some aspx pages in it. When I deploy the project to the server and navigate to the site, everything works except for the pages that exist in the sub-folder, they throw a 404 error.

In IIS, I can navigate the sub-folders and see the pages there, but when I right click on one of the files and select "Browse", that too throws a 404.

FYI... when I publish the site from VS, I check the box that says "Allow this precompiled site to be updatable". I've tried unchecking the box but it gives me the same result.

Also, running locally or in debug mode does not produce this result, I can navigate to the pages in sub-folders just fine.

Edit: A look deeper and it is giving me a 404.2 (404 2 1260) error in IIS Logs which means Lockdown policy prevents this request. Any ideas what this means and how I can resolve it?

A: 

Check to see if the pages in the subfolder are referencing a page or user control that you may have forgotten to deploy with the rest of the site content.

Kon
+4  A: 

If it's a file extension that IIS doesn't know the mime type for, that can cause 404's.

Try looking in the IIS logs (web site properties->enable logging->browse) for the errors. IIS should call them 404.1 or 404.2 or something like that which will give you more information about what the specific error is.

edit: This is waay late, but that error makes me wonder if you need to go into IIS management->Web Service Extensions (the folder under Web Sites) and Allow ASP.NET. This defaults to Disabled in Win2003.

David
the page is an .aspx page and the error that is being returned is a 404.2 error.
Chris Conway
A: 

Try this: Open the IIS Manager on the server, right-click on the site folder (not the subfolder), and click "Properties". On the "Virtual Directory" tab, in the "Application Settings" look for the "Create" button. If it's there, make sure the permissions settings is set to "Scripts Only", then click the "Create" button. If button says "Remove", try changing the permissions to "Scripts and Executables". If it doesn't work, you can always change it back.