Csharp/C#教程:尝试使用ServerManager获取应用程序池时出现COMException分享


尝试使用ServerManager获取应用程序池时出现COMException

当我尝试使用以下代码从远程服务器获取IIS应用程序池列表时

List appPools; using (ServerManager serverManager = ServerManager.OpenRemote("XXX")) { appPools = serverManager.ApplicationPools.ToList(); } 

我得到一个例外:

 System.Runtime.InteropServices.COMException (0x800706BA): Retrieving the COM class factory for remote component with CLSID {2B72133B-3F5B-4602-8952-803546CE3344} from machine XXX failed due to the following error: 800706ba. 

可能导致这种情况的任何想法?

事实certificate,可以通过在防火墙中添加适当的规则来解决问题:

上述解决方案的灵感来自于此线程: Windows防火墙阻止OAB连接 。

上述就是C#学习教程:尝试使用ServerManager获取应用程序池时出现COMException分享的全部内容,如果对大家有所用处且需要了解更多关于C#学习教程,希望大家多多关注—计算机技术网(www.ctvol.com)!

本文来自网络收集,不代表计算机技术网立场,如涉及侵权请联系管理员删除。

ctvol管理联系方式QQ:251552304

本文章地址:https://www.ctvol.com/cdevelopment/1005951.html

(0)
上一篇 2021年12月28日
下一篇 2021年12月28日

精彩推荐