|
Who Are We?Fluent Consulting is a software development and consulting firm that specializes in enterprise application integration, web applications, and software product development. We are a dedicated team focused on providing the highest level of quality and value for our clients. Please feel free to visit our corporate site or get in touch! |
IIS Nested Virtual Directory Problems
Microsoft Internet Information Server (IIS) 5.1 has an undocumented bug we recently came across. The bug involves nested virtual directories in IIS. We encountered the bug on a development machine running Windows XP Professional (with IIS 5.1), but it may also exist on servers running IIS 6.0. The fix is easy, once you know what is going on.
The quick fix is to not include a period (.) in the name of a nested virtual directory. For some reason a period prevents nested virtual directories from loading properly. With a period in the name, the nested virtual directory is instead treated as just a directory by IIS. Your files are available, but they tie back to the parent bin rather than the nested bin.
Our specific problem occurred on a development machine running Windows XP Professional with IIS 5.1. On a desktop installation, IIS only allows you to have 1 default web site. This is generally not a problem for developers, you simply use virtual directories and you can access all your development sites. You would then use a nested virtual directory for what would be a virtual directory on your server. Usually, this is not a problem. Nested virtual directories have worked without incident for most people since the release of IIS.
The problem showed up when we were branching a project and named the parent virtual directory 'project.v2'. Beneath project.v2 was another virtual directory that was a sub-project. The sub-project stopped working. When it loaded it would try to read in the parent Web.config and parent dll's and fail. This initially led us to believe there was a problem with the sub-project. After trying to reconfigure the sub-project for the better part of a day, we renamed the parent directory and everything started working. We were able to confirm this bug on all our sites by creating projects with a period in the IIS virtual directory name.
Other characters may cause this behavior too, but we haven't tried them all. We have tried underscore (_) and dash (-) and they both work without problems.
If you do run across this problem and you are at a loss, you may want to rename your directory with alphanumerics only and see if that does fix the problem.



