Azure Classroomnotes 13/Sep/2022

Azure Linux VM’s Continued

Activity 1: Create an ubuntu linux VM

  • Create an ubuntu linux vm and install the following softwares
    • apache
    • php
    • stress
sudo apt update
sudo apt install apache2 -y
sudo apt install php libapache2-mod-php php-mysql -y
sudo apt install stress -y
echo '<?php phpinfo(); ?>' > info.php
sudo cp info.php /var/www/html/info.php
# create a file in 
#<?php phpinfo(); ?>
  • While creating VM open 22, 80 ports
  • Ensure you use the key imported (your id_rsa)
  • Ensure the username matches your laptops username
  • Solution
    • Create a ubuntu 20.04 VM, Enter user name (Dell) and select public key stored in azure.
    • Once the VM is created.
    • Approach 1:
      • ssh into the vm and execute the above commands
      • Access http://publicip/info.php

    • Approach 2: Lets use Run Command from Operations blade
      • Screen shot

      • Lets select shell script


    • When we use Approach 2, azure will interact with the agent present on the linux vm.
  • Note: Try resetting the ssh password or key using the help blade => Reset password from Azure VM
Published
Categorized as Uncategorized Tagged

By continuous learner

devops & cloud enthusiastic learner

Leave a ReplyCancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Please turn AdBlock off
Animated Social Media Icons by Acurax Responsive Web Designing Company

Discover more from Direct DevOps from Quality Thought

Subscribe now to keep reading and get access to the full archive.

Continue reading

Exit mobile version
%%footer%%