Lab1 7
Lab1 7
Lab Report
On
Installing Virtual Box and Ubuntu
..…………………………………………………………………
Lab Report 1
Theory:
Virtual Machine Applications abstract the hardware of our personal computers such
as CPU, Disk Drives, Memory, NIC (Network Interface Card), etc, into many
different execution environments as per our requirements. Hence, gives us a feeling
that each execution environment is a single computer, for example, VirtualBox
Desktop Software.
Installing Ubuntu on VirtualBox is the need of the time. We can create the Ubuntu
Virtual Machine for several reasons. All of these are fundamentally related to the
ability to share the same basic hardware yet also support different execution
environments. For all of these reasons, many move to Ubuntu Download on
VirtualBox and use it.
Steps:
Step 1: Before we begin with the installation process, we need to Download ISO for
Ubuntu. For that, all the versions of Ubuntu are available on the Official Site.
Step 3: Give a Name to your Virtual Machine and select the Location for it to install.
Step 4: Assign RAM Size to your Virtual Machine.
Step 5: Create a Virtual Hard Disk for the machine to store files.
Step 6: Select the type of Hard disk. Using VDI type is recommended.
Step 7: Either of the Physical Storage types can be selected. Using a Dynamically
Allocated Disk is by default recommended.
Step 8: Select Disk Size and provide the Destination Folder to install.
Step 9: After the Disk creation is done, boot the Virtual Machine and begin
installing Ubuntu.
Step 10: If the installation disk is not automatically detected. Browse the file location
and select the ISO file for Ubuntu.
Step 11: Proceed with the installation file and wait for further options.
Step 12: Click on the Install Ubuntu option, this might look different for other Ubuntu
versions.
Step 13: Select Keyboard Layout, if the defaults are compatible, just click on
the Continue button and proceed.
Step 14: Select Installation Type. By default, it is set to Normal Installation, which is
recommended, but it can also be changed to Minimal Installation if there is no need
for all Ubuntu features.
Step 15: Click on the Install Now button and carry on with the installation. Do not get
worried about the Erase disk option, it will only be effective inside the virtual
machine, and other system files outside the VirtualBox remain intact.
Step 16: Click on the Continue button, and proceed with writing changes on the disk.
Step 18: Choose a Name for your computer and set a Password to secure login info.
Step 20: Once the installation process is over, reboot your Virtual Machine.
Some of the basic commands in Ubuntu:
Free Memory Usage: Check free memory with free -mh.
Storage Information: Check storage with df -h and folder/file sizes with du -h.
CPU/Processor Information: View CPU processes with top.
Process and User Info: Get process and user info with ps -ef.
Network Configuration:
o Change network types (e.g., NAT to bridge adapter) in virtual machine
settings.
o View IP configurations with ipconfig (Windows) or ip a (Linux).
o System Updates: Update system resources while in an idle state.
Virtual Machine Operations:
o Access virtual machine settings through Machine -> Settings ->
System.
o Take and manage snapshots (Snapshot -> Take Snapshot, Snapshot ->
Manage Snapshots).
Linux Commands:
o Change directory (cd /path/to/directory).
o Create files (touch filename), directories (mkdir dirname), and list files
(ls -ltr).
o Remove files/directories (rm -rf filename dirname).
o Shutdown: Shutdown the virtual machine (sudo shutdown).
Result and Conclusion:
Lab Report
On
Snapshot and Restoring Files using Virtual Machine
..…………………………………………………………………
Lab Report 2
Theory:
Snapshot Technology: Snapshots are based on a technology called "copy-on-
write," which means that when you take a snapshot, VirtualBox creates a read-
only image of the current state of the VM's disk. Any changes made to the VM
after taking the snapshot are written to a new, separate file, leaving the
original disk image unchanged.
Delta Images: As you make changes to the VM after taking a snapshot,
VirtualBox creates "delta" images to store these changes. When you restore a
snapshot, VirtualBox merges these delta images back into the original disk
image to revert the VM to its previous state.
Snapshot Chains: If you take multiple snapshots of a VM, VirtualBox creates
a chain of snapshots, where each snapshot depends on the previous one. When
you restore a snapshot, VirtualBox ensures that all subsequent snapshots in the
chain are discarded, bringing the VM back to the selected state.
Snapshot Management: It's important to manage your snapshots carefully to
avoid using excessive disk space. Regularly delete snapshots that are no longer
needed, as each snapshot consumes additional disk space.
Steps:
Creating Snapshots:
1. Select the VM: In the VirtualBox Manager, select the VM you want to take a
snapshot of.
2. Take Snapshot: Click on the "Snapshot" button. You can also go to the
"Machine" menu and select "Take Snapshot."
3. Name the Snapshot: Give your snapshot a descriptive name to easily identify it
later.
4. Optional: You can also choose to take a snapshot of the VM's memory, which
allows you to restore the VM to an exact state, including the contents of its
memory.
1. Access Snapshot: In the VirtualBox Manager, select the VM and click on the
"Snapshots" tab. Here, you'll see a list of snapshots.
2. Restore Snapshot: To restore the VM to a previous state, select the snapshot
you want to restore to and click the "Restore" button. This will revert the VM's
state, including its disk and memory, to the selected snapshot.
Results and Conclusion
Result: After taking a snapshot of a virtual machine, you will have created a point-in-
time backup of the VM's state. This snapshot includes the VM's disk, memory, and
settings at the moment the snapshot was taken. You can continue to use the VM as
usual, making changes and testing different configurations. If at any point you need to
revert to the state captured in the snapshot, you can do so easily.
Lab Report
On
Virtual Machine and Azure Cloud
..…………………………………………………………………
Lab Report 4
Lab Report
On
IIS setup in azure using windows server students
..…………………………………………………………………
Lab Report 5
1) Azure Virtual Machine Provisioning: Begin by accessing the Azure portal and
creating a new virtual machine instance. Choose the appropriate Windows Server
edition based on your requirements.
2) Network Configuration: Configure networking settings for the virtual machine,
including IP address assignment, virtual network configuration, and subnet
settings. This ensures proper connectivity for the VM within the Azure
environment.
3) Storage Setup: Set up storage resources for the VM, selecting disk types and
sizes that meet the needs of your applications. Adequate storage provisioning is
essential for storing application files and system data.
4) Installation of Internet Information Services (IIS): After the VM is
provisioned, connect to it using Remote Desktop Protocol (RDP). Install the IIS
role through the Server Manager or PowerShell. This step enables the VM to act
as a web server, capable of hosting and serving web content.
5) IIS Configuration: Configure various aspects of IIS to suit your application
requirements. This includes setting up website bindings, configuring SSL
certificates for secure communication, defining authentication methods, and
implementing URL rewrite rules for redirecting and rewriting URLs.
6) Deployment of Web Applications: Upload your web application files to the VM.
This can be done manually via RDP or through deployment tools such as FTP or
Git. Ensure that the application files are placed in the appropriate directories
within the IIS web server's root folder.
7) Testing and Monitoring: Thoroughly test the deployed web applications to
ensure they function as expected. Implement monitoring and logging mechanisms
to track performance metrics and identify any potential issues that may arise
during operation.
Step1: Create a windows virtual machine in azure cloud
Step 2: Review and create the virtual machine
Step 3: Add Roles and Features
Step 10: Now you can access your website with the public ip outside of the
window from anywhere.
Result
By setting up Internet Information Services (IIS) in a virtualized environment using
Azure, we established a powerful platform for hosting web applications. This
involved creating a virtual machine instance on Azure, installing and configuring IIS
to serve web content, and deploying our web applications. We ensured that the
virtualized environment provided the necessary resources and flexibility for our web
hosting needs.
Conclusion
Virtualizing IIS on Azure offers a convenient and scalable solution for hosting
websites. Leveraging Azure's infrastructure allows us to easily manage and scale our
web applications while benefiting from the reliability and security of the cloud.
Overall, utilizing Azure for virtualized web hosting simplifies management tasks and
ensures optimal performance for our online presence.
(Affiliated to Tribhuvan University
Lab Report
On
Azure Blob Storage
..…………………………………………………………………
Lab Report 6
In this lab we performed steps such as creating a storage account, uploading blobs,
and creating a static blog website using azure storage concept.
Conclusion:
We learned using Azure Blob Storage effectively understanding Azure Blob Storage
and cloud storage concepts.
(Affiliated to Tribhuvan University
Lab Report
On
Nginx Instillation in Dockers using Azure virtual machine
..…………………………………………………………………
Lab Report 7
Theory:
Docker is a platform that allows you to package, distribute, and run applications in
containers. Containers are lightweight, portable, and self-sufficient environments that
contain everything needed to run an application, including the code, runtime, system
tools, libraries, and settings. Some of the theory concepts are:
Azure Container Instances (ACI): ACI allows you to run containers without
managing the underlying infrastructure.
Azure Container Registry (ACR): ACR is a private registry for storing and
managing container images. It provides secure access to your images,
integration with Azure services, and support for Docker CLI and other
container tools.
Containerization: Containerization is a lightweight alternative to full
machine virtualization. It involves encapsulating an application in a container
with its own operating environment. Containers are isolated from each other
and from the underlying infrastructure, making them portable and consistent
across different environments.
Images: Docker containers are created from images. An image is a read-only
template that contains the application code, runtime, libraries, and
dependencies needed to run the application. Images are used to create
containers.
Containers: A container is a runtime instance of an image. It runs as a process
on the host machine's operating system and contains everything needed to run
the application, including the code, runtime, system tools, libraries, and
settings.
Dockerfile: A Dockerfile is a text file that contains instructions for building a
Docker image. It specifies the base image to use, the dependencies to install,
and the commands to run to set up the environment for the application.
Docker Engine: Docker Engine is the runtime environment for containers. It
includes the Docker daemon, which manages the containers, images,
networks, and volumes, and the Docker CLI, which is used to interact with the
Docker daemon.
Step 1: Connecting to Azure Instances via Terminal
Result:
Conclusion:
This setup provides a flexible, scalable, and resource-efficient solution for hosting
web applications, leveraging the benefits of Docker and Azure VMs.