How can I download azure vhd with powershell to local machine?
I read the document, but I can't find the blob url like "https://XXX.blob.core.windows.net/vhds/XXX.vhd"
Anybody know that?
Thanks
How can I download azure vhd with powershell to local machine?
I read the document, but I can't find the blob url like "https://XXX.blob.core.windows.net/vhds/XXX.vhd"
Anybody know that?
Thanks
https://storage-account-name.blob.core.windows.net/container-name/vhd-name.vhd
You can also find the URL in Azure Portal. Open your storage account, go into the container and click the VHD you want. You will see "URL" in "Blob properties" blade.
You can use Save-AzureVhd cmdlet to download the vhd file to local machine.
The Save-AzureVhd cmdlet enables download of .vhd images from a blob where they are stored to a file. It has parameters to configure the download process by specifying the number of downloader threads that are used or overwriting the file which already exists in the specified file path.
Save-AzureVhd does not do any VHD format conversion and the blob is downloaded as it is.
Example PowerShell cmdlets:
To get the exact URL, Login to Azure Portal, Select Storage Account and the vhd file, then copy the path.
You can also use Azure Storage Explorer to download the vhd file easily.
According to your description, your VM uses managed disk not unmanaged disk. So, you could not find the VHD file in storage account. More information about managed disk please refer to this link.
If you want to download the VHD in managed disk, you should copy it to a storage account first.
Then, you could use
Save-AzureVhd
or Azcopy to download the VHD to your local.Please refer to the similar question.
Try this.
Download, install, login and then browse to your container, select your .vhd and click download.