美文网首页
hive tez 引擎 导入数据导入到 动态分区表 文件不存在

hive tez 引擎 导入数据导入到 动态分区表 文件不存在

作者: 无来无去_A | 来源:发表于2020-04-27 19:08 被阅读0次

    DBserver版本: 6.3.5

    使用hive版本:  apache-hive-3.1.2-bin.tar.gz

    linux 版本:  CentOS-7.5-x86_64-DVD-1804.iso

    使用tez 引擎后有时候导入数据提示文件不存在,但是我文件系统上面是有这个文件的。

    解决办法: 1 . 需要过一段时间导入就可以导入

                     2. 把hive的执行引擎替换为mr

    导入命令:

    load data local inpath '/opt/module/hive/datas/dept.txt' into table dept_partition_dy ;

    表结构:

    CREATE TABLE `dept_partition_dy`(

      `id` int,

      `name` string)

    PARTITIONED BY (

      `loc` int)

    ROW FORMAT SERDE

      'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe'

    WITH SERDEPROPERTIES (

      'field.delim'='\t',

      'serialization.format'='\t')

    STORED AS INPUTFORMAT

      'org.apache.hadoop.mapred.TextInputFormat'

    OUTPUTFORMAT

      'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'

    LOCATION

      'hdfs://hadoop102:8020/user/hive/warehouse/mydb.db/dept_partition_dy'

    TBLPROPERTIES (

      'bucketing_version'='2',

      'transient_lastDdlTime'='1587984078') 

    SQL 错误 [2] [08S01]: Error while processing statement: FAILED: Execution Error, return code 2 from org.apache.hadoop.hive.ql.exec.tez.TezTask. Vertex failed, vertexName=Map 1, vertexId=vertex_1587904916551_0019_4_00, diagnostics=[Vertex vertex_1587904916551_0019_4_00 [Map 1] killed/failed due to:ROOT_INPUT_INIT_FAILURE, Vertex Input: dept_partition_dy__temp_table_for_load_data__ initializer failed, vertex=vertex_1587904916551_0019_4_00 [Map 1], org.apache.hadoop.mapred.InvalidInputException: Input path does not exist: file:/opt/module/hive/datas/dept.txt

    at org.apache.hadoop.mapred.FileInputFormat.singleThreadedListStatus(FileInputFormat.java:297)

    at org.apache.hadoop.mapred.FileInputFormat.listStatus(FileInputFormat.java:239)

    at org.apache.hadoop.mapred.FileInputFormat.getSplits(FileInputFormat.java:325)

    at org.apache.hadoop.hive.ql.io.HiveInputFormat.addSplitsForGroup(HiveInputFormat.java:519)

    at org.apache.hadoop.hive.ql.io.HiveInputFormat.getSplits(HiveInputFormat.java:765)

    at org.apache.hadoop.hive.ql.exec.tez.HiveSplitGenerator.initialize(HiveSplitGenerator.java:245)

    at org.apache.tez.dag.app.dag.RootInputInitializerManager$InputInitializerCallable$1.run(RootInputInitializerManager.java:280)

    at org.apache.tez.dag.app.dag.RootInputInitializerManager$InputInitializerCallable$1.run(RootInputInitializerManager.java:271)

    at java.security.AccessController.doPrivileged(Native Method)

    at javax.security.auth.Subject.doAs(Subject.java:422)

    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1729)

    at org.apache.tez.dag.app.dag.RootInputInitializerManager$InputInitializerCallable.call(RootInputInitializerManager.java:271)

    at org.apache.tez.dag.app.dag.RootInputInitializerManager$InputInitializerCallable.call(RootInputInitializerManager.java:255)

    at com.google.common.util.concurrent.TrustedListenableFutureTask$TrustedFutureInterruptibleTask.runInterruptibly(TrustedListenableFutureTask.java:125)

    at com.google.common.util.concurrent.InterruptibleTask.run(InterruptibleTask.java:57)

    at com.google.common.util.concurrent.TrustedListenableFutureTask.run(TrustedListenableFutureTask.java:78)

    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

    at java.lang.Thread.run(Thread.java:748)

    ]Vertex killed, vertexName=Reducer 2, vertexId=vertex_1587904916551_0019_4_01, diagnostics=[Vertex received Kill in INITED state., Vertex vertex_1587904916551_0019_4_01 [Reducer 2] killed/failed due to:OTHER_VERTEX_FAILURE]DAG did not succeed due to VERTEX_FAILURE. failedVertices:1 killedVertices:1

    相关文章

      网友评论

          本文标题:hive tez 引擎 导入数据导入到 动态分区表 文件不存在

          本文链接:https://www.haomeiwen.com/subject/wsvuwhtx.html