Configure IIS on Windows Server 2019 in D Drive

Arunpandian 0 Reputation points
2023-08-31T14:28:52.4733333+00:00

Hello All, I want to configure IIS on windows server 2019 in D Drive. But I got some information like in default we have to configure on C Drive then we can move on D Drive. Can some help me on this steps? And if we configure IIS in D Drive then if we want to restart IIS or Application Pool via external tool like Octopus then what type of aceess do I have to create?

Windows development | Internet Information Services
Windows for business | Windows Server | User experience | Other
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Lex Li 6,037 Reputation points
    2023-08-31T18:47:20.66+00:00

    IIS is part of the operating system, so try not to move any of its installed files out of system drive. you can, however, put web contents on another drive and then map to web sites on IIS.

    2 people found this answer helpful.
    0 comments No comments

  2. Yurong Dai-MSFT 2,846 Reputation points Microsoft External Staff
    2023-09-01T03:15:27.3166667+00:00

    Hi @Arunpandian,
    IIS is part of the operating system and must be located on the system drive. You cannot choose to install IIS on a specific drive, but you can choose where to place your site files. When you configure your site in IIS, you are free to place these files anywhere in the file system.

    Microsoft have made the following explanation in official documents:

    During installation, most of the core IIS components and configuration files are placed inside the %windir%\system32\inetsrv folder. The Inetsrv directory is considered the main installation directory for IIS. It has been reported that some non-Microsoft security scanning tools suggest that IIS should be installed on a non-system drive for security purposes. This is not a correct assessment. IIS is a core Windows component and cannot be installed on a non-system drive.

    There have also been reports of suggestions to move the Inetpub directory to a non-system drive for security purposes. The Inetpub directory is the default web content directory and also acts as a placeholder for logs and temporary files. Most of the Inetpub subfolder locations can be reconfigured based on your needs and business requirements, however the initial Inetpub folder and subfolders should never be renamed nor deleted. This is because Windows Servicing may at some point need to update one or more of the core IIS files that are stored in %systemdrive%\inetpub. Moving the Inetpub folder structure completely off of the system drive is not supported. Further, there are no real security benefits from moving the entire Inetpub directory structure to a non-system drive.

    NOTE: IN THE EVENT OF WINDOWS SERVICING, ONLY THE ORIGINAL DIRECTORIES AND THEIR CONTENTS WILL BE UPDATED. MICROSOFT DOES NOT RECOMMEND ANY MANIPULATION TO THE IIS DIRECTORY STRUCTURE. DOING SO WILL RENDER IIS IN AN UNSUPPORTED STATE.

    You can see the above in this Microsoft Knowledge Base archive: Guidance for relocation of IIS 7.0 and IIS 7.5 content directories

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.