Hi Vladimir Amirov,
Welcome to Microsoft Q&A, thanks for posting your query.
To resolve the issue where Get-AzStorageFileHandle
is not showing files paths for open files on your Azure file share, you can follow the below steps:
- Check your Azure PowerShell module is up to date. Sometimes, issues and missing features or bugs are resolved in the latest versions.
Update-Module -Name Az
- One of the most common reasons for not seeing file paths is due to access permissions. Make sure that your azure account has the necessary permissions to view manage files handles. You need to ensure that the account has the appropriate roles such as Storage Account Contributor.
- Try using the command with a storage context to see if it retrieves more detailed information.
# Create a context for your storage account
$storageAccount = Get-AzStorageAccount -ResourceGroupName "yourResourceGroupName" -Name "yourStorageAccountName"
$context = $storageAccount.Context
# Retrieve file handles with context
Get-AzStorageFileHandle -Context $context -ShareName "mysharename" -Recursive | Sort-Object ClientIpAddress, OpenTime
- You can also verify open file handles directly through the Azure portal. Navigate to your Storage Account > File Shares. Choose your file share and go to Open handles verify if the paths are visible there.
Please let us know if you have any further queries. I’m happy to assist you further.
Please do not forget to "Accept the answer” and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.