0
0
Azurecloud~10 mins

File shares (Azure Files) - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to create an Azure file share using Azure CLI.

Azure
az storage share create --name [1] --account-name mystorageaccount
Drag options to blanks, or click blank then click option'
Amyblob
Bmycontainer
Cmyfileshare
Dmydisk
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'mycontainer' which is for blob containers, not file shares.
Using 'myblob' which is for blobs, not file shares.
2fill in blank
medium

Complete the code to mount an Azure file share on a Linux machine using SMB protocol.

Azure
sudo mount -t cifs //mystorageaccount.file.core.windows.net/[1] /mnt/myfileshare -o vers=3.0,username=mystorageaccount,password=mypassword,dir_mode=0777,file_mode=0777,serverino
Drag options to blanks, or click blank then click option'
Amyfileshare
Bmycontainer
Cmyblob
Dmydisk
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'mycontainer' which is for blob storage.
Using 'myblob' which is not a file share.
3fill in blank
hard

Fix the error in the Azure CLI command to upload a file to an Azure file share.

Azure
az storage file upload --share-name myfileshare --source ./localfile.txt --path [1] --account-name mystorageaccount
Drag options to blanks, or click blank then click option'
Amyblob
Bmyfileshare
Cmycontainer
DremoteFile.txt
Attempts:
3 left
💡 Hint
Common Mistakes
Using the share name as the path.
Using container or blob names instead of a file name.
4fill in blank
hard

Fill both blanks to create a file share and set its quota to 100 GB using Azure CLI.

Azure
az storage share create --name [1] --account-name mystorageaccount --quota [2]
Drag options to blanks, or click blank then click option'
Aprojectfiles
B50
C100
Dbackupshare
Attempts:
3 left
💡 Hint
Common Mistakes
Setting quota to a string with units like '100GB' instead of just '100'.
Using a container name instead of a file share name.
5fill in blank
hard

Fill all three blanks to upload a file, set metadata, and list files in an Azure file share using Azure CLI.

Azure
az storage file upload --share-name [1] --source ./data.txt --path data.txt --account-name mystorageaccount && az storage file metadata update --share-name [2] --path data.txt --metadata [3] --account-name mystorageaccount && az storage file list --share-name [1] --account-name mystorageaccount
Drag options to blanks, or click blank then click option'
Adatashare
Cenv=prod
Denv=dev
Attempts:
3 left
💡 Hint
Common Mistakes
Using different share names for upload and metadata update.
Setting metadata with spaces or incorrect format.