curl/wget cannot run in Azure Batch

1.3k Views Asked by At

I am trying Azure Batch services and followed this example.

I was trying to download a webpage so I changed the task into something like

az batch task create  --task-id mytask  --job-id myjob --command-line "/bin/bash -c 'curl http://www.google.com'"

However, I find this cannot run properly after I add this task. Would anyone kindly help me figure out what is happening? Thanks so much!

1

There are 1 best solutions below

2
On BEST ANSWER

First of all, the link you post is lost and cannot see it. And then you can follow the quickstart of the Azure Batch Service to learn it. With the command curl http://www.google.com I have done the test and the task works well. You can follow the document to download the stdout.txt file to see the output of the task with the command. My test result here:

enter image description here

I also test it on my local ubuntu machine and the same as it. So there is no problem with the quickstart of the Azure Batch Service. Maybe you should wait for a steady state pool when you want to execute the task.