Azure storage File Share storage for Windows Azure

Source: Internet
Author: User

Talk about how to create a file share in an Azure storage account and mount it on an azure VM today. (By the way, the Chinese Azure official documents can be translated, literal translation of global Azure, the technical documentation of the calibration is not good)

We'll start by creating a test VM on Azure, for reference: http://gshao.blog.51cto.com/3512873/1344846

1. Create a storage account on azure;

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M00/71/F0/wKiom1Xa_5OgRvfoAAHXUtwYrto540.jpg "height=" 504 "/>

2. Login Window Azure PowerShell, configure the file sharing;

Input:

Get-azurepublishsettingsfile-environment Azurechinacloud

Mport-azurepublishsettingsfile "****.publishsettings" (path to the configuration file)

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M01/71/F0/wKiom1Xa_5SQror4AAGksW8JSUE425.jpg "height="/>

Configure the Storage account context

$ctx =new-azurestoragecontext–storageaccountname Account-name–storageaccountkey account-key-environment " Azurechinacloud "(Chinese only need to add this, global not)

Create a shared folder

$s =new-azurestorageshare sharefiles (shared folder name)-context $ctx

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M02/71/F0/wKiom1Xa_5aiHoDXAAEu86TcMJQ328.jpg "height="/>

You can use the command to view the case of file:

Input: Get-azurestoragefile–share $s

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M00/71/F0/wKiom1Xa_5fRdbFSAABKUHB4-II308.jpg "height="/>

3. Mount the file share in Azure VM;

In PowerShell input:

Cmdkey/add:<storage-account-name>.file.core.windows.net/user:<storage-account-name>/pass:< Storage-account-key>

This is to save the credentials so that restarting the VM does not cause the file share's login credentials to be lost

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M01/71/F0/wKiom1Xa_5nicy-SAAFGhQf5LdY841.jpg "height="/>

To add a file share store:

net use Z: \ \ <storage-account>.file.core.chinacloudapi.cn\ shared folder name/u:<storage-account> < Storage-account-key>

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M02/71/F0/wKiom1Xa_5vztLwcAAEWBhntLzo722.jpg "height="/>

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M00/71/F0/wKiom1Xa_53ADuQ0AAEVAlWxHG8181.jpg "height=" 257 "/>

Well, guess how much storage space this folder is about. The answer is 5TB.

650) this.width=650; "title=" image "style=" border-top:0px;border-right:0px;background-image:none;border-bottom:0 px;padding-top:0px;padding-left:0px;border-left:0px;margin:0px;padding-right:0px; "border=" 0 "alt=" image "src=" Http://s3.51cto.com/wyfs02/M01/71/F0/wKiom1Xa_5_hLSpnAADRW9wL4mA858.jpg "height=" 288 "/>

But I'm quite surprised that the Chinese version of Azure

(The exact words are

    • share: The file storage share is an SMB 2.1 file share in Azure. All directories and files must be created in the parent share. An account can contain an unlimited number of shares, and a share can store an unlimited number of files until the storage account's capacity limit is reached.

Specifically, you can see China Azure about file Share storage links: http://www.windowsazure.cn/documentation/articles/storage-dotnet-how-to-use-files

This article from "Gs_hao" blog, declined reprint!

Azure storage File Share storage for Windows Azure

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.