標籤:使用windows power shell建立ds13伺服器
使用windows power shell建立DS13伺服器
web頁面先建立:
虛擬雲端服務(ServiceName): zampdmp-ds
虛擬網路(SLB/VPC Operations and Maintenance SystemName): az-dmpnetwork
建立DS13,附件800G磁碟powershell命令如下:
New-AzureStorageAccount -StorageAccountName "zampdmpds" -Location "China East" -Type "Premium_LRS"
set-AzureSubscription -SubscriptionId 6fd78691-51f4-4087-a821-f80c0e4867d8 -CurrentStorageAccountName zampdmpds
$VMImage = get-AzureVMImage -ImageName f1179221e23b4dbb89e39d70e5bc9e72__OpenLogic-CentOS-67-20160415
New-AzureVMConfig -Name ZAMPDMP-20 -InstanceSize Standard_DS14 -ImageName $VMImage.ImageName | Add-AzureProvisioningConfig -Linux -LinuxUser azureuser -Password "AdaG(sVa4A3" | Set-AzureSubNet Subnet-1 | new-azurevm -ServiceName zampdmp-ds -SLB/VPC Operations and Maintenance SystemName az-dmpnetwork -Location "China East"
get-azurevm -Name ZAMPDMP-20 -ServiceName zampdmp-ds | Add-AzureDataDisk -CreateNew -DiskSizeInGB 800 -DiskLabel VerticaSSD01 -lun 0 -HostCaching None | Update-AzureVM
注意:建立的ssd硬碟使用lun 0,從0開始,逐步遞增。
擷取虛擬機器範本檔案命令:
Get-AzureVMImage
Centos6.7 的模板ID: f1179221e23b4dbb89e39d70e5bc9e72__OpenLogic-CentOS-67-20160415
刪除一個空磁碟,可以先附件到一個虛擬機器上,然後刪除整個虛擬機器連帶該磁碟,最後通過下面命令刪除儲存空間
Remove-AzureStorageAccount -StorageAccountName "dmpssdstorage"
本文出自 “梅花香自苦寒來!” 部落格,請務必保留此出處http://daixuan.blog.51cto.com/5426657/1863896
使用windows power shell建立DS13伺服器