First of all, I apologize if this is a basic question. I am a Linux sysadmin and just so happen to be dealing with Windows at the moment. Feel free to edit the question or add tags where appropriate.
The premise: I am migrating a website from IIS 6.0 on Windows Server 2003 to IIS 8.5 on Windows Server 2016.
IIS 8.5 was originally installed in the default location and the website worked fine when located under C:\inetpub\wwwroot
on the new server.
However, due to organizational policy, the website needs to be located on the E:\
drive of the new server, rather than on the C:\
drive.
First, I tried simply moving the site from C:\inetpub\wwwroot
to E:\inetpub\wwwroot
and updating references to the site in IIS, but the site would not come up.
(I do not remember the exact error message I got here. If it would be helpful, I can reconstruct this environment and replicate the error.)
After that, I reached out to a colleague and he pointed me to a script that he uses when installing websites on nonstandard drives on Windows Server 2012. Here is a summary of what the script does:
- Stop IIS
- Copy
C:\inetpub
toE:\inetpub
(or whichever drive is specified) while retaining file ownership and ACL information - Using
appcmd set config
, specify directory paths for the following:- Logs
- Configuration history
- Temporary files
- Default site
- Error pages
- Modify the following registry components:
HKLM\System\CurrentControlSet\Services\WAS\Parameters\ConfigIsolationPath
HKLM\Software\Microsoft\inetstp\PathWWWRoot
HKLM\Software\Microsoft\inetstp\PathFTPRoot
HKLM\Software\Wow6432Node\Microsoft\inetstp\PathWWWRoot
HKLM\Software\Wow6432Node\Microsoft\inetstp\PathFTPRoot
- Start IIS
I ran that script, but ended up seeing the following error after iisreset /start
:
Attempting start... Start attempt failed. The IIS Admin Service or the World Wide Web Publishing Service, or a service dependent on them failed to start. The service, or dependent services, may had an error during its startup or may be disabled.
I cannot find the IIS Admin Service under the Windows Services menu, and when I try to start the World Wide Web Publishing Service, I get the following error message:
Windows could not start the World Wide Web Publishing Service service on Local Computer.
Error 1068: The dependency service or group failed to start.
My next thought was that maybe logging out of and back into Windows would help, since the registry changes might not take effect until doing so. However, doing that didn't help.
Is there something else that I need to do in addition to what the script performed, given that the script was for Windows Server 2012 / IIS 8, and my current environment is Windows Server 2016 / IIS 8.5?