Error in Hadoop Mapreduce

0 votes

I am writing my first HDFS command and getting error:

hdfs dfs -cat /home/vinay/script/input.txt
WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
cat: `/home/vinay/script/input.txt': No such file or directory
Apr 19, 2018 in Big Data Hadoop by coldcode
• 2,090 points
1,178 views

1 answer to this question.

0 votes

The file that you are referring here is is in the local directory i.e. /home/vinay/script/input.txt

You need to pass the HDFS uri of the file, or the HDFS file system path.

First go to localhost:50070 in your browser and find the path of the file. If the file is not uploaded to HDFS, use this command to upload the file:

 hdfs dfs -put <local-filesystem-file-path> <path-on-hdfs>

Then you can use the below command to print the content of the file present in HDFS:

hdfs dfs -cat <path-on-hdfs>
answered Apr 19, 2018 by Shubham
• 13,490 points

Related Questions In Big Data Hadoop

0 votes
1 answer

Error running hadoop mapreduce in Python using Hadoop Streaming

Hi As you write mapper and reducer program  ...READ MORE

answered Jan 21, 2020 in Big Data Hadoop by anonymous
2,592 views
0 votes
1 answer
0 votes
1 answer

Getting error in Hadoop Streaming: Type mismatch in Key from Map

In Hadoop streaming you have to customize ...READ MORE

answered Apr 18, 2018 in Big Data Hadoop by coldcode
• 2,090 points
1,289 views
+1 vote
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 11,380 points
11,078 views
+2 votes
11 answers

hadoop fs -put command?

Hi, You can create one directory in HDFS ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by nitinrawat895
• 11,380 points
109,078 views
–1 vote
1 answer

Hadoop dfs -ls command?

In your case there is no difference ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by kurt_cobain
• 9,350 points
4,644 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Getting error in MapReduce job.setInputFormatClass

In old Hadoop API(i.e. below Hadoop 0.20.0), ...READ MORE

answered Apr 15, 2018 in Big Data Hadoop by Shubham
• 13,490 points
2,090 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP