DEV Community

Cover image for How to create a Window Virtual Machine using Azure
Emmyfx1
Emmyfx1

Posted on

How to create a Window Virtual Machine using Azure

A virtual machine, commonly shortened to just VM, is no different than any other physical computer like a laptop, smart phone, or server. It has a CPU, memory, disks to store your files, and can connect to the internet if needed. While the parts that make up your computer (called hardware) are physical and tangible, VMs are often thought of as virtual computers or software-defined computers within physical servers, existing only as code.

how to create a VM
open the Azure portal and sign in, click the search bar to search for Virtual Machine
Image description
and type the VIRTUAL MACHINE in the search bar and click on the plus sign to create
Image description

Select a subscription and create a resource group and give your VM a unique name
Image description

select a region and the image you want the Virtual machine to have
Image description

Next create a username and a password and select HTTPS in the inbound port
Image description
click on create review and create it will validate in a few seconds then click on create
Image description
Next go to resource group
Image description

click on connect with RDP and download the RDP file
Image description
open the downloaded file and log in with the information yoiu created

your new VM should display
Image description
Image description
click the search bar at the bottom left and type in powershell
Image description
When the powershell on the search displays right click and run as administrator
then type Insall-WindowsFeature Web-Server
Image description
Go back to the overview of the virtual machine and copy the public IP address and paste it on a web page the virtual machine should display
Go back to the overview page of the virtual machine and click on disk and add a data disk give it a name and increase the size to 10gb and click on save/apply
Image description
go to the virtual machine search bar and type in disk management and click on it
Image description
Click ok to initialize it
Image description

scroll down to locate disk 2, which is the new disk you created and right click on it
Image description
Click on new simple volume
Image description
click on start
Image description
Keep the default setting but you can change the same from new volume to a name of your choice and click on finish
Image description
Image description
Your disk is ready to be use
Image description

Top comments (0)