Please note that it will take a long time.
$ pip install azure-cli
$ pip install azure
$ az login
$ az account list --all
Pick up a subscription ID you want to use from the above list.
$ az account set --subscription [YOUR SUBSCRIPTION ID]
$ ./deploy.py \
--resource-group chainermn
--location westus2 \
--public-key-file ~/.ssh/id_rsa.pub
python deploy.py \
-k ~/.ssh/id_rsa.pub \
-g chainermn-images \
-s chainermnscripts \
--jumpbox-only
az vm create \
-n vmss-image \
-g chainermn-images \
--image Canonical:UbuntuServer:16.04-LTS:latest \
-l eastus \
--size Standard_NC24r \
--admin-username ubuntu \
--authentication-type ssh \
--ssh-key-value $HOME/.ssh/id_rsa.pub
Login to the VM and run the scripts/setup_vmss_cuda92.sh
.
Then reboot it once, then run:
sudo waagent -deprovision+user -force
Logout and run these commands on your local machine:
az vm deallocate --resource-group chainermn-images --name vmss-image && \
az vm generalize --resource-group chainermn-images --name vmss-image && \
az image create --resource-group chainermn-images --name vmss-image-cuda92 --source vmss-image && \
python utils.py -g chainermn-images delete-vm vmss-image
Login to the jumpbox server and run:
sudo waagent -deprovision+user -force
Then logout, then run these commands from your local machine:
az vm deallocate --resource-group chainermn-images --name jumpbox && \
az vm generalize --resource-group chainermn-images --name jumpbox && \
az image create --resource-group chainermn-images --name jumpbox-image --source jumpbox && \
python utils.py -g chainermn-images delete-vm jumpbox
First, please create a resource group.
az group create -g chainermn-v100 -l eastus
image_id=$(az image show -g chainermn-images -n jumpbox-image --query "id" -o tsv) && \
az vm create \
--image ${image_id} \
--name jumpbox \
--resource-group chainermn-v100 \
--size Standard_DS3_v2 \
--admin-username ubuntu \
--ssh-key-value $HOME/.ssh/id_rsa.pub \
--vnet-name chainer-vnet
image_id=$(az image show -g chainermn-images -n vmss-image-cuda92 --query "id" -o tsv) && \
az vmss create \
--image ${image_id} \
--vm-sku Standard_NC24rs_v3 \
--instance-count 64 \
--lb '' \
--name vmss \
--resource-group chainermn-v100 \
--admin-username ubuntu \
--public-ip-address '' \
--ssh-key-value $HOME/.ssh/id_rsa.pub \
--vnet-name chainer-vnet \
--subnet jumpboxSubnet