{"id":324,"date":"2021-10-23T18:08:33","date_gmt":"2021-10-23T17:08:33","guid":{"rendered":"http:\/\/192.168.8.123\/?p=324"},"modified":"2022-02-11T11:21:38","modified_gmt":"2022-02-11T11:21:38","slug":"create-and-connect-to-an-azure-files-share","status":"publish","type":"post","link":"https:\/\/exceedthecloud.com\/?p=324","title":{"rendered":"Create and connect to an Azure Files share"},"content":{"rendered":"\n<p>Azure Files offers fully managed file shares in the cloud that are accessible via the industry standard Server Message Block (SMB) protocol or Network File System (NFS) protocol. Azure Files file shares can be mounted concurrently by cloud or on-premises deployments. SMB Azure file shares are accessible from Windows, Linux, and macOS clients<\/p>\n\n\n\n<p>There are two steps to creating Azure file shares. The first step is to create a storage account by choosing the correct options. The second step involves creating the file shares themselves.<\/p>\n\n\n\n<p>In this Lab, you\u2019ll see how to use Azure CLI commands to create the storage account you need. You\u2019ll learn how to authenticate with Azure and persist credentials to allow the company\u2019s satellite offices to maintain connections to the file shares.<\/p>\n\n\n\n<p>Prerequisites for this labs :&nbsp;<a rel=\"noreferrer noopener\" href=\"https:\/\/azure.microsoft.com\/en-us\/free\/\" target=\"_blank\">Azure Account<\/a><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Create a resource group to host your resources<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>New-AzResourceGroup -Name rg-exceed13102021 -Location \"East US\"<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img01-2.png\" alt=\"\"\/><\/figure>\n\n\n\n<p><strong>Create a storage account with the Azure CLI<\/strong><\/p>\n\n\n\n<p>Note: The chosen storage account name must be unique and not already taken<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>az storage account create --name saexceed13102021 --resource-group rg-exceed13102021 --sku Standard_GRS<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img02-2.png\" alt=\"\"\/><\/figure>\n\n\n\n<p>Get the storage account key<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img03-2-1024x655.png\" alt=\"\"\/><\/figure>\n\n\n\n<p>Click on Show Keys and copy the key<\/p>\n\n\n\n<p><strong>Create a file share<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>az storage share create --account-name saexceed13102021 --account-key ## --name fsexceed13102021<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img04-2-1024x70.png\" alt=\"\"\/><\/figure>\n\n\n\n<p>The only required argument to this command is&nbsp;\u2013name, but it won\u2019t enable you to create a share on its own. You also need to provide the storage account information. There are two ways you can provide the information to the command:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>By using the&nbsp;\u2013account-name&nbsp;and either an&nbsp;\u2013account-key&nbsp;or a&nbsp;\u2013sas-token&nbsp;argument.<\/li><li>By using a storage account connection string with&nbsp;\u2013connection-string.<\/li><\/ul>\n\n\n\n<p>There are interesting optional arguments that you might find useful in some situations. The first argument controls the size of the share in gigabytes. If you need this restriction, use the&nbsp;\u2013quota&nbsp;argument. The second argument lets you control the timeout for calls to the service in seconds with&nbsp;\u2013timeout.<\/p>\n\n\n\n<p>The defaults for these arguments are acceptable in our scenario. So, the full command takes the following form:<\/p>\n\n\n\n<p><strong>Connect to an Azure file share with SMB<\/strong><\/p>\n\n\n\n<p>With the Azure file share created, you connect to it from a Windows, Linux, or macOS computer. There are guides for each operating system online, and links to them are in the summary Lab. This module assumes you\u2019re going to be working with Windows machines.<\/p>\n\n\n\n<p>The Azure portal makes it easy to connect to your new share by providing the PowerShell commands to run.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img05-2-1024x486.png\" alt=\"\"\/><\/figure>\n\n\n\n<p><strong>Create a VM and connect with RDP protocol<\/strong><\/p>\n\n\n\n<p>Create a Windows Server VM to simulate an on-premises machine running in the finance company\u2019s datacenter or branch office.<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Using Cloud Shell, create a Windows VM with the Azure CLI. When you\u2019re prompted for a password, enter a complex password of your choice, and note it for reference later.<\/li><\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>az vm create --resource-group rg-exceed13102021 --name 2019FileServer --image Win2019Datacenter --admin-username azureuser<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img06-1-1024x171.png\" alt=\"\"\/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>When the virtual machine has been created, sign in to the&nbsp;<a href=\"https:\/\/portal.azure.com\/learn.docs.microsoft.com\">Azure portal<\/a>&nbsp;with the account you used to activate the sandbox.<\/li><li>On the home page, under&nbsp;<strong>All services<\/strong>, select&nbsp;<strong>Virtual machines<\/strong>, and then select the&nbsp;<strong>2019FileServer<\/strong>&nbsp;VM you created in step 1 of this task. The&nbsp;<strong>2019 FileServer<\/strong>&nbsp;Virtual machine pane appears.<\/li><li>On the command bar, select&nbsp;<strong>Connect<\/strong>&nbsp;&gt;&nbsp;<strong>RDP<\/strong>, and then select&nbsp;<strong>Download RDP File<\/strong>.<\/li><li>When the RDP file has downloaded, select it to run. In the&nbsp;<strong>Remote Desktop Connection<\/strong>&nbsp;dialog box, select&nbsp;<strong>Connect<\/strong>.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img07-1-1024x424.png\" alt=\"\"\/><\/figure>\n\n\n\n<p>On the Windows Security&nbsp;<strong>Enter your credentials<\/strong>&nbsp;dialog box, select&nbsp;<strong>More choices<\/strong>, and then scroll down and select&nbsp;<strong>Use a different account<\/strong>. In the&nbsp;<strong>Email address<\/strong>&nbsp;field, enter&nbsp;<em>azureuser<\/em>, in the&nbsp;<strong>Password<\/strong>&nbsp;field, enter the password you created earlier, and then select&nbsp;<strong>OK<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img08-1-1024x651.png\" alt=\"\"\/><\/figure>\n\n\n\n<p>If you\u2019re prompted to verify the remote connection, select&nbsp;<strong>Yes<\/strong>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"map-drives-to-the-azure-file-shares\"><strong>Map drives to the Azure file shares<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>In the Azure portal, in the top&nbsp;<em>Search resources, services, and docs<\/em>&nbsp;search box, search for and select&nbsp;<strong>Storage accounts<\/strong>.<\/li><li>Select the storage account that you created, which should be named&nbsp;<strong>saexceed13102021<\/strong>&nbsp;followed by random numbers. That storage account pane appears.<\/li><li>In the middle menu pane, under&nbsp;<strong>Data storage<\/strong>, select&nbsp;<strong>File shares<\/strong>.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img09-1-1024x536.png\" alt=\"\"\/><\/figure>\n\n\n\n<p>The&nbsp;<strong>File shares<\/strong>&nbsp;pane for your storage account appears with two file shares.<\/p>\n\n\n\n<p>In the file shares list, select&nbsp;<strong>fsexceed13102021<\/strong>. The&nbsp;<strong>fsexceed13102021<\/strong>file share pane appears.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"528\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img10-1-6-1024x528.png\" alt=\"\" class=\"wp-image-2079\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img10-1-6-1024x528.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img10-1-6-300x155.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img10-1-6-768x396.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img10-1-6-1536x791.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img10-1-6.png 1551w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>In the command bar, select&nbsp;<strong>Connect<\/strong>. The&nbsp;<strong>Connect<\/strong>&nbsp;pane appears.<\/li><li>In the&nbsp;<strong>Drive letter<\/strong>&nbsp;dropdown list, select the&nbsp;<strong>F<\/strong>.<\/li><li>Under&nbsp;<strong>Authentication method<\/strong>, ensure&nbsp;<strong>Storage account key<\/strong>&nbsp;is selected, and then copy the PowerShell script that appears in the text box.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"488\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img11-1-6-1024x488.png\" alt=\"\" class=\"wp-image-2083\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img11-1-6-1024x488.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img11-1-6-300x143.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img11-1-6-768x366.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img11-1-6-1536x731.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img11-1-6.png 1840w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>On your virtual machine, in the system tray, select&nbsp;<strong>Start<\/strong>, scroll to&nbsp;<strong>Windows PowerShell (Admin)<\/strong>, or if you don\u2019t see&nbsp;<strong>(Admin)<\/strong>, then right-click&nbsp;<strong>Windows PowerShell<\/strong>&nbsp;and select&nbsp;<strong>Run as Administrator<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img12-1-6-1024x576.png\" alt=\"\" class=\"wp-image-2087\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img12-1-6-1024x576.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img12-1-6-300x169.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img12-1-6-768x432.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img12-1-6-1536x864.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img12-1-6.png 1600w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>In the PowerShell console title bar, right-click the PowerShell icon, and select&nbsp;<strong>Properties<\/strong>. On the&nbsp;<strong>Options<\/strong>&nbsp;tab, ensure that&nbsp;<strong>Use Ctrl+Shift+C\/V as Copy\/Paste<\/strong>&nbsp;is selected, and then select&nbsp;<strong>OK<\/strong>. Now you can use accelerator keys&nbsp;<kbd>Ctrl+Shift+V<\/kbd>&nbsp;to paste content into your VM PowerShell console.<\/li><li>At the command prompt in the PowerShell console, paste the script you copied from the Azure portal, and press&nbsp;<kbd>Enter<\/kbd>.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"359\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img13-1-6-1024x359.png\" alt=\"\" class=\"wp-image-2091\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img13-1-6-1024x359.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img13-1-6-300x105.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img13-1-6-768x269.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img13-1-6-1536x539.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img13-1-6.png 1660w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>In the Azure portal, go back to the&nbsp;<strong>File shares<\/strong>&nbsp;pane, and select&nbsp;<strong>reportexceed13102021<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"489\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img14-1-5-1024x489.png\" alt=\"\" class=\"wp-image-2095\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img14-1-5-1024x489.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img14-1-5-300x143.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img14-1-5-768x367.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img14-1-5-1536x733.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img14-1-5.png 1841w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>On the command bar, select&nbsp;<strong>Connect<\/strong>. The&nbsp;<strong>Connect<\/strong>&nbsp;reports pane appears.<\/li><li>In the&nbsp;<strong>Drive letter<\/strong>&nbsp;dropdown list, select the&nbsp;<strong>G<\/strong>.<\/li><li>Under&nbsp;<strong>Authentication method<\/strong>, ensure&nbsp;<strong>Storage account key<\/strong>&nbsp;is selected, and then copy the PowerShell script that appears in the text box.<\/li><li>In the RDP PowerShell window, paste&nbsp;<kbd>Ctrl+Shift+V<\/kbd>&nbsp;the script you copied, and then press&nbsp;<kbd>Enter<\/kbd>.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"274\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img15-8-1024x274.png\" alt=\"\" class=\"wp-image-2097\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img15-8-1024x274.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img15-8-300x80.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img15-8-768x206.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img15-8-1536x412.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img15-8.png 1668w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"test-the-mounted-drive\"><strong>Test the mounted drive<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>In the RDP connection, open File Explorer, and select&nbsp;<strong>This PC<\/strong>.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"577\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img16-8-1024x577.png\" alt=\"\" class=\"wp-image-2099\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img16-8-1024x577.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img16-8-300x169.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img16-8-768x433.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img16-8.png 1124w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>Select the&nbsp;<em>fsexceed13102021<\/em>&nbsp;drive named&nbsp;<strong>F<\/strong>.<\/li><li>Right-click the main window, and select&nbsp;<strong>New<\/strong>&nbsp;&gt;&nbsp;<strong>Text Document<\/strong>.<\/li><li>Save the file, naming&nbsp;<strong>test upload<\/strong>.<\/li><li>Return to the Azure portal in your browser, go back to the&nbsp;<strong>File shares<\/strong>&nbsp;pane, and select&nbsp;<strong>fsexceed13102021<\/strong>. You should see the file in the portal.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"266\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img17-8-1024x266.png\" alt=\"\" class=\"wp-image-2101\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img17-8-1024x266.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img17-8-300x78.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img17-8-768x200.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img17-8-1536x399.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img17-8.png 1863w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"secure-access-to-files-stored-in-azure-files\"><strong>Secure access to files stored in Azure Files<\/strong><\/h2>\n\n\n\n<p>In this Lab, you\u2019ll investigate ways to secure access to Azure file shares from on-premises machines. You\u2019ll check to ensure that data is encrypted in transit to Azure. With secure access in place, you\u2019ll look at how the finance company can use Azure AD to control access to the file shares. As an extra level of protection for the shared files, you\u2019ll also explore the snapshot feature.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"enable-secure-file-transfer\"><strong>Enable secure file transfer<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>In the Azure portal you should still have open from the previous exercise, select the storage account you created, named&nbsp;<strong>saexceed13102021<\/strong>.<\/li><li>In the middle menu pane, under&nbsp;<strong>Settings<\/strong>, select&nbsp;<strong>Configuration<\/strong>. The&nbsp;<strong>Configuration<\/strong>&nbsp;pane appears for your storage account.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"495\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img18-7-1024x495.png\" alt=\"\" class=\"wp-image-2103\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img18-7-1024x495.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img18-7-300x145.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img18-7-768x371.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img18-7.png 1522w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Ensure that&nbsp;<strong>Secure transfer required<\/strong>&nbsp;is enabled.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"add-a-firewall-rule-to-restrict-access-to-an-ip-address\"><strong>Add a firewall rule to restrict access to an IP address<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>In the middle menu pane, under&nbsp;<strong>Security + networking<\/strong>, select&nbsp;<strong>Networking<\/strong>. The&nbsp;<strong>Networking<\/strong>&nbsp;pane appears for your storage account with the&nbsp;<strong>Firewalls and virtual networks<\/strong>&nbsp;tab highlighted.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"377\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img19-7-1024x377.png\" alt=\"\" class=\"wp-image-2105\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img19-7-1024x377.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img19-7-300x110.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img19-7-768x283.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img19-7.png 1203w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>Under&nbsp;<strong>Allow access from<\/strong>, select&nbsp;<strong>Selected networks<\/strong>.<\/li><li>Under&nbsp;<strong>Firewall<\/strong>, in the address range input, note the public IP address of your VM. You can see this address in the title bar of the remote desktop connection.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"571\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img20-7-1024x571.png\" alt=\"\" class=\"wp-image-2107\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img20-7-1024x571.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img20-7-300x167.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img20-7-768x428.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img20-7.png 1535w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>On the top menu bar, select&nbsp;<strong>Save<\/strong>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"test-security-of-the-file-share\"><strong>Test security of the file share<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>In the middle menu pane, under&nbsp;<strong>Security + networking<\/strong>, select&nbsp;<strong>Networking<\/strong>. The&nbsp;<strong>Firewalls and virtual networks<\/strong>&nbsp;tab is highlighted.<\/li><li>Select the&nbsp;<strong>Add your client IP address<\/strong>&nbsp;check box, and in the top menu bar, select&nbsp;<strong>Save<\/strong>.<\/li><li>In the middle menu pane, select&nbsp;<strong>Overview<\/strong>, and under&nbsp;<strong>Data storage<\/strong>, select&nbsp;<strong>File shares<\/strong>.<\/li><li>Select the&nbsp;<strong>fsexceed13102021<\/strong>&nbsp;file share. The&nbsp;<strong>fsexceed13102021<\/strong>&nbsp; pane appears for your file share. You can now browse the file share in your local browser.<\/li><\/ul>\n\n\n\n<p><strong>&nbsp;Note<\/strong><\/p>\n\n\n\n<p>You might need to go to the reports share because the error page could be cached for the fsexceed13102021 file share.<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Use the browser on your computer to download AzCopy by going to&nbsp;<a href=\"https:\/\/aka.ms\/downloadazcopy-v10-windows\">https:\/\/aka.ms\/downloadazcopy-v10-windows<\/a>.<\/li><li>Connect to your VM by using the remote desktop connection.<\/li><li>Open the file share in the Azure portal, upload the azcopy.exe file so it is available on the VM.<\/li><li>On the VM, drag the file to the desktop for easy use.<\/li><li>Select the&nbsp;<strong>azcopy<\/strong>&nbsp;zip file.<\/li><li>On the menu, select&nbsp;<strong>Compressed Folder Tools<\/strong>, and then select&nbsp;<strong>Extract all<\/strong>.<\/li><li>In the Extract Compressed (Zipped) Folders window, select&nbsp;<strong>Extract<\/strong>.<\/li><li>Select&nbsp;<strong>Start<\/strong>, then select the&nbsp;<strong>Windows PowerShell folder<\/strong>, and then select&nbsp;<strong>Windows PowerShell<\/strong>.<\/li><li>Move to the folder that contains&nbsp;<strong>AzCopy<\/strong>.<\/li><\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>cd C:\\Users\\azureuser\\Downloads\\azcopy_windows_amd64_10.12.2\\azcopy_windows_amd64_10.12.2 <\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"334\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img21-7-1024x334.png\" alt=\"\" class=\"wp-image-2109\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img21-7-1024x334.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img21-7-300x98.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img21-7-768x251.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img21-7.png 1121w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<pre class=\"wp-block-preformatted\">Run AzCopy to copy the files to Azure by first signing in\n\n.\\azcopy.exe login --tenant-id XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"103\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img22-7-1024x103.png\" alt=\"\" class=\"wp-image-2111\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img22-7-1024x103.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img22-7-300x30.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img22-7-768x77.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img22-7.png 1165w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img23-7-1024x576.png\" alt=\"\" class=\"wp-image-2113\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img23-7-1024x576.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img23-7-300x169.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img23-7-768x432.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img23-7.png 1181w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Click on Continue<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"copy-local-files-to-azure\"><strong>Copy local files to Azure<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>Create some local example test files using PowerShell.<\/li><\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>1..100 | % { New-Item -Path F:\\ -Name \"$_.txt\" -Value (Get-Date).toString() -ItemType file}<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"520\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img24-7-1024x520.png\" alt=\"\" class=\"wp-image-2115\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img24-7-1024x520.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img24-7-300x152.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img24-7-768x390.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img24-7.png 1318w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>In the Azure portal you should still have open, select the storage account you previously created, named&nbsp;<strong>fsexceed13102021<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"474\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img25-7-1024x474.png\" alt=\"\" class=\"wp-image-2117\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img25-7-1024x474.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img25-7-300x139.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img25-7-768x355.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img25-7-1536x711.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img25-7.png 1852w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>In the middle menu pane, under&nbsp;<strong>Security + networking<\/strong>, select&nbsp;<strong>Shared access signature<\/strong>.<\/li><li>Select the allowed resource types using the shared access signature<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"583\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img26-7-1024x583.png\" alt=\"\" class=\"wp-image-2119\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img26-7-1024x583.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img26-7-300x171.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img26-7-768x437.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img26-7.png 1519w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>At the bottom of the pane, select&nbsp;<strong>Generate SAS and connection string<\/strong>.<\/li><li>Copy the&nbsp;<strong>File service SAS URL<\/strong>.<\/li><li>Paste the connection string into Notepad, and add a path to the data share. Change the string by adding&nbsp;<code>fsexceed13102021\/<\/code>&nbsp;to the path from:<\/li><\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>https:&#47;&#47;saexceed13102021.file.core.windows.net\/?sv=2020-08-04&amp;ss=bfqt&amp;srt=sco&amp;sp=rwdlacuptfx&amp;se=2021-10-14T16:35:01Z&amp;st=2021-10-14T08:35:01Z&amp;spr=https&amp;sig=%2FGnvOLk7LIJqJ7CK1lCziO5RqL9c9KRw6KLnFY7edcY%3D<\/code><\/pre>\n\n\n\n<p>To<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>https:&#47;&#47;saexceed13102021.file.core.windows.net\/fsexceed13102021\/?sv=2020-08-04&amp;ss=bfqt&amp;srt=sco&amp;sp=rwdlacuptfx&amp;se=2021-10-14T16:35:01Z&amp;st=2021-10-14T08:35:01Z&amp;spr=https&amp;sig=%2FGnvOLk7LIJqJ7CK1lCziO5RqL9c9KRw6KLnFY7edcY%3D<\/code><\/pre>\n\n\n\n<p>Use this new SAS connection string in the AzCopy command to copy the files to Azure. Run this command in the PowerShell window.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"258\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img27-7-1024x258.png\" alt=\"\" class=\"wp-image-2121\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img27-7-1024x258.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img27-7-300x76.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img27-7-768x194.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img27-7.png 1348w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"create-a-share-snapshot\"><strong>Create a share snapshot<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>In the Azure portal you should still have open, select the storage account you previously created, named&nbsp;<strong>saexceed13102021<\/strong>.<\/li><li>In the middle menu pane, under&nbsp;<strong>Data storage<\/strong>, select&nbsp;<strong>File shares<\/strong>. The Storage account&nbsp;<strong>File shares<\/strong>&nbsp;pane appears.<\/li><li>Select the&nbsp;<strong>fsexceed13102021<\/strong>&nbsp;share.<\/li><li>In the&nbsp;<strong>Operations<\/strong>&nbsp;section, select&nbsp;<strong>Snapshots<\/strong>.<\/li><li>Select&nbsp;<strong>Add snapshot<\/strong>, and then select&nbsp;<strong>OK<\/strong>.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"261\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img28-7-1024x261.png\" alt=\"\" class=\"wp-image-2123\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img28-7-1024x261.png 1024w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img28-7-300x77.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img28-7-768x196.png 768w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img28-7-1536x392.png 1536w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img28-7.png 1862w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\"><li>Return to your VM, and open&nbsp;<strong>File Explorer<\/strong>.<\/li><li>Browse to the fsexceed13102021 share mounted on the&nbsp;<strong>F<\/strong>&nbsp;drive, right-click any of the text files, and select&nbsp;<strong>Properties<\/strong>.<\/li><li>In the File properties window, select&nbsp;<strong>Previous Versions<\/strong>, and note the listed snapshots created on the file share.<\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"362\" height=\"473\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img29-7.png\" alt=\"\" class=\"wp-image-2125\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img29-7.png 362w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2022\/02\/img29-7-230x300.png 230w\" sizes=\"auto, (max-width: 362px) 100vw, 362px\" \/><\/figure>\n\n\n\n<p>From here, you can select&nbsp;<strong>Open<\/strong>&nbsp;to open the previous version to browse the files at that snapshot. Otherwise, you can select&nbsp;<strong>Restore<\/strong>&nbsp;to restore files from a snapshot.<\/p>\n\n\n\n<p><strong>Summary<\/strong><\/p>\n\n\n\n<p>In this lab the company you\u2019re working with has moved an application to Azure that generates reports and data exports for users and other systems to consume. They wanted to consolidate the files they produce into a native cloud service. With Azure file shares, the company can continue to use the SMB protocol to access these files securely.<\/p>\n\n\n\n<p>You used Azure storage accounts, and the fully managed cloud shares it provides, to re-create the on-premises file shares used by the company. You then added extra levels of security to these shares to restrict access and create snapshots.<\/p>\n\n\n\n<p>Azure file shares are simpler to use because organizations can continue to use their existing tools. The speed of adoption is fast because Azure provides PowerShell commands that can be deployed to add Azure file shares to Windows machines. Azure file shares are a simple, secure, and resilient way to manage shared files in the cloud.<\/p>\n\n\n\n<p><mark class=\"kt-highlight\"><strong>Reminder<\/strong>: Don\u2019t forget to delete or shutdown all unused Azure resources after your labs for cost saving<\/mark><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Azure Files offers fully managed file shares in the cloud that are accessible via the industry standard Server Message Block (SMB) protocol or Network File System (NFS) protocol. Azure Files file shares can be mounted concurrently by cloud or on-premises &hellip; <a href=\"https:\/\/exceedthecloud.com\/?p=324\">Continued<\/a><\/p>\n","protected":false},"author":1,"featured_media":882,"comment_status":"open","ping_status":"open","sticky":true,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"kt_blocks_editor_width":"","_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[4,24,19],"tags":[8,77,76,79,75,78],"class_list":["post-324","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-practical-labs-series","category-storage-backup-recovery","category-virtual-machines","tag-azure","tag-files-share","tag-nfs","tag-shares","tag-smb","tag-storage"],"aioseo_notices":[],"jetpack_featured_media_url":"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2021\/10\/istockphoto-459878341-170667a.jpg","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts\/324","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=324"}],"version-history":[{"count":3,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts\/324\/revisions"}],"predecessor-version":[{"id":2340,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts\/324\/revisions\/2340"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/media\/882"}],"wp:attachment":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=324"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=324"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=324"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}