add mapred tasks
This commit is contained in:
parent
12399a1d42
commit
dcb6e22a9e
@ -35,7 +35,7 @@ if hadoop_streaming_jar != None:
|
|||||||
args.hadoop_streaming_jar = hadoop_streaming_jar
|
args.hadoop_streaming_jar = hadoop_streaming_jar
|
||||||
|
|
||||||
def hadoop_streaming(nslaves, slave_args):
|
def hadoop_streaming(nslaves, slave_args):
|
||||||
cmd = '%s jar %s -input %s -output %s -mapper \"%s stdin %d %d stdout %s\" -reducer \"/bin/cat\" -file %s' % (args.hadoop_binary, args.hadoop_streaming_jar, args.input, args.output, args.mapper, args.nclusters, args.iterations, ' '.join(slave_args), args.mapper)
|
cmd = '%s jar %s -input %s -output %s -mapper \"%s stdin %d %d stdout %s\" -reducer \"/bin/cat\" -file %s -D mapred.map.tasks=%d' % (args.hadoop_binary, args.hadoop_streaming_jar, args.input, args.output, args.mapper, args.nclusters, args.iterations, ' '.join(slave_args), args.mapper, nslaves)
|
||||||
print cmd
|
print cmd
|
||||||
subprocess.check_call(cmd, shell = True)
|
subprocess.check_call(cmd, shell = True)
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user