Linux Notes
Linux Notes
Virtualization:
Virtualization is a technique of how to separate a service from the
underlying physical delivery of that service. It is the process of
creating a virtual version of something like computer hardware. It
was initially developed during the mainframe era. It involves using
specialized software to create a virtual or software-created version of
a computing resource rather than the actual version of the same
resource. With the help of Virtualization, multiple operating systems
and applications can run on the same machine and its same
hardware at the same time, increasing the utilization and flexibility of
hardware.
Operating-system-level virtualization is a server virtualization method
in which an operating system’s kernel allows multiple isolated user-
space instances, instead of just one. Such instances, which are
sometimes called containers, software containers, virtualization
engines (VEs), or jails (FreeBSD jail or chroot jail), may look and feel
like a real server from the point of view of its owners and users.
Hypervisor:
A hypervisor is a critical software layer that facilitates the creation
and management of virtual machines (VMs) on physical computer
hardware. Its primary function is to abstract and virtualize the
underlying hardware resources (like CPU, memory, storage, and
networking) so that multiple virtualized environments, each running
its own operating system, can coexist on a single physical machine.
There are two primary types of hypervisors:
1. Type 1 Hypervisor (Bare Metal):
- This hypervisor directly runs on the underlying physical hardware,
without the need for a host operating system.
- Examples of Type 1 hypervisors include: VMware ESXi, Microsoft
Hyper-V, and Citrix XenServer.
- They offer efficient resource utilization as they manage hardware
resources directly.
2. Type 2 Hypervisor (Hosted):
- This hypervisor runs on top of a host operating system.
- It leverages the host OS for managing hardware resources and
provides virtualization capabilities above it.
- Examples of Type 2 hypervisors include: VMware Workstation,
Oracle VirtualBox, and Parallels Desktop.
- They are easier to set up and suitable for desktop or testing
environments.
Linux Commands:
pwd – present working directory.
ls – show directories and files in pd.
cd – used to change directory.
mkdir – creates a directory.
rmdir - Removes empty directories from the directory lists.
rm – delete files and directories.
--help – is an option to show (help) details about the command.
man - access manual for commands.
cp – copies directories.
mv – replace directories.
uname - shows basic information about the OS.
cal – shows calendar.
date – show date, time and day.
whoami – shows the current user.
touch – create empty files.
cat – displays the file content.
clear – clear the terminal.
echo – display active processes on the terminal (prints strings
and variables)
grep - search for a specific string in an output.
history – shows history of commands.
heads - display the first 10 lines of a file.
tail - display the last 10 lines of a file.
find - search for a file or directory in the real system.
alias – give alias name to bigger commands.
unalias – undo alias.
wc – command to count words.
tar – used to compress files.
> - used to redirect in new file.
>> - used to redirect in already created file.
Types of Shells:
1. sh
2. csh
3. zsh
4. bash – Born Again Shell
5. fish
USER
Types:-
1. Super User – root {UID = 0}
2. System User – UID = 1-999
3. General User – UID = 1000 - *
GROUP
Types:-
1. Primary Group – made while creation of the user.
2. Supplementary Group – upto 15 can be made.