2015-01-01 24 views
5

Używam impala z flume jako filestream.Impala - plik nie znaleziono błąd

Problemem jest koryta jest dodanie tymczasowe pliki z rozszerzeniem .tmp, a następnie, gdy są one usunięte zapytań impala są niepowodzeniem z następującym komunikatem:

Backend 0: Nie udało się otworzyć pliku HDFS HDFS://localhost:8020/user/hive/../FlumeData.1420040201733.tmp Error (2): nie ma takiego pliku lub katalogu

Jak mogę dokonać impala zignorować ten tmp pliki lub koryta nie pisać je lub zapisać w innym katalogu?

konfiguracja Flume:

### Agent2 - Avro Source and File Channel, hdfs Sink ### 
# Name the components on this agent 
Agent2.sources = avro-source 
Agent2.channels = file-channel 
Agent2.sinks = hdfs-sink 

# Describe/configure Source 
Agent2.sources.avro-source.type = avro 
Agent2.sources.avro-source.hostname = 0.0.0.0 
Agent2.sources.avro-source.port = 11111 
Agent2.sources.avro-source.bind = 0.0.0.0 

# Describe the sink 
Agent2.sinks.hdfs-sink.type = hdfs 
Agent2.sinks.hdfs-sink.hdfs.path = hdfs://localhost:8020/user/hive/table/ 
Agent2.sinks.hdfs-sink.hdfs.rollInterval = 0 
Agent2.sinks.hdfs-sink.hdfs.rollCount = 10000 
Agent2.sinks.hdfs-sink.hdfs.fileType = DataStream 
#Use a channel which buffers events in file 
Agent2.channels.file-channel.type = file 
Agent2.channels.file-channel.checkpointDir = /home/ubutnu/flume/checkpoint/ 
Agent2.channels.file-channel.dataDirs = /home/ubuntu/flume/data/ 

# Bind the source and sink to the channel 
Agent2.sources.avro-source.channels = file-channel 
Agent2.sinks.hdfs-sink.channel = file-channel 
+0

czy możesz spróbować unieważnić metadane i spróbować ponownie zapytać? –

+0

Robię to - ale pliki aktualizują się między obydwoma zapytaniami. –

+0

Jaka jest twoja konfiguracja Flume? – kichik

Odpowiedz

3

miałem ten problem raz.

Ulepszono mop i flume, a problem został rozwiązany. (od cloudera hadoop cdh-5.2 do cdh-5.3)

Spróbuj ulepszyć - hadoop, flume lub impala.