繁体   English   中英

到端口的TCP / IP连接失败。 sqoop jdbc连接错误

[英]TCP/IP connection to the port is failed. sqoop jdbc connection error

当我尝试运行sqoop命令导入时

sqoop import --connect jdbc:sqlserver://localhost/db_name--username 
user--password user--table table_name.

我收到以下错误。

ERROR: The TCP/IP connection to the host 127.0.0.1, port 1433 has failed. Error: "Connection refused: connect. Verify the connection properties. Make sure that an instance of SQL Server is running on the host and accepting TCP/IP connections at the port. Make sure that TCP connections to the port are not blocked by a firewall.".

我的命名管道和TCP / IP均已启用,并且具有端口1433。SQLServer TCP / IP协议也具有端口1433。我创建了防火墙入站和出站规则以允许连接。仍然出现相同的错误。

请尝试将sqljdbc42.jar添加到sqoop lib路径并添加

--driver com.microsoft.sqlserver.jdbc.SQLServerDriver

到您的sqoop导入命令。

还要确保db_name和--username之间应该有一个空格,并且username和--password之间应该有一个空格,并且在命令末尾没有点。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM