我尝试使用以下代码在Linux上与sqlcmd连接:
sqlcmd -S tcp:x.x.x.x,1433 -d myDtaBaseName -U userName -P *******
并出现以下错误:
Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : Login timeout expired.
Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : TCP Provider: Error code 0x102.
Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online..
但是当我尝试在Windows服务器和桌面Windows上进行连接时工作正常。