kettle连接数据库报错

错误连接数据库 [ads] : org.pentaho.di.core.exception.KettleDatabaseException: 

Error occurred while trying to connect to the database

Error connecting to database: (using class com.microsoft.sqlserver.jdbc.SQLServerDriver)

通过端口 1433 连接到主机 ${aos_dw_host} 的 TCP/IP 连接失败。错误:“null。请验证连接属性。确保 SQL Server 的实例正在主机上运行,且在此端口接受 TCP/IP 连接,还要确保防火墙没有阻止到此端口的 TCP 连接。”。

org.pentaho.di.core.exception.KettleDatabaseException: 

Error occurred while trying to connect to the database

Error connecting to database: (using class com.microsoft.sqlserver.jdbc.SQLServerDriver)

通过端口 1433 连接到主机 ${aos_dw_host} 的 TCP/IP 连接失败。错误:“null。请验证连接属性。确保 SQL Server 的实例正在主机上运行,且在此端口接受 TCP/IP 连接,还要确保防火墙没有阻止到此端口的 TCP 连接。”。

at org.pentaho.di.core.database.Database.normalConnect(Database.java:472)

at org.pentaho.di.core.database.Database.connect(Database.java:370)

at org.pentaho.di.core.database.Database.connect(Database.java:341)

at org.pentaho.di.core.database.Database.connect(Database.java:331)

at org.pentaho.di.core.database.DatabaseFactory.getConnectionTestReport(DatabaseFactory.java:80)

at org.pentaho.di.core.database.DatabaseMeta.testConnection(DatabaseMeta.java:2783)

at org.pentaho.ui.database.event.DataHandler.testDatabaseConnection(DataHandler.java:597)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at org.pentaho.ui.xul.impl.AbstractXulDomContainer.invoke(AbstractXulDomContainer.java:313)

at org.pentaho.ui.xul.impl.AbstractXulComponent.invoke(AbstractXulComponent.java:157)

at org.pentaho.ui.xul.impl.AbstractXulComponent.invoke(AbstractXulComponent.java:141)

at org.pentaho.ui.xul.swt.tags.SwtButton.access$500(SwtButton.java:43)

at org.pentaho.ui.xul.swt.tags.SwtButton$4.widgetSelected(SwtButton.java:137)

at org.eclipse.swt.widgets.TypedListener.handleEvent(Unknown Source)

at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)

at org.eclipse.swt.widgets.Display.sendEvent(Unknown Source)

at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)

at org.eclipse.swt.widgets.Display.runDeferredEvents(Unknown Source)

at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)

at org.eclipse.jface.window.Window.runEventLoop(Window.java:820)

at org.eclipse.jface.window.Window.open(Window.java:796)

at org.pentaho.di.ui.xul.KettleDialog.show(KettleDialog.java:80)

at org.pentaho.di.ui.xul.KettleDialog.show(KettleDialog.java:47)

at org.pentaho.di.ui.core.database.dialog.XulDatabaseDialog.open(XulDatabaseDialog.java:116)

at org.pentaho.di.ui.core.database.dialog.DatabaseDialog.open(DatabaseDialog.java:60)

at org.pentaho.di.ui.spoon.delegates.SpoonDBDelegate.editConnection(SpoonDBDelegate.java:96)

at org.pentaho.di.ui.spoon.Spoon.doubleClickedInTree(Spoon.java:3108)

at org.pentaho.di.ui.spoon.Spoon.doubleClickedInTree(Spoon.java:3043)

at org.pentaho.di.ui.spoon.Spoon.access$2300(Spoon.java:361)

at org.pentaho.di.ui.spoon.Spoon$26.widgetDefaultSelected(Spoon.java:6184)

at org.eclipse.swt.widgets.TypedListener.handleEvent(Unknown Source)

at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)

at org.eclipse.swt.widgets.Display.sendEvent(Unknown Source)

at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)

at org.eclipse.swt.widgets.Display.runDeferredEvents(Unknown Source)

at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)

at org.pentaho.di.ui.spoon.Spoon.readAndDispatch(Spoon.java:1366)

at org.pentaho.di.ui.spoon.Spoon.waitForDispose(Spoon.java:8022)

at org.pentaho.di.ui.spoon.Spoon.start(Spoon.java:9277)

at org.pentaho.di.ui.spoon.Spoon.main(Spoon.java:692)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at org.pentaho.commons.launcher.Launcher.main(Launcher.java:92)

Caused by: org.pentaho.di.core.exception.KettleDatabaseException: 

Error connecting to database: (using class com.microsoft.sqlserver.jdbc.SQLServerDriver)

通过端口 1433 连接到主机 ${aos_dw_host} 的 TCP/IP 连接失败。错误:“null。请验证连接属性。确保 SQL Server 的实例正在主机上运行,且在此端口接受 TCP/IP 连接,还要确保防火墙没有阻止到此端口的 TCP 连接。”。

at org.pentaho.di.core.database.Database.connectUsingClass(Database.java:585)

at org.pentaho.di.core.database.Database.normalConnect(Database.java:456)

... 47 more

Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: 通过端口 1433 连接到主机 ${aos_dw_host} 的 TCP/IP 连接失败。错误:“null。请验证连接属性。确保 SQL Server 的实例正在主机上运行,且在此端口接受 TCP/IP 连接,还要确保防火墙没有阻止到此端口的 TCP 连接。”。

at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDriverError(SQLServerException.java:190)

at com.microsoft.sqlserver.jdbc.SQLServerException.ConvertConnectExceptionToSQLServerException(SQLServerException.java:241)

at com.microsoft.sqlserver.jdbc.SocketFinder.findSocket(IOBuffer.java:2243)

at com.microsoft.sqlserver.jdbc.TDSChannel.open(IOBuffer.java:491)

at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1309)

at com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:991)

at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:827)

at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:1012)

at java.sql.DriverManager.getConnection(DriverManager.java:664)

at java.sql.DriverManager.getConnection(DriverManager.java:270)

at org.pentaho.di.core.database.Database.connectUsingClass(Database.java:558)

... 48 more

主机名       : ${aos_dw_host}

端口           : 1433

数据库名:aos_ads

FineReport sgq3256 发布于 2023-2-7 15:44
1min目标场景问卷 立即参与
回答问题
悬赏:3 F币 + 添加悬赏
提示:增加悬赏、完善问题、追问等操作,可使您的问题被置顶,并向所有关注者发送通知
共2回答
最佳回答
0
IndustryPaysLv6见习互助
发布于2023-2-7 16:01(编辑于 2023-2-7 16:04)

微信截图_20230207155956.png数据库连接错误,${aos_dw_host}数据库指向文件配置地址找不到,查看kettle.properties该文件配置信息是否有误,没有则添加文件;

最佳回答
0
CD20160914Lv8专家互助
发布于2023-2-7 15:45

主机名       : ${aos_dw_host}

你主机名设置的是变量,你没有给变量设置对应的值,所以找不到主机

  • 3关注人数
  • 402浏览人数
  • 最后回答于:2023-2-7 16:04
    请选择关闭问题的原因
    确定 取消
    返回顶部