2016-06-30 7 views
1

Ich versuche, in eine Hive-Bucket-sortierte Tabelle einzufügen und mit einer Negative Array Size-Ausnahme, die vom Reducer ausgelöst wurde, zu hängen. Bitte finden Sie unten Stapelverfolgung.Negative Array Size Exception beim Einfügen in Hive Bucketed Tabelle

Error: org.apache.hadoop.mapreduce.task.reduce.Shuffle$ShuffleError: error in shuffle in fetcher#3 
    at org.apache.hadoop.mapreduce.task.reduce.Shuffle.run(Shuffle.java:134) 
    at org.apache.hadoop.mapred.ReduceTask.run(ReduceTask.java:376) 
    at org.apache.hadoop.mapred.YarnChild$2.run(YarnChild.java:164) 
    at java.security.AccessController.doPrivileged(Native Method) 
    at javax.security.auth.Subject.doAs(Subject.java:415) 
    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1693) 
    at org.apache.hadoop.mapred.YarnChild.main(YarnChild.java:158) 
Caused by: java.lang.NegativeArraySizeException 
    at org.apache.hadoop.io.BoundedByteArrayOutputStream.<init>(BoundedByteArrayOutputStream.java:56) 
    at org.apache.hadoop.io.BoundedByteArrayOutputStream.<init>(BoundedByteArrayOutputStream.java:46) 
    at org.apache.hadoop.mapreduce.task.reduce.InMemoryMapOutput.<init>(InMemoryMapOutput.java:63) 
    at org.apache.hadoop.mapreduce.task.reduce.MergeManagerImpl.unconditionalReserve(MergeManagerImpl.java:305) 
    at org.apache.hadoop.mapreduce.task.reduce.MergeManagerImpl.reserve(MergeManagerImpl.java:295) 
    at org.apache.hadoop.mapreduce.task.reduce.Fetcher.copyMapOutput(Fetcher.java:514) 
    at org.apache.hadoop.mapreduce.task.reduce.Fetcher.copyFromHost(Fetcher.java:336) 
    at org.apache.hadoop.mapreduce.task.reduce.Fetcher.run(Fetcher.java:193) 

Und meine Tabelle DDL ist (nur eine Teilmenge der Spalten zur besseren Lesbarkeit zeigt. Die tatsächlichen DDL 100 Spalten)

CREATE TABLE clustered_sorted_orc(conv_type string, 
            multi_dim_id int, 
            multi_key_id int, 
            advertiser_id bigint, 
            buy_id bigint, 
            day timestamp 
PARTITIONED BY(job_instance_id int) 
CLUSTERED BY(conv_type) SORTED BY (day) INTO 8 BUCKETS 
STORED AS ORC; 

Insert-Anweisung ist

FROM not_clustered_orc 
INSERT OVERWRITE TABLE clustered_sorted_orc PARTITION(job_instance_id) 
SELECT conv_type ,multi_dim_id ,multi_key_id ,advertiser_id,buy_id ,day, job_instance_id 

hive Eigenschaften Nach sind gesetzt

set hive.enforce.bucketing = true; 
set hive.exec.dynamic.partition.mode=nonstrict; 

Dies ist ein Protokoll-Snippet von MergerManagerImpl, das ioSortFactor, mergeThreshold usw. angibt, wenn es hilft.

2016-06-30 05:57:20,518 INFO [main] org.apache.hadoop.mapreduce.task.reduce.MergeManagerImpl: MergerManager: memoryLimit=12828540928, maxSingleShuffleLimit=3207135232, mergeThreshold=8466837504, ioSortFactor=64, memToMemMergeOutputsThreshold=64 

Ich verwende CDH 5.7.1, Hive1.1.0, Hadoop 2.6.0. Hat jemand schon einmal mit einem ähnlichen Problem konfrontiert? Jede Hilfe wird wirklich geschätzt.

+0

Einstellung, wenn es einmal tun Sortierung bei Einsatz Zeit. –

Antwort

1

Ich habe es nach der Arbeit

hive.optimize.sort.dynamic.partition=true 
+0

Könnten Sie bitte mit mehr Details Ihre Antwort erarbeiten. Ich habe das gleiche Problem, aber mit Apache Crunch. – dbustosp

Verwandte Themen