1: The cause of the problem, the deployment of hadoop-2.6.4 WINDOW10 operation Hadoop API error, the specific error is that I upload files to HDFs, but also better, previously resolved, not described here, here to say the error from the HDFs download file:
The detailed errors are as follows:
java.lang.NullPointerException at Java.lang.ProcessBuilder.start (Unknown Source) at Org.apache.hadoop.util.Shel L.runcommand (Shell.java:482) at Org.apache.hadoop.util.Shell.run (Shell.java:455) at Org.apache.hadoop.util.shell$shellcommandexecutor.execute (Shell.java:715) at Org.apache.hadoop.util.Shell.execCommand (Shell.java:808) at Org.apache.hadoop.util.Shell.execCommand (Shell.java:791) at Org.apache.hadoop.fs.RawLocalFileSystem.setPermission (Rawlocalfilesystem.java:659) at Org.apache.hadoop.fs.FilterFileSystem.setPermission (Filterfilesystem.java:490) at Org.apache.hadoop.fs.ChecksumFileSystem.create (Checksumfilesystem.java:462) at Org.apache.hadoop.fs.ChecksumFileSystem.create (Checksumfilesystem.java:428) at Org.apache.hadoop.fs.FileSystem.create (Filesystem.java:908) at Org.apache.hadoop.fs.FileSystem.create (Filesystem.java:889) at Org.apache.hadoop.fs.FileSystem.create (Filesystem.java:786) at Org.apache.hadoop.fs.FileUtil.copy (Fileutil.java:365) at Org.apache.hadoop.fs.FileUtil.copy (Fileutil.java:338) at Org.apache.hadoop.fs.FileUtil.copy (Fileutil.java:289) at Org.apache.hadoop.fs.FileSystem.copyToLocalFile (Filesystem.java:1970) at Org.apache.hadoop.fs.FileSystem.copyToLocalFile (Filesystem.java:1939) at Org.apache.hadoop.fs.FileSystem.copyToLocalFile (Filesystem.java:1915) at Com.bie.lesson01.HdfsClientTest.downloadFile (Hdfsclienttest.java: -) at Sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method) at Sun.reflect.NativeMethodAccessorImpl.invoke (Unknown source) at Sun.reflect.DelegatingMethodAccessorImpl.invoke (Unknown source) at Java.lang.reflect.Method.invo Ke (Unknown Source) at org.junit.runners.model.frameworkmethod$1. Runreflectivecall (Frameworkmethod.java: -) at Org.junit.Internal. Runners.model.ReflectiveCallable.run (Reflectivecallable.java: A) at org.junit.runners.model.FrameworkMethod.invokeExplosively (Frameworkmethod.java: -) at Org.junit.Internal. Runners.statements.InvokeMethod.evaluate (Invokemethod.java: -) at Org.junit.Internal. Runners.statements.RunBefores.evaluate (Runbefores.java: -) at Org.junit.runners.ParentRunner.runLeaf (Parentrunner.java:271) at Org.junit.runners.BlockJUnit4ClassRunner.runChild (Blockjunit4classrunner.java: -) at Org.junit.runners.BlockJUnit4ClassRunner.runChild (Blockjunit4classrunner.java: -) at org.junit.runners.parentrunner$3. Run (Parentrunner.java:238) at org.junit.runners.parentrunner$1. Schedule (Parentrunner.java: the) at Org.junit.runners.ParentRunner.runChildren (Parentrunner.java:236) at org.junit.runners.parentrunner.access$ the(Parentrunner.java: -) at org.junit.runners.parentrunner$2. Evaluate (Parentrunner.java:229) at Org.junit.runners.ParentRunner.run (Parentrunner.java:309) at ORG.ECLIPSE.JDT.Internal. Junit4.runner.JUnit4TestReference.run (Junit4testreference.java: the) at ORG.ECLIPSE.JDT.Internal. Junit.runner.TestExecution.run (Testexecution.java: -) at ORG.ECLIPSE.JDT.Internal. junit.runner.RemoteTestRunner.runTests (Remotetestrunner.java:459) at ORG.ECLIPSE.JDT.Internal. junit.runner.RemoteTestRunner.runTests (Remotetestrunner.java:675) at ORG.ECLIPSE.JDT.Internal. Junit.runner.RemoteTestRunner.run (Remotetestrunner.java:382) at ORG.ECLIPSE.JDT.Internal. Junit.runner.RemoteTestRunner.main (Remotetestrunner.java:192)
Indeed, as many netizens say:
Cause: Missing Hadoop.dll or Winutils.exe
Workaround: Which one is missing, and which is added under the local E:\hadoop\hadoop-2.6.4\bin.
And this method, seemingly not so, after personal testing, the workaround is as follows:
Add these two files to your bin directory, and then, with your C:\Windows\System32 plus hadoop.dll, you can resolve the errors that appear above.
And you can do the things you want to do:
Resources: http://download.csdn.net/download/biexiansheng/10132712
Stop more ...
2017-11-25 17:28:05
Java.lang.NullPointerException at Java.lang.ProcessBuilder.start (Unknown Source) at Org.apache.hadoop.util.Shell.runCommand (shell.java:482)