kettle 中出现的问题集锦

本文汇总了kettle使用过程中遇到的问题,包括启动界面报错、连接MySQL资源库失败、数据溢出、类型不一致等问题,并提供了详细的解决办法,如更新MySQL驱动、调整数据库字段类型等。

前言:

        对于一些新手来说,初次接触kettle的过程中可能会出现一系列的问题,然后由于网上的一些问题和资料都不够详细,解决办法也不是很有效,本文大致总结了kettle中出现的一些常见的问题以及相应的解决办法,供大家参考,如有不足欢迎大家指出:

1、kettle加载启动界面报错,出现下面的问题

INFO  25-11 13:48:05,948 - Using"/tmp/vfs_cache" as temporary files store.

INFO  25-11 13:48:06,915 - Spoon - Logging goes tofile:///tmp/spoon_bd3cbf27-b2d2-11e6-98af-d77e84cfe1a2.log

WARN  25-11 13:48:08,384 - could not parse[vertical] as Align value

#

# A fatal errorhas been detected by the Java Runtime Environment:

#

#  SIGSEGV (0xb) at pc=0x00007fdd42d2e987,pid=59090, tid=140589643634432

#

# JRE version:6.0_45-b06

# Java VM: JavaHotSpot(TM) 64-Bit Server VM (20.45-b01 mixed mode linux-amd64 compressed oops)

# Problematicframe:

# C  [libxul.so+0x11e0987]  __float128+0x11e0987

#

# An error reportfile with more information is saved as:

# ~/tool/kettle/hs_err_pid59090.log

#

# If you wouldlike to submit a bug report, please visit:

#  http://java.sun.com/webapps/bugreport/crash.jsp

# The crashhappened outside the Java Virtual Machine in native code.

# See problematicframe for where to report the bug.

#

./spoon.sh: line140: 59090 Aborted                 (core dumped)"$_PENTAHO_JAVA" $OPT $STARTUP -lib $LIBPATH "${1+$@}"

原因:这应该是GNOME或者X的库和Spoon集成的浏览器不能一起工作导致的

解决办法:

在当前用户的目录下添加.spoonrc文件

cd ~/.kettle

vim .spoonrc

ShowWelcomePageOnStartup=N

 

2、运行kettle 4.1的时候连接MySQL资源库的时候报错

Error inserting/updating row

Data truncation: Incorrect datetime value:'' for column 'LOG_DATE' at row 1

详细信息:

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

Error inserting/updating row

Data truncation: Incorrect datetime value:'' for column 'LOG_DATE' at row 1

 

         atorg.pentaho.di.core.database.Database.insertRow(Database.java:1393)

         atorg.pentaho.di.core.database.Database.insertRow(Database.java:1307)

         atorg.pentaho.di.core.database.Database.insertRow(Database.java:1295)

         atorg.pentaho.di.core.database.Database.insertRow(Database.java:1278)

         atorg.pentaho.di.repository.kdr.delegates.KettleDatabaseRepositoryConnectionDelegate.insertTableRow(KettleDatabaseRepositoryConnectionDelegate.java:1695)

         at。。。。。。。

如图:

  


 

原因:出现这种情况是由于kettle版本和相对应的MySQL驱动不一致造成的

解决办法:

方法1:只需要替换kettle/libext/JDBC/下的MySQL驱动,删除

mysql-connector-java-3.1.14-bin.jar,添加mysql-connector-java-5.1.17.jar,重新启动即可

方法2:直接下载kettle4.2或者更高版本即可

 

3、出现Datatruncation: Out of range value for column 'NEWSCODE'at row 1 问题

解决办法:

    登录到mysql,找到对应的表,找到对应的的字段NEWSCODE类型改为 bigint20 0,具体的字段根据Oracle字段转换成MySQL字段变化,改变MySQL相对应的字段的类型

 

4、出现 ORA-00932: 数据类型不一致: 应为 NUMBER, 但却获得 BINARY

解决办法:

    出现这个问题的原因可能是查询条件里添加了某些函数,比如to_char()函数,去掉即可,或者使用正确的函数转换数据。

 

5、针对kettle执行过程出现Couldn't get row from result set  Io异常:Socket read timed out

 

原因:出现这个问题原因可能是MySQL数据库设置的wait_timeout过短(缺省为8小时由于MySQL服务在长时间不连接之后断开了,断开之后的首次请求会抛出这个异常

解决办法:

以root用户登录MySQL,首先查看wait_timeout:

>show global variables like'wait_timeout';

根据实际情况,设置wait_timeout比之前的时间长一点

>set global wait_timeout=864000;

注意:

    wait timeout的值可以设定,但最多只能是2147483,不能再大了,也就是约24.85

 

6、如果是通过Linux或者windows命令行下执行脚本的话,会报下面的错

 

Error in step, asking everyone to stopbecause of:Error looking up row in database

    The last packet successfully received fromthe server was 59,903,094 milliseconds ago. The last packet sent    successfully to the server was 59,903,094 milliseconds ago. is longerthan the server configured value of    'wait_timeout'. You should consider either expiring and/or testingconnection validity before use in your application,     increasing the server configured valuesfor client timeouts, or using the Connector/J connection property    'autoReconnect=true' to avoid this problem.

  org.pentaho.di.trans.steps.insertupdate.InsertUpdate.processRow(InsertUpdate.java:307)

  org.pentaho.di.trans.step.RunThread.run(RunThread.java:40)

   java.lang.Thread.run(Thread.java:745)

原因:出现这个问题原因和上面的原因是一样的:MySQL数据库设置的wait_timeout过短

解决办法:

以root用户登录MySQL,首先查看wait_timeout:

>show global variables like'wait_timeout';

根据实际情况,设置wait_timeout比之前的时间长一点

>set global wait_timeout=864000;

注意:

    wait timeout的值可以设定,但最多只能是2147483,不能再大了,也就是约24.85


评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值