Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
262 views
in Technique[技术] by (71.8m points)

sql server - Intermittent ODBC connection failures

We are developing an in-house 32bit app. The app connects to a SQL Server. The test environment is SQL Server 2008 R2, and the live environment is SQL Server 2014 SP2.

Connection to the database is made using this ODBC string:

Driver={SQL Server};Server=<redacted>;Database=<redacted>;Trusted_Connection=Yes;

The users for this database belong to a 'domain local' security group. We have users from three different AD domains as members of this group. The group is defined as a login for the SQL Server and a user for the target database. In the test environment, this worked fine.

In the live environment, only some of the users can successfully connect to the database. Interestingly, users who are in the security group but NOT in the same domain as the server can connect. Users in the same domain as the server cannot. (I've not checked with all 25 users, but that's the pattern I'm seeing). Users (like me) with sysadmin rights to the database server have no trouble.

I've been over everything I can think of with a fine tooth comb trying to figure out why it works on one server but not the other, with no luck. I've tried removing the group as a user & adding back, taking users out of the group and putting them back in, and so forth. The SQL Server service is running under the same domain account on both servers.

Any insight is appreciated.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Thanks to Birel for pointing me in the right direction. The answer was that on the new 2014 server, the 'SQL Server Browser Service' was not running. I set it to automatic startup, and started it. That resolved the issue.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...