如何调查仅在配备 NVIDIA Quadro 的计算机上经常发生的客户端 WSAECONNABORTED?
我们有一个 C++ 客户端/服务器应用程序,其中客户端从服务器检索并呈现 3D 内容。
我们的客户端经常与服务器断开连接(超过 50% 的运行时间不到 1 分钟),recv
失败且 WSAGetLastError
返回 WSAECONNABORTED
。但奇怪的是,这种情况仅在以下情况下发生:
- 客户端具有 NVIDIA Quadro GPU(发生在具有不同版本 Quadro 的多台机器上)
- 我们的应用程序使用 OpenGL 进行渲染
我们在具有其他 GPU 的机器上没有看到这种情况。切换到 Direct3D 进行渲染也可以消除断开连接。在一台 Quadro 机器上,在通过 Windows 更新推送驱动程序更新后,这种情况开始出现(频率较低,但仍然超过一天一次)。恢复驱动程序有帮助。
服务器在 recv
中也会失败,并出现 WSAECONNRESET
。根据这个答案,我们在服务器端做错了事情,我们确实在做关闭
,然后立即关闭
。但由于服务器获取了WSAECONNRESET,我想说客户端首先强制断开连接,因此问题不是由服务器执行错误关闭引发的。
从长远来看,我们可能会解决服务器shutdown
+ close
问题,但我们希望有一些短期解决方法或对 Quadros 上的行为的解释。也许这是一个以某种方式与 Winsock 交互的驱动程序错误,尽管这听起来很古怪。
服务器 WSAECONNRESET
意味着客户端首先断开连接,我说得对吗?
关于如何解决 GPU 驱动程序可能对套接字造成的潜在奇怪错误的任何想法? strong> 当然,我并不期望有一个具体的解决方案来解决我们奇怪的问题,但任何想法都可以。
We have a C++ client/server application in which the client retrieves and renders 3D content from a server.
Our client disconnects from the server very often (more than 50% of runs after less than 1 minute) with recv
failing and WSAGetLastError
returning WSAECONNABORTED
. But the strange thing is that this happens only when:
- the client has an NVIDIA Quadro GPU (happening on multiple machines with various versions of Quadro)
- our application uses OpenGL for rendering
We didn't see this on a machine with another GPU. Switching to Direct3D for rendering also makes the disconnects go away. On one Quadro machine this started appearing (less often but still more than once a day) after a driver update pushed through Windows update. Reverting the driver helped.
The server also fails in recv
with WSAECONNRESET
. According to this answer we are doing things wrong on the server side, where we indeed do shutdown
and then immediately close
. But since the server gets WSAECONNRESET
I would say that the client forcibly disconnects first so the problem is not initiated by the server doing a bad close.
We'll probably fix the server shutdown
+ close
problem in the long term but we would like some short term workaround or explanation for the behavior on Quadros. Maybe it's a driver bug that somehow interacts with Winsock, even though it sounds very wacky.
Am I right that server WSAECONNRESET
means that the client disconnected first?
Any ideas on how to troubleshoot potential weird bugs that the GPU driver would cause to sockets? I don't expect a specific solution to our weird problem of course, but any idea would do.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
客户端是否可能发出关闭/关闭命令,而未读数据仍在接收缓冲区中?这将中止连接。
Is it possible that the client is issuing a close/shutdown with unread data still in the receive buffer? This will abort the connection.