DEV Community

Cover image for Creating and Deploying your first Linux VM made simple
Berenice Enikanoselu
Berenice Enikanoselu

Posted on

Creating and Deploying your first Linux VM made simple

Hi,I'm making this post to show you how easy you can create and deploy your first VM. Constant practice will make you a NINJA. Come right in with me and let's see together, even a dummy will get it the very first time!

To create a Virtual Machine follow these steps:

  1. Login to your Azure Portal you can click this link https://azure.microsoft.com/en-us/get-started/azure-portal
  2. sign in with your preferred login details
  3. Type VM or virtual machine in the search bar, select virtual machines from the drop down you find

4 click Create in the window that opens, pick the first option: Virtual Machine which is the simplest to create for now. Others will be treated in subsequent exercises

5 A new window will open showing your current subscription, you can change it if you have multiple subscriptions. Choose aan existing resource group by clicking the arrow or create a new one if none is existing(or you prefer a new one to the existing ones)

6 Name your virtual marchine(name must be between 3- 24 characters with alpbabeths/numbers), choose your preferred location, choose availability option (We chose NO INFRASTRUCTURE REDUNDANCY REQUIRED because we are running on free subscription) Choose Standard security type(this is to minimise cost too), choose any of the Ubuntu servers as Image. You can view all the images as indicated by the arrow


7 Choose the size. Click to see more sizes.
Under Administrator Account choose Password

8 Fill in the login details for username, Password and confirmation. Be sure to save your password in a secure place where you can easily reference it.
9 Select SSH(22) and HTTP(80) under Select Inbound Port

10 Scroll up and click Monitoring, disable Boot diagnostic

11 click create and review. (Fix any review that is suggested, then click create and review again). Click create. Your Virtual machine will start deploying!
After it is fully deployed you can improve the efficiency of the machine by follow these steps:
11 click the Primary NIC Public IP Address.

Drag the circle as indicated by the arrow to increase the idle time out from 4 to 30 and click APPLY **

Use the browser back arrow to return to the virtual machine page and click connect twice to make the VM active.

Click **Check Access
to give a green mark port 22 is accesible...... coppy the SSH address as indicated by arrow
![ ](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rivrqcd8uqu0iefh3t9x.png
Open your VS code terminal. If you do not have the VScode terminal download it from google and run the following commands

  1. paste the copied SSH address in the command line and strike enter key on your keyboard. Input yes, strike enter key, inputyour password(Note that the Password will not show so you have to be sure of what you are inputting), strike enter key
  2. run the following command subsequently i. sudo su ii. apt update iii. apt install ngnix iv. apt instal vim

You are now a NINJA! more commands will be treated in subsequent posts!!

Top comments (0)