You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Ubuntu 22.04无法连接远程SQL Server Express 2012求助

问题:Ubuntu 22.04连接远程SQL Server Express 2012失败

我在Ubuntu 22.04系统上,通过apt安装了openssl、unixodbc-dev、freetds和mssqlodbc18,尝试连接远程SQL Server Express 2012时遇到错误,错误信息如下:

Error 20002 (severity 9):
Adaptive Server connection failed(自适应服务器连接失败)

我已经做了以下操作,但问题仍未解决:

  • 修改FreeTds.conf文件,添加了如下配置:
[sqlserver]
        host = XXX.XXX.XXX.X
        port = 1433
        tds version = 7.4
        instance=XX_XXXX
  • 将openssl.cnf文件中的CipherString设置为SECLEVEL=0
  • 用telnet测试能成功连接目标服务器的对应端口,但使用Python的pyodbc连接并执行查询时,依然出现相同的连接失败错误。

内容的提问来源于stack exchange,提问作者Arjun Bhandari

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.20 16:22:36