Skip to main content

Command Palette

Search for a command to run...

A pictorial guide to creating Linux Virtual Machine

Updated
2 min read
A pictorial guide to creating Linux Virtual Machine

Join me as we explore the step-by-step approach to creating a Linux Virtual Machine and how we log into it using SSH. We will be setting up a private key/public key authentication.

Step 1: Ensure you have a valid Azure Subscription

Step 2: Select Create under a virtual machine

Step 3: Select a Resource group or create a new one. The Resource Group is to organise your resources for easy management and monitoring

Step 4: Under instance details, specify your virtual machine name, select the Region and availability and redundancy setting. You also need to select the image to use. For this example, we are using the Red Hat Linux 8.7

Step 5: Specify the username and keypair name

Step 6: Allow SSH access to the Virtual machine

Step 7: Disk parameters setting

Step 8: Networking

Step 9: Management

Step 10: Go through Monitoring, Advanced and Tag tab and make adjustments as necessary. Ensure you have Validation passed at the Create and Review Window

Step 11: Click Create to begin the deployment of your virtual machine

Step 11: Download and keep your private key file saved. You can only download it once.

Step 12: Go to the resource

Step 13: Connect

Step 14: SSH to the Virtual machine. From your power shell in Windows type the command copied

--ssh -i <private key path> azurelinux@51.105.48.110

Step 15: Open Windows PowerShell as an administrator on your local system.

  • Search for PowerShell on the Windows search bar, right-click and open as administrator

Step 16: On your CLI type "az login" A web browser will open for you to log in to your Azure login

After logging in your will receive the indication that your CLI is logged in and ready to receive the SSH command

Step 17: copy the URL for SSH login to your Linux Virtual machine

Step 18: replace <key path> with the path to your private key file

when logging in for the first time type yes to the question prompted

Step 19: You are successfully logged in

Thank you for reading. Hope the write up is informative and educative.

Thanks.

Femi Moses

More from this blog

Femi's place

11 posts

New technical blogger. Ambition is to inspire others and strong believer of rising by lifting others.