当我试图在windows 2016上安装NFS服务时,它就失败了。在系统事件日志中,我有3个错误:
- The Server for NFS Open RPC (ONCRPC) Portmapper service failed to start due to the following error:
A device attached to the system is not functioning.
- The Server for NFS Driver service depends on the Server for NFS Open RPC (ONCRPC) Portmapper
我的代码是在线程上调用CoInitializeEx(NULL, COINIT_MULTITHREADED),然后在同一个线程上调用CoInitialize(NULL)。
我知道CoInitialize(NULL)调用在RPC_E_CHANGED_MODE中会失败,但这不是我关心的问题。此错误由代码正确处理如下:
if (retValue == RPC_E_CHANGED_MODE) {
thModel = kThModelMulti; // thread was initialized with MTA model
}
请不要担心功能方面。CoInitialize(NULL) 对的调