Reason:
ERROR CODE: 0x80070021 is
ERROR_LOCK_VIOLATION The process cannot access the file because another process has locked a portion of the file.
Solution:
There are usually a few more lines in that error response that points to the exact line in the config file (and hence the locked section) that has the problem. You will either have to unlock that section or not use it in your application’s web.config file.
For e.g., one can lock/unlock handlers/modules sections by either
Ø use appcmd.exe
%windir%\system32\inetsrv\appcmd unlock config -section:system.webServer/handlers
%windir%\system32\inetsrv\appcmd unlock config -section:system.webServer/modules
OR
Ø manually change value from "Deny" to "Allow" for below settings in %windir%\system32\inetsrv\config\ applicationHost.config
<section name="handlers" overrideModeDefault="Deny" />
<section name="modules" allowDefinition="MachineToApplication" overrideModeDefault="Deny"/>
You can also configure the locking via IIS manager UI.
http://blogs.iis.net/webtopics/archive/2010/03/08/troubleshooting-http-500-19-errors-in-iis-7.aspx