Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Exception in thread "main" java.lang.UnsatisfiedLinkError: org.apache.hadoop.io.nativeio.NativeIO$Windows.access0(Ljava/lang/String;I)Z

Tags:

java

hadoop

trying to run MR program version(2.7) in windows 7 64 bit in eclipse while running the above exception occurring . I verified that using 64 bit 1.8 java version and observed that all the hadoop daemons are running.

Any suggestions highly appreciated

like image 620
sukumar konduru Avatar asked Jan 25 '17 11:01

sukumar konduru


People also ask

What is Java Lang UnsatisfiedLinkError?

The UnsatisfiedLinkError is a sub-class of the LinkageError class and denotes that the Java Virtual Machine (JVM) cannot find an appropriate native-language definition of a method declared as native . This error exists since the first release of Java (1.0) and is thrown only at runtime.


4 Answers

After putting haddop.dll and winutils in hadoop/bin folder and adding the folder of hadoop to PATH, we also need to put hadoop.dll into the C:\Windows\System32 folder

like image 26
JasonWayne Avatar answered Oct 19 '22 18:10

JasonWayne


In addition to other solutions, Please download winutil.exe and hadoop.dll and add to $HADOOP_HOME/bin. It works for me.

https://github.com/steveloughran/winutils/tree/master/hadoop-2.7.1/bin

Note: I'm using hadoop-2.7.3 version enter image description here

enter image description here enter image description here

like image 76
Thirupathi Chavati Avatar answered Oct 19 '22 19:10

Thirupathi Chavati


This issue occurred to me and the cause was I forgot to append %HADOOP_HOME%/bin to PATH in my environment variables.

like image 23
Julius Delfino Avatar answered Oct 19 '22 20:10

Julius Delfino


In my case I was having this issue when running unit tests on local machine after upgrading dependencies to CDH6. I already had HADOOP_HOME and PATH variables configured properly but I had to copy the hadoop.ddl to C:\Windows\System32 as suggested in the other answer.

like image 7
OsvaldoP Avatar answered Oct 19 '22 18:10

OsvaldoP