Exercise - Configure network access has an incorrect commands in

C R 25 Reputation points
2023-06-08T14:37:03.7566667+00:00

IT has me run the following commands against the previously running VM:

IPADDRESS="$(az vm list-ip-addresses \
  --resource-group learn-1b8b498d-3dff-4e2d-b4bc-f8a67d50d5e9 \
  --name my-vm \
  --query "[].virtualMachine.network.publicIpAddresses[*].ipAddress" \
  --output tsv)"

Then run:

curl --connect-timeout 5 http://$IPADDRESS

The exercise states that I should be getting the following error:

curl: (28) Connection timed out after 5001 milliseconds

But I get this error instead:

curl: (3) URL using bad/illegal format or missing URL

Which tells me that possibly there is something wrong with one of the values on the first command that sets the IPADDRESS variable?

Can someone tell me what is wrong?

Azure Training
Azure Training
Azure: A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.Training: Instruction to develop new skills.
1,568 questions
0 comments No comments
{count} votes

Accepted answer
  1. kobulloc-MSFT 26,246 Reputation points Microsoft Employee
    2023-06-08T15:26:52.73+00:00

    Hello, @C R !

    Where am I seeing this?

    Why am I getting a URL using bad/illegal format or missing URL error?

    Usually this is an error due to Task 1, step 1 where you set the IPADDRESS as you noted above which often fails as a result of the VM from unit 3 Exercise - Create an Azure Virtual Machine expiring after an hour. If it's been more than an hour since you completed unit 3, go back and complete that before continuing this exercise. If not, let us know so we can continue to troubleshoot this.


    I hope this has been helpful! Please take a moment to accept answers as this helps increase visibility of this question for other members of the Microsoft Q&A community. If you are still running into issues, let us know in the comments. Thank you for helping to improve Microsoft Q&A!

    User's image

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.