Skip to content

Commit 4c8e60a

Browse files
committed
Snap to Az.
1 parent eefa05c commit 4c8e60a

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

articles/storage/files/storage-how-to-use-files-windows.md

+3-5
Original file line numberDiff line numberDiff line change
@@ -35,27 +35,25 @@ You can use Azure file shares on a Windows installation that is running either i
3535
> [!Note]
3636
> We always recommend taking the most recent KB for your version of Windows.
3737
38-
[!INCLUDE [updated-for-az](../../../includes/updated-for-az.md)]
39-
4038
## Prerequisites
4139
* **Storage account name**: To mount an Azure file share, you will need the name of the storage account.
4240

4341
* **Storage account key**: To mount an Azure file share, you will need the primary (or secondary) storage key. SAS keys are not currently supported for mounting.
4442

45-
* **Ensure port 445 is open**: The SMB protocol requires TCP port 445 to be open; connections will fail if port 445 is blocked. You can check to see if your firewall is blocking port 445 with the `Test-NetConnection` cmdlet. The following PowerShell code assumes you have the AzureRM PowerShell module installed, see [Install Azure PowerShell module](/powershell/azure/azurerm/install-azurerm-ps) for more information. Remember to replace `<your-storage-account-name>` and `<your-resoure-group-name>` with the relevant names for your storage account.
43+
* **Ensure port 445 is open**: The SMB protocol requires TCP port 445 to be open; connections will fail if port 445 is blocked. You can check to see if your firewall is blocking port 445 with the `Test-NetConnection` cmdlet. The following PowerShell code assumes you have the AzureRM PowerShell module installed, see [Install Azure PowerShell module](https://docs.microsoft.com/powershell/azure/install-az-ps) for more information. Remember to replace `<your-storage-account-name>` and `<your-resoure-group-name>` with the relevant names for your storage account.
4644

4745
```PowerShell
4846
$resourceGroupName = "<your-resource-group-name>"
4947
$storageAccountName = "<your-storage-account-name>"
5048
5149
# This command requires you to be logged into your Azure account, run Login-AzureRmAccount if you haven't
5250
# already logged in.
53-
$storageAccount = Get-AzureRmStorageAccount -ResourceGroupName $resourceGroupName -Name $storageAccountName
51+
$storageAccount = Get-AzStorageAccount -ResourceGroupName $resourceGroupName -Name $storageAccountName
5452
5553
# The ComputerName, or host, is <storage-account>.file.core.windows.net for Azure Public Regions.
5654
# $storageAccount.Context.FileEndpoint is used because non-Public Azure regions, such as sovereign clouds
5755
# or Azure Stack deployments, will have different hosts for Azure file shares (and other storage resources).
58-
Test-NetConnection -ComputerName [System.Uri]::new($storageAccount.Context.FileEndPoint).Host -Port 445
56+
Test-NetConnection -ComputerName ([System.Uri]::new($storageAccount.Context.FileEndPoint).Host) -Port 445
5957
```
6058
6159
If the connection was successful, you should see the following output:

articles/storage/files/storage-troubleshoot-windows-file-connection-problems.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -63,12 +63,12 @@ To use the `Test-NetConnection` cmdlet, the AzureRM PowerShell module must be in
6363

6464
# This command requires you to be logged into your Azure account, run Login-AzureRmAccount if you haven't
6565
# already logged in.
66-
$storageAccount = Get-AzureRmStorageAccount -ResourceGroupName $resourceGroupName -Name $storageAccountName
66+
$storageAccount = Get-AzStorageAccount -ResourceGroupName $resourceGroupName -Name $storageAccountName
6767

6868
# The ComputerName, or host, is <storage-account>.file.core.windows.net for Azure Public Regions.
6969
# $storageAccount.Context.FileEndpoint is used because non-Public Azure regions, such as sovereign clouds
7070
# or Azure Stack deployments, will have different hosts for Azure file shares (and other storage resources).
71-
Test-NetConnection -ComputerName [System.Uri]::new($storageAccount.Context.FileEndPoint).Host -Port 445
71+
Test-NetConnection -ComputerName ([System.Uri]::new($storageAccount.Context.FileEndPoint).Host) -Port 445
7272

7373

7474
If the connection was successful, you should see the following output:

0 commit comments

Comments
 (0)