WCF 服务在 NT AUTHORITY\NETWORK SERVICE 帐户下运行,请求被其他帐户(在数据库上是管理员)模拟,但 NHibernate 抛出异常:
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
有什么想法吗?
最佳答案
NHibernate 与该问题无关。这是模仿设置问题。 The solution could be found here .
关于c# - 使用 Windows 身份验证的 NHibernate 模拟,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6019631/