Flume采集数据集成到Hive分桶表问题总结

Exception in thread “main” java.lang.NoClassDefFoundError: org/antlr/runtime/RecognitionException
解决:拷贝hive中的jar到flume的lib下
antlr-3.4.jar
antlr-runtime-3.4.jar

Caused by: java.lang.NullPointerException: Expected timestamp in the Flume event headers, but it was null
解决:
ag1.sinks.sink1.useLocalTimeStamp=true

Caused by: java.lang.ClassNotFoundException: com.facebook.fb303.FacebookService$Iface
解决:
拷贝hive中的lib的libfb303-0.9.3.jar到flume/lib

Cannot stream to table that has not been bucketed : {metaStoreUri=‘thrift://master:9083’, database=‘default’, table=‘t_pages’, partitionVals=[] }
解决:
flume必须连接hive的分桶表

org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat cannot be cast to org.apache.hadoop.hive.ql.io.AcidOutputFormat
解决:
创建hive表加入:stored as orc;

还有就是报hive表字段和flume配置中字段找不到,因为hive表只能识别到小写,所以修改flume配置为:
awen.sinks.k1.serializer.fieldnames = datestring,username,operatione,userip,url,title,beforeurl,equipment,airip都

需要导入的jar包总结
libfb303-0.9.3.jar
antlr-3.4.jar
antlr-runtime-3.4.jar

hadoop-auth-2.5.0-cdh5.3.3.jar
hadoop-common-2.5.0-cdh5.3.3.jar
hadoop-hdfs-2.5.0-cdh5.3.3.jar
hadoop-hdfs-nfs-2.6.0-cdh5.12.2.jar
hadoop-mapred-0.22.0.jar 没找到

hive-cli-1.1.0-cdh5.12.2.jar
hive-common-1.1.0-cdh5.12.2.jar
hive-exec-1.1.0-cdh5.12.2.jar
hive-hcatalog-core-1.1.0-cdh5.12.2.jar
hive-hcatalog-pig-adapter-1.1.0-cdh5.12.2.jar
hive-hcatalog-server-extensions-1.1.0-cdh5.12.2.jar
hive-hcatalog-streaming-1.1.0-cdh5.12.2.jar
hive-metastore-1.1.0-cdh5.12.2.jar
htrace-core-3.2.0-incubating.jar

commons-configuration-1.9.jar
commons-io-2.4.jar
common-1.1.0.jar 没找到

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值