我最近使用这个命令更新了 NewRelic 代理:
Update-Package NewRelic.Azure.WebSites
当我重新部署我的站点时,它会在日志中显示此错误而失败。有任何想法吗?
Copying all files to temporary location below for package/publish:
C:\DWASFiles\Sites\mysite\Temp\eca8e7b2-2483-4759-ba73-1c04312a8910.
KuduSync.NET from: 'C:\DWASFiles\Sites\mysite\Temp\eca8e7b2-2483-4759-ba73-1c04312a8910' to: 'C:\DWASFiles\Sites\mysite\VirtualDirectory0\site\wwwroot'
Error: The process cannot access the file 'C:\DWASFiles\Sites\mysite\VirtualDirectory0\site\wwwroot\newrelic\NewRelic.Agent.Core.dll' because it is being used by another process.
Copying file: 'Web.config'
Copying file: 'bin\mysite.dll'
Copying file: 'bin\zh\mysite.resources.dll'
Copying file: 'newrelic\NewRelic.Agent.Core.dll'
An error has occurred during web site deployment
更新:* 我试过卸载 New Relic。它试图删除 dll 并失败。* 我已经尝试过网络部署。它以同样的方式失败。
此时剩下的就是简单地创建一个新的 azure 网站并重新部署。.