由于 AntiVirus,登录前握手期间发生错误?

Error occurred during the pre-login handshake, due to AntiVirus?

我需要你的专业知识来解决我的一个问题。我经常遇到从 Power BI 本地网关到 SQL 连接

的间歇性问题

网关日志错误

Error: A connection was successfully established with the server, but then an error occurred during the pre-login handshake. (provider: SSL Provider, error: 0 - The wait operation timed out.)

这里的困难部分是很难重现☹️ 每当我尝试从网关连接到 SQL 服务器时,它都会成功,但在极少数情况下会失败。

我们为找到根本原因所做的步骤

最后,我们联系了我们的内部支持团队,他们告诉 运行 网络跟踪器。所以我们做到了。 很长一段时间后,我们有幸在网络跟踪器中捕获到错误。 (下图)

支持团队这样说:

我们看到客户端(网关服务器)在 14 秒后为 TLS SSL 握手发送客户端问候,这种延迟导致连接失败,因为连接需要在 15 秒内建立。 我们看到了相同的模式,客户端在多个通信实例上造成延迟。 而这种延迟一般是由 Antivirus

我的问题:

P.S 我知道这个问题已经在 SO 中提出并且可能重复,但我真正的问题是这个防病毒软件可能是这个问题的原因吗?

经过多次尝试,问题终于解决了。以下是对我们有用的解决方案

• Azure AD 加入,其中连接指向“login.microsoft.com”并延迟连接。注册表和 GPO 中的一些设置需要执行才能禁用此 Auto Azure WorkPlace 连接。

https://docs.microsoft.com/en-us/azure/active-directory/device-management-troubleshoot-hybrid-join-windows-current

它讨论了通过 GPO 限制服务器加入 AzureAD,解析为:

HKLM\SOFTWARE\Policies\Microsoft\Windows\WorkplaceJoin\ key: autoWorkplaceJoin = 0

• 前往 http://ctldl.windowsupdate.com 的连接,请参阅下面讨论此问题的文章。

https://blogs.technet.microsoft.com/askds/2018/04/10/tls-handshake-errors-and-connection-timeouts-maybe-its-the-ctl-engine/

To disable it:
• Create a backup of this registry key (export and save a copy)
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\SystemCertificates\AuthRoot
• Then create the following DWORD registry values under the key
“EnableDisallowedCertAutoUpdate”=dword:00000000 “DisableRootAutoUpdate”=dword:00000001

我希望这对以后的人有所帮助!