How to create a Linux Virtual Machine and Access it
Create the Linux Virtual Machine:
Below are the simple steps in setting up a Linux virtual machine.
- Access the Azure portal home page and click on virtual machines.
Click on Create Virtual Machine and fill in all the required tabs below.
Create a resource group or use the existing resource group from the drop-down.
Give the Virtual machine a name and ensure it is unique.
Select a region and it is always advisable to consider region proximity and cost.
Select the image required. since we are creating a Linux VM, select Ubuntu server 20.04
Select the size you require.
To set administrator account of the virtual machine, create a username and password.
Note: You need to enable inbound port SSH (Secure shell) in other to be able to access the virtual machine.
Then create the VM.
Access the virtual Machine:
click connect on the virtual machine.
Note the IP address (51.145.77.14)
Click "Select SSH using Azure CLI"
Check the box and click on "Configure and connect"
Open Power Shell on your computer as an administrator. Ensure your PowerShell works with Azure CLI.
Login to your Azure portal from your power shell using this command - " az login"
Once logged in, use this command to enter the Virtual Machine - "ssh <Username>@Ipaddress" and click enter.
Login with the password used to create the VM
-
you now have access to the Linux virtual machine
-
Welcome to the Linux Virtual Machine
Subscribe to my newsletter
Read articles from Damilola Awojoodu directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by