FAQ
Hi all,



I have a 50 node cluster and I am trying to write some logs of size 1GB
each into hdfs. I need to write them in temporal fashion say for every
15 mins worth of data, I am closing previously opened file and creating
a new file. The snippet of code is

if(<some condition>)

{

if(out != null)

{

out.close();

}

String outFileStr = outputDir+ File.separator + outDate +
File.separator + outFileSuffix + "." + outputMinute;

System.out.println("Creating outFileStr:"+ outFileStr);

Path outFile = new Path(outFileStr);

out = fs.create(outFile); //It throws exception here saying
Already Being Created

}



When I run this code, I am getting Intermittent "Already Being Created
Exceptions". I am not having any threads and this code is running
sequentially. I went thru the previous mailing list posts but couldn't
get much information. Can anyone please tell me why this is happening
and how to avoid this?



Thanks

Pallavi

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 1 | next ›
Discussion Overview
groupcommon-user @
categorieshadoop
postedMay 28, '09 at 7:01a
activeMay 28, '09 at 7:01a
posts1
users1
websitehadoop.apache.org...
irc#hadoop

1 user in discussion

Palleti, Pallavi: 1 post

People

Translate

site design / logo © 2022 Grokbase