本文介绍了详解wmi rpc 服务器不可用的解决方案,分享给大家,具体如下:
connectionoptions connectionoptions = new connectionoptions(); connectionoptions.username = username; connectionoptions.password = password; managementscope managementscope = new managementscope("\\\\" + host + "\\root\\cimv2", connectionoptions); try { managementscope.connect(); } catch { }
发生"rpc 服务器不可用"或者其它无法连接的情况下(确保连接本机没有问题)的解决方案:
1 检查远程服务器 “remote procedure call”、“dcom server process launcher” 和 “dhcp client”服务 是否开启
2 检查远程服务器 本地安全策略--本地策略--安全选项--网络访问:本地帐户的共享和安全模式--属性 选择:经典-本地用户以自己的身份验证
3 在远程服务器上,运行"netsh firewall set service remoteadmin".
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持移动技术网。
如对本文有疑问, 点击进行留言回复!!
使用Visual Studio2019创建C#项目(窗体应用程序、控制台应用程序、Web应用程序)
C#实现获取本地内网(局域网)和外网(公网)IP地址的方法分析
网友评论