You are on page 1of 10

OPERATING SYSTEM

ACTIVITY - 02

1. Explain OS level virtualization and state its benefits

RB
Operating System Virtualization

Operating system virtualizations include a modified form than a normal


operating system so that different users can operate its end use different
applications. This whole process shall perform on a single computer at a time.
In OS virtualizations, the virtual eyes environment accepts commands from
TH
any of the users operating it and performs different tasks on the same
machine by running different applications.
In operating system virtualizations when the application does not interfere with
another one even though they are functioning in the same computer.
The kernel of an operating system allows more than one isolated user-space
RU

instance to exist. These instances are called software containers, which are
virtualization engines.

Uses

● Operating System Virtualization is used to integrate server hardware by


AM

moving services on separate servers.


● It provides security to the hardware resources which harm by distrusting
users.
● OS Virtualization is used for virtual hosting environments.
● It can separate several applications into containers.
● Simplified system administration, as containers can be easily created,
modified, and destroyed using container management tools, reducing
the need for manual intervention and configuration.
● Overall, OS-level virtualization is a powerful tool for creating lightweight,
efficient, and scalable environments for deploying and managing
applications, and it has become an increasingly popular technology for
cloud computing and DevOps workflows.
2. Compare VMs and Containers

Virtual Machine

A VM can be defined as a virtual environment that works like a computer


system (virtual) with its CPU, storage, memory, and network interface built on
the physical hardware systems.
A software known as hypervisor isolates the resources of the machine from
hardware and arranges them properly.

Various physical machines that are equipped with any hypervisor like KVM

RB
(Kernel-based Virtual Machine) are known as a host computer, host operating
system, host machine, or simply host. Many virtual machines that are using
the resources are called a guest operating system, guest computers, guest
machines, or simple guests.

A hypervisor treats all computer resources (such as CPU, storage, and


TH
memory) as the resource pool that can be relocated among new virtual
machines or existing guests easily.
Virtual Machines allow more than one different types of operating system to
execute on an individual computer simultaneously. All operating systems
execute in the same fashion an application or operating system normally will
RU

on the host hardware.

Container
AM

The container is a type of OS virtualization. An individual container could be


used for running anything through a small software process or micro-service
to a big application.
Within a container, there are so many essential executables such as
configuration files, libraries, and binary code.

Compared to machine or server virtualization approaches, a container does


not include images of the operating system. It makes them portable and
lightweight with fundamentally less overhead. More than one container can be
deployed as multiple container clusters. These types of clusters can be
handled by a container orchestrator like Kubernetes.
Let’s see the difference between Virtual machines and Containers.

SNo. Virtual Machines(VM) Containers

A VM is a piece of software that


allows you to install other software While a container is a software
1 inside of it so you basically control it that allows different functionalities
virtually as opposed to installing the of an application independently.
software directly on the computer.

While applications running in a

RB
Applications running on VM systems
2. container environment share a
can run different OS.
single OS.

While containers virtualize the


3. VM virtualizes the computer system.
operating system only.
TH
While the size of the container is
4. The VM size is very large.
very light; i.e. a few megabytes.

VM takes minutes to run, due to the While containers take a few


5.
large size. seconds to run.
RU

While containers require very


6. VM uses a lot of system memory.
less memory.

7. VM is more secure. While containers are less secure.


AM

While containers are useful when


VM’s are useful when we require all
we are required to maximise the
8. of the OS resources to run various
running applications using
applications.
minimal servers.

While examples of containers


Examples of VM are: KVM, Xen,
9. are:RancherOS, PhotonOS,
VMware.
Containers by Docker.
3. Identify the difference between hypervisors and Linux containers

Hypervisors and Linux containers are both technologies used for virtualization,
but they have some fundamental differences. Here are a few of the key
differences between the two:

Operating System

Hypervisors are typically used to virtualize an entire operating system,


allowing multiple guest operating systems to run on a single physical host. In
contrast, Linux containers virtualize at the operating system level, allowing

RB
multiple isolated user-space instances to run on a single host operating
system.

Resource Allocation:

Hypervisors provide virtual machines with dedicated hardware resources,


TH
such as CPU, memory, and storage, which are completely isolated from other
virtual machines. In contrast, Linux containers share the same kernel and
operating system resources of the host, but each container has its own
isolated file system and user space.
RU

Overhead

Hypervisors have a higher overhead than Linux containers because they


virtualize the entire operating system and require more resources to run. On
the other hand, Linux containers have lower overhead and better performance
AM

because they share the same kernel and operating system resources.

Isolation

Hypervisors provide stronger isolation between virtual machines because


each virtual machine has its own hardware resources and kernel. In contrast,
Linux containers provide weaker isolation because they share the same kernel
and operating system resources, although containerization technologies like
groups and namespaces provide a degree of isolation.
Virtualization is being pursued with great attention by numerous IT
businesses. One of the main benefits of virtualization for platforms that
support remote working is their integration with the cloud.

1. Cheap

IT infrastructures find virtualization to be a more affordable implementation


option because it doesn't require the use or installation of actual hardware
components. Dedicating substantial amounts of space and money to create

RB
an on-site resource is no longer required. We need a licence or access from a
third-party vendor to begin using the hardware, just as if it were locally
produced.

2. Efficient
TH
By downloading the new versions of the software and hardware from a
third-party supplier, efficient virtualization also enables automatic upgrades of
both. By handling the problem themselves and saving money, IT specialists
are able to avoid having to hire specialists. Virtualization also lessens the
difficulty of managing resources to increase the effectiveness of virtual
RU

environments.

3. Disaster recovery

When servers are virtualized, disaster recovery is relatively simple thanks to


AM

fast backup restoration and current snapshots of your virtual machines.


Organizations were better able to create a low-cost replication location thanks
to virtualization. If a disaster occurs in the data centre or server room itself,
you can still relocate such virtual machines to a cloud provider. Having the
flexibility level guarantees that the disaster recovery plan will be simpler to
implement and will have a 99% success rate.

4. Deployment

Resources may be deployed much more quickly when employing virtualization


technology. It is feasible to significantly reduce the amount of time required for
setting up physical devices or creating local networks. As a result, users really
need is at least one connection to the virtual world.
5. Encourages digital entrepreneurship

Prior to widespread virtualization, the average person found it nearly


impossible to start a digital business. Thanks to the multiple networks,
servers, and storage devices that are now accessible, almost anyone can start
their own side business or turn into a business owner. Everyone can hang out
their shingle and start looking for employment.

6. Saves energy

Both individuals and businesses can save energy by using virtualization. The

RB
rate of energy consumption can be reduced because no local hardware or
software alternatives are being employed. To boost the total ROI of
virtualization, monies can be used over time for other operational expenses
rather than paying for a data centre's cooling costs and equipment operation
costs.

7. improved uptime
TH
Virtualization technologies have increased uptime dramatically. An uptime of
99.9999% is offered by some providers. Even low-cost carriers now offer
uptime at a rate of 99.99%.
RU

8. Consistent cost

People and corporations can have predictable expenses for their IT


requirements because third-party vendors frequently offer choices for
virtualization.
AM

9. Improved security

Virtualization can improve security by isolating applications and data from


each other. This means that if one virtual machine is compromised, it does not
affect the other virtual machines on the same physical machine.
OPERATING SYSTEM

ACTIVITY - 03

1. Compare ex2/ex3 file system attributes

Linux File System Format

RB
The Linux File System is a structured collection of files on a disk drive or a
partition. It is used for data management, and the partition contains specific
data. The purpose behind systematic data storage is that it can quickly access
files. It manages all the information, including file size, creation date, file
name, etc.

Linux File System Format supports Windows operating systems. It supports


TH
Ext2, Ext3, Ext4, JFSm ReiserFS, XFS, btrfs and swap file system.

Ext2
RU

The Ext2 is defined as a second extended file system. It was introduced in


1993, and it is the first commercial file system designed to overcome the
limitation of the Ext file system.
Ext2 does not have a journaling feature, and it is recommended for flash
drives and USB.
AM

The individual file size that Ext2 supports is 2TB and can be from 4TB to 32
TB depending upon block size.

Pros
● It supports a maximum file size of 4TB
● The maximum file name length is 255 bytes characters.
● It can track the state of the file system.

Cons
● Includes a waste block size
● No file journaling
Ext3

Ext3 refers to the third extended file system. This file journaling system is
used on multiple Linux distributions.
It can track all the changes made with Ext3 to improve reliability and reduce
possible file system corruption.
In addition, it allows you to upgrade from Ext2 without the need to back up
and restore data.

RB
Ext2 and Ext3 use e2fsprogs as a standard utility. It makes the conversation
between both the file systems easier and smooth.
Ext3 is designed with new features such as journal, online file system growth,
and HTree indexing large directories.
Ext3 used less CPU power as compared to other Linux file systems. It is
TH
relatively safer and can easily recover data.

Pros
● The filename supports all characters except NULL and '/.'
RU

● Journal, order, and writeback are available.


● You can convert Ext2 to Ext3 files without backup and restore files
● Basic multiple book allocation
● Second-time stamp
● It makes the updates safer because the journal makes the updates look
AM

atomic

Cons
● Lacks basic features to extend, dynamic, allocation, inode, and block
sub-allocation
● Hard to recover deleted files
● Write a journal on a storage device with an extra cache.
● Gives no snapshot support
What's the Difference Between Ext 2 and Ext 3

Feature Ext2 Ext3

Individual File Size 16GB-2TB 16GB-2TB

Volume file system size 4TB-32TB 4TB-32TB

RB
Default inode size 128 bytes 128 bytes

Time Stamp No support Second

Defragmentation No No
TH
Directory Indexing Disabled Disabled

Multiple Block Allocation Basic Basic


RU

In-core
Preallocation No
reservation

Delayed Allocation No No
AM
2. Discuss the file- mount and unmount system calls

In an operating system, mount and unmount system calls are used to attach
and detach file systems respectively.

Mount

Mounting a file system is the process of making it accessible to the operating


system and applications. When a file system is mounted, it becomes part of
the file hierarchy, and its files and directories can be accessed by the user. In
Unix-like operating systems, the mount system call is used to attach a file

RB
system to a specific directory in the file hierarchy.

For example, if a user wants to mount a USB flash drive to the /mnt directory,
they would use the following command:

bash
TH
mount /dev/sdb1 /mnt

In this command, /dev/sdb1 is the device file for the USB flash drive and /mnt
is the directory where the file system will be mounted. Once the file system is
mounted, the user can access its files and directories using the /mnt directory.
RU

Unmount

Unmounting a file system is the process of detaching it from the file hierarchy
and making it inaccessible to the operating system and applications. This is an
AM

important step before removing the storage device, as it ensures that all
changes to the file system have been saved and that there are no open files
or processes accessing it.

For example, if a user wants to unmount the USB flash drive mounted on the
/mnt directory, they would use the following command:

bash
umount /mnt

In this command, /mnt is the directory where the file system is mounted. Once
the file system is unmounted, the user can safely remove the USB flash drive
from the system.

You might also like