exam questions

Exam 70-740 All Questions

View all questions & answers for the 70-740 exam

Exam 70-740 topic 1 question 102 discussion

Actual exam question from Microsoft's 70-740
Question #: 102
Topic #: 1
[All 70-740 Questions]

You have a Windows container host named Server1.
On Server1, you create a container named Container1.
You need to mount C:\ContainerFiles from Server1 to Container1.
What should you run?

  • A. dockerd --storage-opt dm.mountopt=ContainerFiles
  • B. docker run -it -v c:\ContainerFiles Container1
  • C. dockerd --storage-opt dm.datadev=/c/ContainerFiles
  • D. docker run -it -vc:\ContainerFiles:c:\ContainerFiles Container1
Show Suggested Answer Hide Answer
Suggested Answer: D 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
MrRiver
Highly Voted 5 years, 10 months ago
Seems correct option -V is for mouting volumes and directorys to the host and you need to specificy path on host and path in container separtetd by a ":" docker -v c:\sourceDIRonhost:c:\destDIRincontainer so D is the only option that makes sens
upvoted 9 times
...
JBSPLAT
Most Recent 4 years, 8 months ago
The -v command needs the ":" separated format. If the dest structure doesn't exist, it gets created. See the "Mounting Volumes" section in this Reference: https://blog.sixeyed.com/docker-volumes-on-windows-the-case-of-the-g-drive/#:~:text=In%20a%20Windows%20Docker%20container,assembles%20into%20a%20virtual%20filesystem.
upvoted 2 times
...
Vortex_SA
4 years, 10 months ago
I dont understand why B isnt correct.. Because you can just use C:\ContainerFiles, and if the directory doesnt exist on the container, it creates it...
upvoted 1 times
Vortex_SA
4 years, 10 months ago
You would only use this c:\ContainerFiles:c:\ContainerFiles if the directory already exists on the container.. right
upvoted 1 times
...
...
ITGEEK
5 years, 10 months ago
According to my knowledge answer is correct.
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...