我在 Windows 7 上遇到了 IIS 7 这个奇怪的问题,它无法加载我正在使用的 dll。但是,它似乎只在一段时间后发生;它可以在随机的一段时间内正常工作,直到它开始抛出此消息:
Could not load file or assembly 'Mono.Security, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756' or one of its dependencies. Access is denied.
如果我删除 dll 并重新添加它,它可以正常工作一段时间,然后再次停止工作。这在 asp.net 网页和 web 服务中都会发生,但是在普通的 .net 桌面程序中它可以正常工作。
这只发生在 Mono.Security 上,而不是我正在使用的任何其他 dll 上(我使用的是依赖于 Mono.Security 的 Npgsql)。
如果有人可以对此提供一些见解,那就太好了。