SlideShare a Scribd company logo
Automating Azure
VMs with PowerShell
Feschenko Alexander
Senior Software Engineer @ EPAM Systems
Blog: feschenkoalex.blogspot.com
Email: feschenko.alex@gmail.com
Microsoft Azure
Agenda
Intro to Windows Azure PowerShell
Automating Azure virtual machines. Base
cmdlets description
Demo Session. Create and configure virtual
machine. Provision and configure frontend and
backend parts
Migrating applications to the Cloud with Azure
IaaS
Getting started
http://go.microsoft.com/?linkid=9811175
What can you do with PowerShell?
Query, Manage and Configure Virtual Machines across multiple subscriptions,
cloud services and storage accounts.
Provision Fully Configured Virtual Machines
Remote Management
Manage SQL Databases, Configuration, Diagnostics, Deployments, and Azure
assets (Affinity Groups, Storage Accounts, Keys, etc..)
Provisioning VM
>_
VM Gallery
7
A COLLECTION OF PREBUILT IMAGES FOR VARIOUS WORKLOADS
Microsoft Azure
Windows Server 2012 R2 Ubuntu Server 14.04 LTS CentOS 6.5
SUSE Linux
Enterprise Server Oracle Linux 6.4.0.0.0
SQL Server 2014 Standard Oracle Database 11g R2 BizTalk Server 2013 SharePoint Server Farm
Microsoft Dynamics
GP 2013
Zulu 8
SAP HANA
Developer Edition Puppet Enterprise 3.2.3 Barracuda Web Application
Oracle WebLogic
Server 12.1.2
Visual Studio Ultimate 2013
openSUSE 13.1
VM Extensions
• Installable components to customize VM instances
• Enable various DevOps scenarios
• Can be added, updated, disabled or removed at any time
• Managed via portal, PowerShell and Management APIs
8Microsoft Azure
Virtual Machine Management
Supports VM Creation in a Single Cmdlet
Provision With: Endpoints, Data Disks
Configure: Cache Settings for OS/Data Disks and Subnet Names
Setting the current storage account
Get-AzureStorageAccount | Select StorageAccountName
Virtual Machine Discovery
Retrieve Cloud Services
Get-AzureService
Retrieve Virtual Machines for Service
Get-AzureVM -ServiceName $cloudSvcName
Retrieve Status for All VMs in Subsription
Get-AzureService | foreach {
$_ | Get-AzureVM | ft ServiceName, Name,
InstanceStatus
}
Simple VM creation
First Virtual Machine in a NEW Cloud Service (-Location specified)
New-AzureQuickVM -Windows -ServiceName $svc -Name $vm1
-ImageName $wimg -Location $location -Password $pwd
New Virtual Machine in an Existing Cloud Service(no -Location)
New-AzureQuickVM -Windows -ServiceName $svc -Name $vm2
-ImageName $wimg -Password $pwd
Creating a Linux Virtual Machine in an Existing Cloud Service
New-AzureQuickVM -Linux -ServiceName $svc -Name $vm3
-ImageName $limg -LinuxUser $lu -Password $pwd
Setting VM configuration
New-AzureVMConfig -Name $vm1 -InstanceSize
Medium -ImageName $img |
Add-AzureProvisioningConfig -Windows -Password
$pwd |
Add-AzureDataDisk -CreateNew -DiskLabel 'data'
-DiskSizeInGB 10 -LUN 0 |
Add-AzureEndpoint -Name 'web' -PublicPort 80 -
LocalPort 80 -Protocol tcp |
New-AzureVM -ServiceName $newSvc -Location
$location
Disks and Images
Base OS image for new Virtual Machines
Sys-Prepped/Generalized/Read Only
Created by uploading or by capture
Writable Disks for Virtual Machines
Created during VM creation or during
upload of existing VHDs.
Image Mobility
Data disk creation
New Virtual Machine Creation with Data Disk
New-AzureVMConfig -Name 'myvm1' -InstanceSize 'Small' -
ImageName $img |
Add-AzureProvisioningConfig -Windows -Password $pwd |
Add-AzureDataDisk -CreateNew -DiskSizeInGB 10 -
DiskLabel 'myddisk' -LUN 0 |
New-AzureVM -ServiceName $cloudSvcName
Add new Data Disk to existing Virtual Machine
Get-AzureVM -ServiceName 'myvm1' |
Add-AzureDataDisk -CreateNew -DiskSizeInGB 10 -
DiskLabel 'myddisk' -LUN 1 |
Update-AzureVM
Disk and image repository
Get-AzureVMImage # Return all
Get-AzureVMImage | Where { $_.Category -eq 'Microsoft' } # Return Microsoft
Get-AzureVMImage | Where { $_.Category -eq 'User' } # Return Custom
Get-AzureVMImage | Where { $_.Category -eq 'Partner' } # Return Partner
Images
Get-AzureVMImage | Where { $_.OS -eq 'Windows' } # Return only Windows OS
images
Remove-AzureVMImage -ImageName 'myimg' -DeleteVHD # Delete image and
storage
Add-AzureVMImage -OS 'Windows' -ImageName 'MyWinImage' -MediaLocation
'http://storageaccount/vhds/winimage.vhd' # Add Existing VM Image from
Storage
Get-AzureDisk # Return all
Get-AzureDisk | Where { $_.AttachedTo -eq $null } # Return all not attached to a
VM
Get-AzureDisk | Where { $_.OS -eq $null } # Return only data disks
Get-AzureDisk | Where { $_.OS -eq 'Windows' } # Return only Windows OS disks
Remove-AzureDisk -DiskName 'mydisk' -DeleteVHD # Delete disk and storage
Add-AzureDisk -OS 'Windows' -DiskName 'MyWinDisk' -MediaLocation
'http://storageaccount/vhds/winosdisk.vhd‘ # Add Existing OS Disk from Storage
Add-AzureDisk -DiskName 'MyDataDisk' -MediaLocation
'http://storageaccount/vhds/datadisk.vhd‘
# Add Existing Data Disk from Storage
Customer Manager Architecture
IISVM1
IISVM2
SQL Server Load Balancer
PowerShell script. Performs
automated deployment
and VM configuringService Management API
End Users
CustomerManager DB
deployed
CustomerManager
web app deployed
CustomerManager
web app deployed
Automating Customer Manager App
Provision 2 frontend servers and 1 backend
Remote PowerShell to VMs and configure its
parameters: web server, firewall rules, app pools,
etc.
Compile and build CustomerManager. Deploy
the package to frontend servers. Point frontend
to SQL VM
Run CustomerManager and observe results
Demo: Provisioning VM
Managing VMs using PowerShell
Migrating apps to
the Cloud
Migration Approaches
Build Virtual Machine in the Cloud
Migrating an existing virtual machine
Lowers upload time and dependency risk
Application, configuration and data in an installed working state
Requires upload and installation of application and data
Requires uploading a large amount of data and higher risk of drivers
or other hardware dependencies on VM not available in the cloud
Migrating a Multi-VM application
Cloud Service Acts as a Network Boundary
All VMs in the same service can communicate directly.
Name resolution between VMs is automatic with Windows Azure provided DNS
VM Name: iisvm1
10.1.5.6
VM Name: iisvm2
10.1.5.7
VM Name: sqlvm1
10.1.5.8
DIP
Cloud Service
Name:
bootcamp2015kh.cloudapp.net
Load Balancer
Public IP
Virtual Machine Configuration
Windows Azure supports VHD file format
Upload existing VHDs using CSUpload.exe
Other formats will have to be converted or migrated before upload
Supports resuming failed transfers
Converting from dynamic to fixed disk on Upload
Efficient upload – does not send empty bytes
Things to do before uploading OS disk
Enable Remote Access
Migrating a simple virtual machine
On Premises VM
Machine Name: APPSRV1
Memory: 8Gb
Cores: 4
Ports: 80/443 http/https
Guest: C:
Host: C:VMsAPP-OS.vhd
Guest: D:
Host: D:VMsAPP-
Data.vhd
Guest: E:
Host: E:VMsAPP-
Logs.vhd
Cloud Service
Name: myapp.cloudapp.net
Virtual Machine
Role Name: appsrv1
4 cores
7 Gb RAM
Ports 80/443
Guest: C:
Host: C:VMsAPP-
OS.vhd
Guest: E:
Host: E:VMsAPP-
Data.vhd
Guest: F:
Host: F:VMsAPP-
Logs.vhd
Migration Steps
1) Upload VHDs
CSUpload or other tools
2) Create VM
OS disk = APP-OS.vhd
3) Configure data disks
Data Disk 1 = App-Data.vhd
Data Disk 2 = App-Logs.vhd
4) Adjust app for drive letters
Windows Azure Storage
5) Add Endpoints (80/443)
Imaging VMs in the Cloud
Cloud
Blob Storage
Base VHD
Boot
VM
Customi
ze VHD
Generali
ze VHD
Capture
VM
Capture VM saves customized
image to your image library
Azure Virtual Networks
 A protected private virtual network in cloud
 Extend enterprise networks into Azure
 Cross-premises connectivity
Virtual Network Scenarios
• Hybrid Public/Private Cloud
Enterprise app in Microsoft Azure requiring connectivity to on-premise resources
• Enterprise Identity and Access Control
Manage identity and access control with on-premise resources (on-premises Active
Directory)
• Monitoring and Management
Remote monitoring and trouble-shooting of resources running in Azure
• Advanced Connectivity Requirements
Cloud deployments requiring IP addresses and direct connectivity across services
29Microsoft Azure
Questions

More Related Content

What's hot (20)

PPTX
SQL_HA_DR_Azure
Oleg Chorny
 
PDF
Tech Ed North America 2014 - Java on Azure
Brian Benz
 
PPTX
Building & managing wa app wely
Spiffy
 
PPTX
WinOps Conf 2015 - Deploying apps to the Cloud with Octopus Deploy
WinOps Conf
 
PDF
Microsoft Azure Websites Webjobs
Magnus Mårtensson
 
PPTX
What's New for the Windows Azure Developer? Lots! (July 2013)
Michael Collier
 
PPTX
Resumen - Microsoft Build 2021
Miguel Angel Teheran Garcia
 
PDF
Tech ED 2014 Running Oracle Databases and Application Servers on Azurev1
Brian Benz
 
PPTX
BizSpark Startup Night Windows Azure March 29, 2011
Spiffy
 
PPTX
Windows Azure Web Sites – things they don’t teach kids in school - AzureConf
Maarten Balliauw
 
PPTX
Microsoft Azure 新功能導覽 @ Build 2014
Jeff Chu
 
PDF
VMware compute driver for OpenStack
openstackindia
 
PPTX
Windows 與 Azure 的容器旅程 @ Skilltree Day
Jeff Chu
 
PPTX
Ansible Automation - Enterprise Use Cases | Juncheng Anthony Lin
Vietnam Open Infrastructure User Group
 
DOCX
Guide - Migrating from Heroku to AWS using CloudFormation
Rob Linton
 
PDF
Develop and Run PHP on Windows. Say(Hello); to WordPress on Azure
Valent Mustamin
 
PPTX
Php on azure
Anders Lybecker
 
PPTX
WinOps Conf 2016 - Ed Wilson - Configuration Management with Azure DSC
WinOps Conf
 
PDF
20211120 Automating EC2 operations / EC2運用の自動化
Masaru Ogura
 
PPTX
Global Windows Azure Bootcamp - San Diego
Michele Leroux Bustamante
 
SQL_HA_DR_Azure
Oleg Chorny
 
Tech Ed North America 2014 - Java on Azure
Brian Benz
 
Building & managing wa app wely
Spiffy
 
WinOps Conf 2015 - Deploying apps to the Cloud with Octopus Deploy
WinOps Conf
 
Microsoft Azure Websites Webjobs
Magnus Mårtensson
 
What's New for the Windows Azure Developer? Lots! (July 2013)
Michael Collier
 
Resumen - Microsoft Build 2021
Miguel Angel Teheran Garcia
 
Tech ED 2014 Running Oracle Databases and Application Servers on Azurev1
Brian Benz
 
BizSpark Startup Night Windows Azure March 29, 2011
Spiffy
 
Windows Azure Web Sites – things they don’t teach kids in school - AzureConf
Maarten Balliauw
 
Microsoft Azure 新功能導覽 @ Build 2014
Jeff Chu
 
VMware compute driver for OpenStack
openstackindia
 
Windows 與 Azure 的容器旅程 @ Skilltree Day
Jeff Chu
 
Ansible Automation - Enterprise Use Cases | Juncheng Anthony Lin
Vietnam Open Infrastructure User Group
 
Guide - Migrating from Heroku to AWS using CloudFormation
Rob Linton
 
Develop and Run PHP on Windows. Say(Hello); to WordPress on Azure
Valent Mustamin
 
Php on azure
Anders Lybecker
 
WinOps Conf 2016 - Ed Wilson - Configuration Management with Azure DSC
WinOps Conf
 
20211120 Automating EC2 operations / EC2運用の自動化
Masaru Ogura
 
Global Windows Azure Bootcamp - San Diego
Michele Leroux Bustamante
 

Similar to Automating Azure VMs with PowerShell (20)

PPTX
Enrique lima azure-it-pro-ps
Enrique Lima
 
PPTX
Creating a gallery image for Azure marketplace
Alexey Bokov
 
PPTX
Aos canadian tour (YOW) @energizedtech - Manage AzureRM with powershell
Sean Kearney
 
PPTX
VMware on 123457895555azure cloud ppt.pptx
pwaghralkar
 
PPTX
Windows Azure Virtual Machines
Neil Mackenzie
 
PPTX
Deep dive into azure virtual machines
Jasjit Chopra
 
PDF
Azure 103 Certification Course
wiTTyMinds1
 
PPTX
From on premise to the hybrid cloud with microsoft azure
DotNetCampus
 
PPTX
FROM ON-PREMISE TO THE HYBRID CLOUD WITH MICROSOFT AZURE
DotNetCampus
 
PPTX
Microsoft azure overview
Ali Mkahal
 
PPTX
NIC - Windows Azure Pack - Level 300
Kristian Nese
 
PPTX
Azure IaaS Tanıtım - Uzun Anlatım
Mustafa
 
PPTX
IaaS azure_vs_amazon
Udaiappa Ramachandran
 
PPTX
App Innovation Circle Azure IaaS - 9th Dec
Raghuram Korukonda
 
PPTX
Lessons from migrating container applications to azure
Christoph Schittko
 
PPTX
Azure virtual machines & Terraform
Juan Jose Gazzola
 
PDF
Azure Migration Guide Virtual Machines and Applications
Elena Mia
 
PPTX
Azure from scratch Part 1 By Girish Kalamati
Girish Kalamati
 
PPTX
Azure IaaS
Guy Barrette
 
PDF
Azure Cloud Dev Camp - App Platform
giventocode
 
Enrique lima azure-it-pro-ps
Enrique Lima
 
Creating a gallery image for Azure marketplace
Alexey Bokov
 
Aos canadian tour (YOW) @energizedtech - Manage AzureRM with powershell
Sean Kearney
 
VMware on 123457895555azure cloud ppt.pptx
pwaghralkar
 
Windows Azure Virtual Machines
Neil Mackenzie
 
Deep dive into azure virtual machines
Jasjit Chopra
 
Azure 103 Certification Course
wiTTyMinds1
 
From on premise to the hybrid cloud with microsoft azure
DotNetCampus
 
FROM ON-PREMISE TO THE HYBRID CLOUD WITH MICROSOFT AZURE
DotNetCampus
 
Microsoft azure overview
Ali Mkahal
 
NIC - Windows Azure Pack - Level 300
Kristian Nese
 
Azure IaaS Tanıtım - Uzun Anlatım
Mustafa
 
IaaS azure_vs_amazon
Udaiappa Ramachandran
 
App Innovation Circle Azure IaaS - 9th Dec
Raghuram Korukonda
 
Lessons from migrating container applications to azure
Christoph Schittko
 
Azure virtual machines & Terraform
Juan Jose Gazzola
 
Azure Migration Guide Virtual Machines and Applications
Elena Mia
 
Azure from scratch Part 1 By Girish Kalamati
Girish Kalamati
 
Azure IaaS
Guy Barrette
 
Azure Cloud Dev Camp - App Platform
giventocode
 
Ad

More from Alexander Feschenko (17)

PPTX
Azure Container Service
Alexander Feschenko
 
PPTX
Microsoft Azure Automation
Alexander Feschenko
 
PPTX
Microsoft Azure. Troubleshooting and monitoring.
Alexander Feschenko
 
PPTX
Azure Powershell. Azure Automation
Alexander Feschenko
 
PPTX
Azure App Service Architecture. Web Apps.
Alexander Feschenko
 
PPTX
Introduction to Windows Azure IaaS
Alexander Feschenko
 
PPTX
Windows Azure. Scaling, Caching and Performance
Alexander Feschenko
 
PPTX
Windows Azure Security and Diagnostics
Alexander Feschenko
 
PPTX
Windows Azure Storage
Alexander Feschenko
 
PPTX
Windows Azure Overview and Application Lifecycle
Alexander Feschenko
 
PPTX
Высокопроизводительные приложения на базе Windows Azure
Alexander Feschenko
 
PPTX
HTML5 WebSockets and WebWorkers
Alexander Feschenko
 
PDF
Windows Azure Internals
Alexander Feschenko
 
PPTX
Developer Days 2011, Kharkov
Alexander Feschenko
 
PPTX
Построение высоконагруженных приложений на базе Windows Azure
Alexander Feschenko
 
PPTX
Построение высоконагруженных приложений на базе Windows Azure
Alexander Feschenko
 
PPTX
Продвинутая web-отладка с Fiddler
Alexander Feschenko
 
Azure Container Service
Alexander Feschenko
 
Microsoft Azure Automation
Alexander Feschenko
 
Microsoft Azure. Troubleshooting and monitoring.
Alexander Feschenko
 
Azure Powershell. Azure Automation
Alexander Feschenko
 
Azure App Service Architecture. Web Apps.
Alexander Feschenko
 
Introduction to Windows Azure IaaS
Alexander Feschenko
 
Windows Azure. Scaling, Caching and Performance
Alexander Feschenko
 
Windows Azure Security and Diagnostics
Alexander Feschenko
 
Windows Azure Storage
Alexander Feschenko
 
Windows Azure Overview and Application Lifecycle
Alexander Feschenko
 
Высокопроизводительные приложения на базе Windows Azure
Alexander Feschenko
 
HTML5 WebSockets and WebWorkers
Alexander Feschenko
 
Windows Azure Internals
Alexander Feschenko
 
Developer Days 2011, Kharkov
Alexander Feschenko
 
Построение высоконагруженных приложений на базе Windows Azure
Alexander Feschenko
 
Построение высоконагруженных приложений на базе Windows Azure
Alexander Feschenko
 
Продвинутая web-отладка с Fiddler
Alexander Feschenko
 
Ad

Recently uploaded (20)

DOCX
CS-802 (A) BDH Lab manual IPS Academy Indore
thegodhimself05
 
DOCX
8th International Conference on Electrical Engineering (ELEN 2025)
elelijjournal653
 
DOC
MRRS Strength and Durability of Concrete
CivilMythili
 
PPTX
Product Development & DevelopmentLecture02.pptx
zeeshanwazir2
 
PPTX
Solar Thermal Energy System Seminar.pptx
Gpc Purapuza
 
PPTX
GitOps_Without_K8s_Training_detailed git repository
DanialHabibi2
 
PDF
Book.pdf01_Intro.ppt algorithm for preperation stu used
archu26
 
PDF
Basic_Concepts_in_Clinical_Biochemistry_2018كيمياء_عملي.pdf
AdelLoin
 
PPTX
MPMC_Module-2 xxxxxxxxxxxxxxxxxxxxx.pptx
ShivanshVaidya5
 
PDF
monopile foundation seminar topic for civil engineering students
Ahina5
 
PDF
Pressure Measurement training for engineers and Technicians
AIESOLUTIONS
 
PPTX
265587293-NFPA 101 Life safety code-PPT-1.pptx
chandermwason
 
PPTX
Lecture 1 Shell and Tube Heat exchanger-1.pptx
mailforillegalwork
 
PPTX
Arduino Based Gas Leakage Detector Project
CircuitDigest
 
PPTX
Element 7. CHEMICAL AND BIOLOGICAL AGENT.pptx
merrandomohandas
 
PPTX
Shinkawa Proposal to meet Vibration API670.pptx
AchmadBashori2
 
PDF
PORTFOLIO Golam Kibria Khan — architect with a passion for thoughtful design...
MasumKhan59
 
PDF
MAD Unit - 1 Introduction of Android IT Department
JappanMavani
 
PDF
Zilliz Cloud Demo for performance and scale
Zilliz
 
PPT
PPT2_Metal formingMECHANICALENGINEEIRNG .ppt
Praveen Kumar
 
CS-802 (A) BDH Lab manual IPS Academy Indore
thegodhimself05
 
8th International Conference on Electrical Engineering (ELEN 2025)
elelijjournal653
 
MRRS Strength and Durability of Concrete
CivilMythili
 
Product Development & DevelopmentLecture02.pptx
zeeshanwazir2
 
Solar Thermal Energy System Seminar.pptx
Gpc Purapuza
 
GitOps_Without_K8s_Training_detailed git repository
DanialHabibi2
 
Book.pdf01_Intro.ppt algorithm for preperation stu used
archu26
 
Basic_Concepts_in_Clinical_Biochemistry_2018كيمياء_عملي.pdf
AdelLoin
 
MPMC_Module-2 xxxxxxxxxxxxxxxxxxxxx.pptx
ShivanshVaidya5
 
monopile foundation seminar topic for civil engineering students
Ahina5
 
Pressure Measurement training for engineers and Technicians
AIESOLUTIONS
 
265587293-NFPA 101 Life safety code-PPT-1.pptx
chandermwason
 
Lecture 1 Shell and Tube Heat exchanger-1.pptx
mailforillegalwork
 
Arduino Based Gas Leakage Detector Project
CircuitDigest
 
Element 7. CHEMICAL AND BIOLOGICAL AGENT.pptx
merrandomohandas
 
Shinkawa Proposal to meet Vibration API670.pptx
AchmadBashori2
 
PORTFOLIO Golam Kibria Khan — architect with a passion for thoughtful design...
MasumKhan59
 
MAD Unit - 1 Introduction of Android IT Department
JappanMavani
 
Zilliz Cloud Demo for performance and scale
Zilliz
 
PPT2_Metal formingMECHANICALENGINEEIRNG .ppt
Praveen Kumar
 

Automating Azure VMs with PowerShell

  • 1. Automating Azure VMs with PowerShell Feschenko Alexander Senior Software Engineer @ EPAM Systems Blog: feschenkoalex.blogspot.com Email: [email protected] Microsoft Azure
  • 2. Agenda Intro to Windows Azure PowerShell Automating Azure virtual machines. Base cmdlets description Demo Session. Create and configure virtual machine. Provision and configure frontend and backend parts Migrating applications to the Cloud with Azure IaaS
  • 4. What can you do with PowerShell? Query, Manage and Configure Virtual Machines across multiple subscriptions, cloud services and storage accounts. Provision Fully Configured Virtual Machines Remote Management Manage SQL Databases, Configuration, Diagnostics, Deployments, and Azure assets (Affinity Groups, Storage Accounts, Keys, etc..)
  • 6. VM Gallery 7 A COLLECTION OF PREBUILT IMAGES FOR VARIOUS WORKLOADS Microsoft Azure Windows Server 2012 R2 Ubuntu Server 14.04 LTS CentOS 6.5 SUSE Linux Enterprise Server Oracle Linux 6.4.0.0.0 SQL Server 2014 Standard Oracle Database 11g R2 BizTalk Server 2013 SharePoint Server Farm Microsoft Dynamics GP 2013 Zulu 8 SAP HANA Developer Edition Puppet Enterprise 3.2.3 Barracuda Web Application Oracle WebLogic Server 12.1.2 Visual Studio Ultimate 2013 openSUSE 13.1
  • 7. VM Extensions • Installable components to customize VM instances • Enable various DevOps scenarios • Can be added, updated, disabled or removed at any time • Managed via portal, PowerShell and Management APIs 8Microsoft Azure
  • 8. Virtual Machine Management Supports VM Creation in a Single Cmdlet Provision With: Endpoints, Data Disks Configure: Cache Settings for OS/Data Disks and Subnet Names
  • 9. Setting the current storage account Get-AzureStorageAccount | Select StorageAccountName
  • 10. Virtual Machine Discovery Retrieve Cloud Services Get-AzureService Retrieve Virtual Machines for Service Get-AzureVM -ServiceName $cloudSvcName Retrieve Status for All VMs in Subsription Get-AzureService | foreach { $_ | Get-AzureVM | ft ServiceName, Name, InstanceStatus }
  • 11. Simple VM creation First Virtual Machine in a NEW Cloud Service (-Location specified) New-AzureQuickVM -Windows -ServiceName $svc -Name $vm1 -ImageName $wimg -Location $location -Password $pwd New Virtual Machine in an Existing Cloud Service(no -Location) New-AzureQuickVM -Windows -ServiceName $svc -Name $vm2 -ImageName $wimg -Password $pwd Creating a Linux Virtual Machine in an Existing Cloud Service New-AzureQuickVM -Linux -ServiceName $svc -Name $vm3 -ImageName $limg -LinuxUser $lu -Password $pwd
  • 12. Setting VM configuration New-AzureVMConfig -Name $vm1 -InstanceSize Medium -ImageName $img | Add-AzureProvisioningConfig -Windows -Password $pwd | Add-AzureDataDisk -CreateNew -DiskLabel 'data' -DiskSizeInGB 10 -LUN 0 | Add-AzureEndpoint -Name 'web' -PublicPort 80 - LocalPort 80 -Protocol tcp | New-AzureVM -ServiceName $newSvc -Location $location
  • 13. Disks and Images Base OS image for new Virtual Machines Sys-Prepped/Generalized/Read Only Created by uploading or by capture Writable Disks for Virtual Machines Created during VM creation or during upload of existing VHDs.
  • 15. Data disk creation New Virtual Machine Creation with Data Disk New-AzureVMConfig -Name 'myvm1' -InstanceSize 'Small' - ImageName $img | Add-AzureProvisioningConfig -Windows -Password $pwd | Add-AzureDataDisk -CreateNew -DiskSizeInGB 10 - DiskLabel 'myddisk' -LUN 0 | New-AzureVM -ServiceName $cloudSvcName Add new Data Disk to existing Virtual Machine Get-AzureVM -ServiceName 'myvm1' | Add-AzureDataDisk -CreateNew -DiskSizeInGB 10 - DiskLabel 'myddisk' -LUN 1 | Update-AzureVM
  • 16. Disk and image repository Get-AzureVMImage # Return all Get-AzureVMImage | Where { $_.Category -eq 'Microsoft' } # Return Microsoft Get-AzureVMImage | Where { $_.Category -eq 'User' } # Return Custom Get-AzureVMImage | Where { $_.Category -eq 'Partner' } # Return Partner Images Get-AzureVMImage | Where { $_.OS -eq 'Windows' } # Return only Windows OS images Remove-AzureVMImage -ImageName 'myimg' -DeleteVHD # Delete image and storage Add-AzureVMImage -OS 'Windows' -ImageName 'MyWinImage' -MediaLocation 'http://storageaccount/vhds/winimage.vhd' # Add Existing VM Image from Storage Get-AzureDisk # Return all Get-AzureDisk | Where { $_.AttachedTo -eq $null } # Return all not attached to a VM Get-AzureDisk | Where { $_.OS -eq $null } # Return only data disks Get-AzureDisk | Where { $_.OS -eq 'Windows' } # Return only Windows OS disks Remove-AzureDisk -DiskName 'mydisk' -DeleteVHD # Delete disk and storage Add-AzureDisk -OS 'Windows' -DiskName 'MyWinDisk' -MediaLocation 'http://storageaccount/vhds/winosdisk.vhd‘ # Add Existing OS Disk from Storage Add-AzureDisk -DiskName 'MyDataDisk' -MediaLocation 'http://storageaccount/vhds/datadisk.vhd‘ # Add Existing Data Disk from Storage
  • 17. Customer Manager Architecture IISVM1 IISVM2 SQL Server Load Balancer PowerShell script. Performs automated deployment and VM configuringService Management API End Users CustomerManager DB deployed CustomerManager web app deployed CustomerManager web app deployed
  • 18. Automating Customer Manager App Provision 2 frontend servers and 1 backend Remote PowerShell to VMs and configure its parameters: web server, firewall rules, app pools, etc. Compile and build CustomerManager. Deploy the package to frontend servers. Point frontend to SQL VM Run CustomerManager and observe results
  • 19. Demo: Provisioning VM Managing VMs using PowerShell
  • 21. Migration Approaches Build Virtual Machine in the Cloud Migrating an existing virtual machine Lowers upload time and dependency risk Application, configuration and data in an installed working state Requires upload and installation of application and data Requires uploading a large amount of data and higher risk of drivers or other hardware dependencies on VM not available in the cloud
  • 22. Migrating a Multi-VM application Cloud Service Acts as a Network Boundary All VMs in the same service can communicate directly. Name resolution between VMs is automatic with Windows Azure provided DNS VM Name: iisvm1 10.1.5.6 VM Name: iisvm2 10.1.5.7 VM Name: sqlvm1 10.1.5.8 DIP Cloud Service Name: bootcamp2015kh.cloudapp.net Load Balancer Public IP
  • 23. Virtual Machine Configuration Windows Azure supports VHD file format Upload existing VHDs using CSUpload.exe Other formats will have to be converted or migrated before upload Supports resuming failed transfers Converting from dynamic to fixed disk on Upload Efficient upload – does not send empty bytes Things to do before uploading OS disk Enable Remote Access
  • 24. Migrating a simple virtual machine On Premises VM Machine Name: APPSRV1 Memory: 8Gb Cores: 4 Ports: 80/443 http/https Guest: C: Host: C:VMsAPP-OS.vhd Guest: D: Host: D:VMsAPP- Data.vhd Guest: E: Host: E:VMsAPP- Logs.vhd Cloud Service Name: myapp.cloudapp.net Virtual Machine Role Name: appsrv1 4 cores 7 Gb RAM Ports 80/443 Guest: C: Host: C:VMsAPP- OS.vhd Guest: E: Host: E:VMsAPP- Data.vhd Guest: F: Host: F:VMsAPP- Logs.vhd Migration Steps 1) Upload VHDs CSUpload or other tools 2) Create VM OS disk = APP-OS.vhd 3) Configure data disks Data Disk 1 = App-Data.vhd Data Disk 2 = App-Logs.vhd 4) Adjust app for drive letters Windows Azure Storage 5) Add Endpoints (80/443)
  • 25. Imaging VMs in the Cloud Cloud Blob Storage Base VHD Boot VM Customi ze VHD Generali ze VHD Capture VM Capture VM saves customized image to your image library
  • 26. Azure Virtual Networks  A protected private virtual network in cloud  Extend enterprise networks into Azure  Cross-premises connectivity
  • 27. Virtual Network Scenarios • Hybrid Public/Private Cloud Enterprise app in Microsoft Azure requiring connectivity to on-premise resources • Enterprise Identity and Access Control Manage identity and access control with on-premise resources (on-premises Active Directory) • Monitoring and Management Remote monitoring and trouble-shooting of resources running in Azure • Advanced Connectivity Requirements Cloud deployments requiring IP addresses and direct connectivity across services 29Microsoft Azure

Editor's Notes

  • #2: Presentation Objectives: This presentation provides a high-level overview of Azure IaaS. It covers essential concepts and tools for people who are new to Azure to get started. It covers both Virtual Machines and Virtual Networks. Speaker Notes: It’s important for the speaker to reiterate the first segment, which should have been covered by the “Design Cloud Solutions” session earlier. Given there are lots of contents to be covered, the speaker should focus on only high-level concepts instead of drilling too much into details.
  • #3: Slide Objectives: Explain the agenda of the session. Speaker Notes: Explain this presentation is a high-level overview, so not everything is covered in-depth.
  • #4: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #5: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #6: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #7: Slide Objective: Explain workflow for provisioning VMs in the cloud Speaker Notes: You have three methods of starting this process: Build a VM from the portal, from the command line OR programmatically calling the REST API. Once your choice of provisioning is made you will need to select the image and instance size to start from. The newly created disk will be stored in blob storage and your machine will boot.
  • #8: Slide Objective: Explain a wide variety of images that you can choose from. Speaker Notes: First of all, you can choose from different Windows Servers and a variety of Linux implementations. [Click] As well as pre-built images for different flavors of SQL Database and Oracle databases. [Click] You can also choose from a number of first-party and certified third-party images for various application servers and infrastructural components. [Click] And last but not least, if you are a MSDN subscriber, you also have access to Visual Studio images and client Windows systems such as Windows 7 and Windows 8.1 for your DevTest purposes.
  • #9: Slide Objective: Introduce VM extensions. Speaker Notes: No matter how big the image gallery is, your projects may have specific needs that can’t be satisfied by standard images. Some components such as anti-virus, configuration management agents are required on most machines for compliance and management purposes. This allows use to innovate faster to meet with your project needs. And you have flexibility to pick and combine extensions for your goals. Point out some of existing extensions: Custom Script Extension, which allows you to download and execute PowerShell scripts. Chef Extension and Puppet Extension for automated management at scale. Symantec Endpoint Protection etc. for protection. Docker (Linux only). Visual Studio Remote Debugger.
  • #11: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #12: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #13: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #14: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #15: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #16: Slide Objective: Explain the differences between disks and images with VMs
  • #17: Slide Objective: Explain the benefits of image mobility Notes: One of the key benefits of IaaS is flexibility and control. The Microsoft Azure solution provides the capability of not only moving VHDs TO the cloud but also allows you to copy the VHD back down and run it locally or on another cloud provider. Great for testing out production issues or any other need where you require a copy of the production server.
  • #18: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #19: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #21: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #22: Demo: Provisioning VM Prerequisites: A Windows Server 2012 is already provisioned. Steps: Open Ibiza portal and click the NEW button at the lower-left corner. Show the short list of resources. Explain that I can directly create popular resources here such as a Windows Server 2012. Click on the Everything link. In Gallery blade, open the Virtual machines category. Scroll down the view and show images of different types (refer back to slide 9). Click on Windows Server 2012 R2, and then click the Create button in the overview blade. For non-Microsoft focused audience, consider to pick a Linux image instead. Fill in the Create VM form and click on the Create button to provision the VM. Explain this will take a few minutes. Open the already provisioned VM. Scroll down the blade to show various of information available on the blade. Click on the Extensions tile. On the Extensions blade, click on the ADD icon to bring up the extension list. Introduce that VM extensions are installable components to customize VM instances. Switch to slides to continue with VM extension introduction.
  • #24: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #25: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #26: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #27: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.
  • #28: Slide Objectives: Explain how Azure helps developers to refocus on their applications. Speaker Notes: Before we discuss about specifics, let’s refocus on what you care about – your application/service. Azure is taking a application-centric approach and brings tools and services to support DevOps scenarios.