I am trying to create a simple map/reducer job for hdinsight but I am having trouble with connecting job in local hdinsight hadoop cluster to local azure storage emulator via ASV://

Sample code like this:

var hadoop = Hadoop.Connect();
HadoopJobConfiguration config = new HadoopJobConfiguration();
config.InputPath = @"asv://127.0.0.1:10000/devstoreaccount1/testcontainer/input";
config.OutputFolder = "asv://127.0.0.1:10000/devstoreaccount1/testcontainer/output";
hadoop.MapReduceJob.Execute<Mapper1>(config);

or

var hadoop = Hadoop.Connect();
HadoopJobConfiguration config = new HadoopJobConfiguration();
config.InputPath = @"asv://testcontainer/input";
config.OutputFolder = "asv://testcontainer/output";
hadoop.MapReduceJob.Execute<Mapper1>(config);

where testcontainer is an existing container in local emulator's blob storage. When running this code I get a StreamingException "Process failed ('Streaming Job Failed!')"

And see the following error in console output:

packageJobJar: [] [/C:/Hadoop/hadoop-1.1.0-SNAPSHOT/lib/hadoop-streaming.jar] C: \Users\user1\AppData\Local\Temp\1\streamjob6525516867576872971.jar tmpDir=null 
13/08/26 12:30:51 INFO util.NativeCodeLoader: Loaded the native-hadoop library 
13/08/26 12:30:51 WARN snappy.LoadSnappy: Snappy native library not loaded 
13/08/26 12:30:51 INFO mapred.JobClient: Cleaning up the staging area hdfs://loc alhost:8020/hadoop/hdfs/tmp/mapred/staging/user1/.staging/job_201308221229_0010 
13/08/26 12:30:51 ERROR security.UserGroupInformation: PriviledgedActionExceptio n as:user1 cause:org.apache.hadoop.mapred.InvalidInputException: Input path does  not exist: hdfs:/devstoreaccount1/testcontainer/input 
13/08/26 12:30:51 ERROR streaming.StreamJob: Error Launching job : Input path do es not exist: hdfs:/devstoreaccount1/testcontainer/input 

Streaming Command Failed!

Any hints?

1

There are 1 answers

0
abedon On

You can use one of the following paths to access local storage emulator.

wasb://testcontainer@storageemulator/input

wasb:///input (when storage emulator is set as the default File System)

asv:///input (when storage emulator is set as the default File System, asv is obsolete, not recommended)