IIS7 won"t run or uninstall
IIS7 won"t run or uninstall
am 08.04.2008 07:45:00 von jrl
I have encountered some kind of corruption, such that an IIS7 site will not
start.
When I try to start the site, IIS responds:
There was an error performing this operation.
Details: Filename \\?\C:\Windows\inetsrv\config\applicationHost.config
Line number: 860
Error: Configuration file is not well-formed XML
Then I tried to uninstall IIS, hoping that I could reinstall it to repair
this file. In spite of my repeated attempts to uninstall it (through Turn
Windows features on or off) it won't uninstall. It says it will uninstall,
processes the changes, and then restarts, but after restart I see that IIS
is still installed, and the web site still won't start.
How can I get out of this loop? I'd like to know how to get it to uninstall,
so that it will rebuild this corrupted file.
RE: IIS7 won"t run or uninstall
am 08.04.2008 10:41:30 von wjzhang
Hi,
The issue should be caused by there is some corrupt data in
C:\Windows\System32\inetsrv\config\applicationHost.config which makes the
configuration XML file no longer well-formed and IIS cannot parse it.
Please check if there is a previous backup under:
C:\Windows\System32\inetsrv\backup\* . If there is, stop IIS services and
copy the backup applicationHost.config and overwrite current corrupt one in
\inetsrv\config .
If there isn't any available backup file, please stop IIS services first
and try uninstalling it again. Regardless if the uninstallation succeeds,
please manually delete the \inetsrv directory under C:\Windows\System32 .
Then please reboot the server to perform a clear reinstallation of IIS. If
the reinstallation succeeds, you can use the following command to create a
fresh backup of IS configurations:
Open a DOS prompt:
C:\Windows\System32>cd inetsrv
C:\Windows\System32\inetsrv>appcmd add backup cleaninstall
Please let me know if problem still persists.
Have a nice day.
Sincerely,
WenJun Zhang
Microsoft Online Community Support
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
msdnmg@microsoft.com.
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/de fault.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx .
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Re: IIS7 won"t run or uninstall
am 08.04.2008 18:12:03 von jrl
In my case there was no backup folder at C:\Windows\System32\inetsrv .
You said "please stop IIS services first and try uninstalling it again." I
could only stop iis admin service and web service (so I hope these are the
services you wanted me to stop).
After requesting it to turn the internet information services off, it
responded "An error occrurred. Not all of the features were successfully
changed."
After a restart, I confirmed that Internet services were still installed and
that the web site still would not run because of the configuration file not
being well-formed.
Then I tried to delete C:\Windows\System32\inetsrv but it would not allow
me, even though I am an administrator, and I used elevated privileges with
UAC. Basically I just click on 'try again' repeatedly, and it never deletes
the directory. I was able to individually delete applicationHost.config
After this I tried to turn the Internet Information Services off again. It
says it is configuring. I confirmed that IIS was removed from the list of
installed windows features. So that was progress. Then I tried to delete
C:\Windows\System32\inetsrv but it still would not allow me (even with
elevated priveleges).
After restarting, then I turned on the IIS features again, to see if it
would reinstall properly. It responded "An error occurred. Not all of the
features were successfully changed." I restarted, and then found that IIS
was not running (and also the iis admin service and web service were not
running). In "turn windows features on or off" IIS was off. I turned it on
again (with default settings) , but received the same error responded "An
error occurred. Not all of the features were successfully changed."
What should I do now?
""WenJun Zhang[msft]"" wrote in message
news:U1G2hRVmIHA.9016@TK2MSFTNGHUB02.phx.gbl...
> Hi,
>
> The issue should be caused by there is some corrupt data in
> C:\Windows\System32\inetsrv\config\applicationHost.config which makes the
> configuration XML file no longer well-formed and IIS cannot parse it.
>
> Please check if there is a previous backup under:
> C:\Windows\System32\inetsrv\backup\* . If there is, stop IIS services and
> copy the backup applicationHost.config and overwrite current corrupt one
> in
> \inetsrv\config .
>
> If there isn't any available backup file, please stop IIS services first
> and try uninstalling it again. Regardless if the uninstallation succeeds,
> please manually delete the \inetsrv directory under C:\Windows\System32 .
> Then please reboot the server to perform a clear reinstallation of IIS. If
> the reinstallation succeeds, you can use the following command to create a
> fresh backup of IS configurations:
>
> Open a DOS prompt:
>
> C:\Windows\System32>cd inetsrv
>
> C:\Windows\System32\inetsrv>appcmd add backup cleaninstall
>
> Please let me know if problem still persists.
>
> Have a nice day.
>
> Sincerely,
>
> WenJun Zhang
>
> Microsoft Online Community Support
>
> Delighting our customers is our #1 priority. We welcome your comments and
> suggestions about how we can improve the support we provide to you. Please
> feel free to let my manager know what you think of the level of service
> provided. You can send feedback directly to my manager at:
> msdnmg@microsoft.com.
>
> ==================================================
> Get notification to my posts through email? Please refer to
> http://msdn.microsoft.com/subscriptions/managednewsgroups/de fault.aspx#notif
> ications.
>
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> http://msdn.microsoft.com/subscriptions/support/default.aspx .
> ==================================================
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>
Re: IIS7 won"t run or uninstall
am 09.04.2008 04:56:10 von David Wang
On Apr 8, 9:12=A0am, "jrl" wrote:
> In my case there was no backup folder at C:\Windows\System32\inetsrv .
> You said "please stop IIS services first and try uninstalling it again." I=
> could only stop iis admin service and web service (so I hope these are the=
> services you wanted me to stop).
> After requesting it to turn the internet information services off, it
> responded "An error occrurred. Not all of the features were successfully
> changed."
> After a restart, I confirmed that Internet services were still installed a=
nd
> that the web site still would not run because of the configuration file no=
t
> being well-formed.
> Then I tried to delete C:\Windows\System32\inetsrv but it would not allow
> me, even though I am an administrator, and I used elevated privileges with=
> UAC. Basically I just click on 'try again' repeatedly, and it never delete=
s
> the directory. I was able to individually delete applicationHost.config
> After this I tried to turn the Internet Information Services off again. It=
> says it is configuring. I confirmed that IIS was removed from the list of
> installed windows features. So that was progress. Then I tried to delete
> C:\Windows\System32\inetsrv but it still would not allow me (even with
> elevated priveleges).
> After restarting, then I turned on the IIS features again, to see if it
> would reinstall properly. It responded "An error occurred. Not all of the
> features were successfully changed." I restarted, and then found that IIS
> was not running (and also the iis admin service and web service were not
> running). In "turn windows features on or off" IIS was off. I turned it on=
> again (with default settings) , but received the same error responded "An
> error occurred. Not all of the features were successfully changed."
> What should I do now?
>
> ""WenJun Zhang[msft]"" wrote in message
>
> news:U1G2hRVmIHA.9016@TK2MSFTNGHUB02.phx.gbl...
>
>
>
> > Hi,
>
> > The issue should be caused by there is some corrupt data in
> > C:\Windows\System32\inetsrv\config\applicationHost.config which makes th=
e
> > configuration XML file no longer well-formed and IIS cannot parse it.
>
> > Please check if there is a previous backup under:
> > C:\Windows\System32\inetsrv\backup\* . If there is, stop IIS services an=
d
> > copy the backup applicationHost.config and overwrite current corrupt one=
> > in
> > \inetsrv\config .
>
> > If there isn't any available backup file, please stop IIS services first=
> > and try uninstalling it again. Regardless if the uninstallation succeeds=
,
> > please manually delete the \inetsrv directory under C:\Windows\System32 =
..
> > Then please reboot the server to perform a clear reinstallation of IIS. =
If
> > the reinstallation succeeds, you can use the following command to create=
a
> > fresh backup of IS configurations:
>
> > Open a DOS prompt:
>
> > C:\Windows\System32>cd inetsrv
>
> > C:\Windows\System32\inetsrv>appcmd add backup cleaninstall
>
> > Please let me know if problem still persists.
>
> > Have a nice day.
>
> > Sincerely,
>
> > WenJun Zhang
>
> > Microsoft Online Community Support
>
> > Delighting our customers is our #1 priority. We welcome your comments an=
d
> > suggestions about how we can improve the support we provide to you. Plea=
se
> > feel free to let my manager know what you think of the level of service
> > provided. You can send feedback directly to my manager at:
> > msd...@microsoft.com.
>
> > ==================== =====
==================== =====3D=
=3D
> > Get notification to my posts through email? Please refer to
> >http://msdn.microsoft.com/subscriptions/managednewsgroups/d efault.asp...
> > ications.
>
> > Note: The MSDN Managed Newsgroup support offering is for non-urgent issu=
es
> > where an initial response from the community or a Microsoft Support
> > Engineer within 1 business day is acceptable. Please note that each foll=
ow
> > up response may take approximately 2 business days as the support
> > professional working with you may need further investigation to reach th=
e
> > most efficient resolution. The offering is not appropriate for situation=
s
> > that require urgent, real-time or phone-based interactions or complex
> > project analysis and dump analysis issues. Issues of this nature are bes=
t
> > handled working with a dedicated Microsoft Support Engineer by contactin=
g
> > Microsoft Customer Support Services (CSS) at
> >http://msdn.microsoft.com/subscriptions/support/default.asp x.
> > ==================== =====
==================== =====3D=
=3D
> > This posting is provided "AS IS" with no warranties, and confers no
> > rights.- Hide quoted text -
>
> - Show quoted text -
I suggest reinstall the OS. This is why.
Your original error was easy to overcime -- there was invalid XML in
applicationHost.config on line 860 that can be fixed without
uninstalling. If you provided that file, someone can tell you what's
wrong and possibly fix the corruption.
Reinstallation will not fix file corruption in the .config file
because IIS reinstallation will try to open the .config file... which
will encounter the same XML well-formedness error when it goes to add/
remove features as part of reinstallation. Thus, it will fail, which
is exactly what you observed.
The correct resolution was to fix the invalid XML file to get yourself
out of the jam.
What you were hoping for, that reinstalling IIS will rebuild the
corrupted file, is impossible to accomplish. We've thought about this
problem a lot, but the flexibility of IIS7 configuration prevents such
restoration behavior. Why? Well, the file content depends on the
features that the user chose to install, so there is no single
"default/correct configuration file". Plus, the file contents have to
be edited as XML and not plain text because users do not expect every
feature addition/removal to revert any existing settings to some
default state while adding/removing the new feature. Thus, rebuilding
the .config file is not possible.
Unfortunately, you went down the path of attempting to manually delete
the inetsrv folder and causing mismatched state between what Windows
thinks is installed and the actual files that are installed.
All IIS files are considered part of the OS and thus under Windows
File Protection, which will prevent you from ever removing the inetsrv
directory as soon as IIS has ever been installed on the OS. It doesn't
matter what user account -- there is a file handle open against that
directory, so you won't be able to delete the directory. And you won't
be able to kill the process that has the file handle since your
machine will BSOD and reboot when you kill that process.
Basically, what you are trying to do is confusing Windows further, and
Vista is designed to babysit the user and will fight against you. It's
not Windows 2000 or XP which will just roll over and let you do
whatever you want.
Unfortunately, you have confused Windows Features, and it is really
unsupported to walk anyone through manually running commands to unwind
all the damage. I believe OS reinstallation is the best supported
solution here.
//David
http://w3-4u.blogspot.com
http://blogs.msdn.com/David.Wang
//
Re: IIS7 won"t run or uninstall
am 09.04.2008 08:55:53 von jrl
Thank you. Reinstalling Vista was effective.
"David Wang" wrote in message
news:ad778926-fa5d-4294-8ba0-c22a24bd889b@n1g2000prb.googleg roups.com...
On Apr 8, 9:12 am, "jrl" wrote:
> In my case there was no backup folder at C:\Windows\System32\inetsrv .
> You said "please stop IIS services first and try uninstalling it again." I
> could only stop iis admin service and web service (so I hope these are the
> services you wanted me to stop).
> After requesting it to turn the internet information services off, it
> responded "An error occrurred. Not all of the features were successfully
> changed."
> After a restart, I confirmed that Internet services were still installed
> and
> that the web site still would not run because of the configuration file
> not
> being well-formed.
> Then I tried to delete C:\Windows\System32\inetsrv but it would not allow
> me, even though I am an administrator, and I used elevated privileges with
> UAC. Basically I just click on 'try again' repeatedly, and it never
> deletes
> the directory. I was able to individually delete applicationHost.config
> After this I tried to turn the Internet Information Services off again. It
> says it is configuring. I confirmed that IIS was removed from the list of
> installed windows features. So that was progress. Then I tried to delete
> C:\Windows\System32\inetsrv but it still would not allow me (even with
> elevated priveleges).
> After restarting, then I turned on the IIS features again, to see if it
> would reinstall properly. It responded "An error occurred. Not all of the
> features were successfully changed." I restarted, and then found that IIS
> was not running (and also the iis admin service and web service were not
> running). In "turn windows features on or off" IIS was off. I turned it on
> again (with default settings) , but received the same error responded "An
> error occurred. Not all of the features were successfully changed."
> What should I do now?
>
> ""WenJun Zhang[msft]"" wrote in message
>
> news:U1G2hRVmIHA.9016@TK2MSFTNGHUB02.phx.gbl...
>
>
>
> > Hi,
>
> > The issue should be caused by there is some corrupt data in
> > C:\Windows\System32\inetsrv\config\applicationHost.config which makes
> > the
> > configuration XML file no longer well-formed and IIS cannot parse it.
>
> > Please check if there is a previous backup under:
> > C:\Windows\System32\inetsrv\backup\* . If there is, stop IIS services
> > and
> > copy the backup applicationHost.config and overwrite current corrupt one
> > in
> > \inetsrv\config .
>
> > If there isn't any available backup file, please stop IIS services first
> > and try uninstalling it again. Regardless if the uninstallation
> > succeeds,
> > please manually delete the \inetsrv directory under C:\Windows\System32
> > .
> > Then please reboot the server to perform a clear reinstallation of IIS.
> > If
> > the reinstallation succeeds, you can use the following command to create
> > a
> > fresh backup of IS configurations:
>
> > Open a DOS prompt:
>
> > C:\Windows\System32>cd inetsrv
>
> > C:\Windows\System32\inetsrv>appcmd add backup cleaninstall
>
> > Please let me know if problem still persists.
>
> > Have a nice day.
>
> > Sincerely,
>
> > WenJun Zhang
>
> > Microsoft Online Community Support
>
> > Delighting our customers is our #1 priority. We welcome your comments
> > and
> > suggestions about how we can improve the support we provide to you.
> > Please
> > feel free to let my manager know what you think of the level of service
> > provided. You can send feedback directly to my manager at:
> > msd...@microsoft.com.
>
> > ==================================================
> > Get notification to my posts through email? Please refer to
> >http://msdn.microsoft.com/subscriptions/managednewsgroups/d efault.asp...
> > ications.
>
> > Note: The MSDN Managed Newsgroup support offering is for non-urgent
> > issues
> > where an initial response from the community or a Microsoft Support
> > Engineer within 1 business day is acceptable. Please note that each
> > follow
> > up response may take approximately 2 business days as the support
> > professional working with you may need further investigation to reach
> > the
> > most efficient resolution. The offering is not appropriate for
> > situations
> > that require urgent, real-time or phone-based interactions or complex
> > project analysis and dump analysis issues. Issues of this nature are
> > best
> > handled working with a dedicated Microsoft Support Engineer by
> > contacting
> > Microsoft Customer Support Services (CSS) at
> >http://msdn.microsoft.com/subscriptions/support/default.asp x.
> > ==================================================
> > This posting is provided "AS IS" with no warranties, and confers no
> > rights.- Hide quoted text -
>
> - Show quoted text -
I suggest reinstall the OS. This is why.
Your original error was easy to overcime -- there was invalid XML in
applicationHost.config on line 860 that can be fixed without
uninstalling. If you provided that file, someone can tell you what's
wrong and possibly fix the corruption.
Reinstallation will not fix file corruption in the .config file
because IIS reinstallation will try to open the .config file... which
will encounter the same XML well-formedness error when it goes to add/
remove features as part of reinstallation. Thus, it will fail, which
is exactly what you observed.
The correct resolution was to fix the invalid XML file to get yourself
out of the jam.
What you were hoping for, that reinstalling IIS will rebuild the
corrupted file, is impossible to accomplish. We've thought about this
problem a lot, but the flexibility of IIS7 configuration prevents such
restoration behavior. Why? Well, the file content depends on the
features that the user chose to install, so there is no single
"default/correct configuration file". Plus, the file contents have to
be edited as XML and not plain text because users do not expect every
feature addition/removal to revert any existing settings to some
default state while adding/removing the new feature. Thus, rebuilding
the .config file is not possible.
Unfortunately, you went down the path of attempting to manually delete
the inetsrv folder and causing mismatched state between what Windows
thinks is installed and the actual files that are installed.
All IIS files are considered part of the OS and thus under Windows
File Protection, which will prevent you from ever removing the inetsrv
directory as soon as IIS has ever been installed on the OS. It doesn't
matter what user account -- there is a file handle open against that
directory, so you won't be able to delete the directory. And you won't
be able to kill the process that has the file handle since your
machine will BSOD and reboot when you kill that process.
Basically, what you are trying to do is confusing Windows further, and
Vista is designed to babysit the user and will fight against you. It's
not Windows 2000 or XP which will just roll over and let you do
whatever you want.
Unfortunately, you have confused Windows Features, and it is really
unsupported to walk anyone through manually running commands to unwind
all the damage. I believe OS reinstallation is the best supported
solution here.
//David
http://w3-4u.blogspot.com
http://blogs.msdn.com/David.Wang
//