« Previous Next »

Thread: IIS Bug? Virtual directory cannot point to a drive's root. (use NTFS symbolic link instead)

Last post 07-27-2009 3:20 PM by SLORider. 2 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (3 items)

Sort Posts:

  • 07-26-2009, 7:41 PM

    • SLORider
    • Top 500 Contributor
    • Joined on 11-25-2006, 10:11 PM
    • San Luis Obispo, CA USA
    • Posts 16

    IIS Bug? Virtual directory cannot point to a drive's root. (use NTFS symbolic link instead)

    Problem:

    I discovered this using WebDAV, but it is not WebDAV specific (see also: Virtual Directory error at root only)

    When a virtual directory is pointed to the root of any drive, no contents are served. The drive appears completely empty and a 404 error is returned.

    Example:

    http://example.com/files (where 'files' is a virtual directory pointed to F:\)

    If you happen to know the name of a directory within F: and type it manually, the sub-directory folders do appear:

    http://example.com/files/foo (contents of 'foo' are properly published to client)

     

    Rationale:

    The reason I am doing this is for server file access/maintenence. I created a WebDAV site on my server (2K8) in place of enabling WebDAV for each web site. Next, I created a virtual directory that 'loops back' to the root of the same drive which contains all the web folders. Thus, using one WebDAV log-in I can access all web sites (and other content) on my server.

    I'd like to know if there is a way to access a drive's root via virtual directories.

    Work Around (NTFS symbolic links)

    A work around that seems just as good as a virtual directory is an NTFS symbolic link created in the WebDAV site's root folder:

    W:/webdav-root/> mklink /D W W:\

    Junctions work also:

    W:/webdav-root/> mklink /J W W:\


    Visit SLORider.com!
  • 07-27-2009, 11:30 AM In reply to

    Re: IIS Bug? Virtual directory cannot point to a drive's root. (use NTFS symbolic link instead)

     What NTFS permissions are on the root folder?

    Jeff

    Look for Wrox's new book Professional IIS 7 in your local bookstore, or order now at Amazon.com
  • 07-27-2009, 3:20 PM In reply to

    • SLORider
    • Top 500 Contributor
    • Joined on 11-25-2006, 10:11 PM
    • San Luis Obispo, CA USA
    • Posts 16

    Re: IIS Bug? Virtual directory cannot point to a drive's root. (use NTFS symbolic link instead)

    Everyone: Traverse/Execute/List/Read (root folder only)

    CREATOR OWNER:Full Control (subfolders and files only)

    SYSTEM: Full Control (this folder, subfolders and files)

    WebDAV Authors: Modify (this folder, subfolder and files)

    Administrators: Full Control (this folder, subfolder and files)

    Users: Traverse/Execute/List/Read (this folder, subfolder and files)

    Users: Create folder (this folder and subfolders)

    Users: Create files/append (subfolders)

    IIS_IUSRS: Traverse/Execute/List/Read (this folder, subfolder and files)

    -------------

    WebDAV users are part of the WebDAV Authors group and log on using Windows Authentication. I have tried both pass-through authentication and specific user authentication with no luck.

     

    In general, using Failed Request Tracing, I will generate either an authorization error, or file not found error:

     

    ModuleNameDirectoryListingModule
    Notification128
    HttpStatus404
    HttpReasonNot Found
    HttpSubStatus0
    ErrorCode2147942402
    ConfigExceptionInfo
    Notification EXECUTE_REQUEST_HANDLER
    ErrorCode The system cannot find the file specified. (0x80070002)

     

     

     

     

    Visit SLORider.com!
Page 1 of 1 (3 items)
Microsoft Communities