Department of : Subject of:
Computer Systems Engineering Operatin g System s Design Concepts
Mehran University of Engineering & Year 3RD Semester 5TH
Technology
Batch F-16CS Duration 03
Hours
Jamshoro
Lab 2: Installation of Linux Distribution
Outlines
• Linux
• Uses of Linux OS
• Basic Linux Features
• Kernel Mode Vs User Mode
• Linux System Architecture
• Linux File System
• Linux Distributions
• Introduction to Ubuntu OS
• Ubuntu Minimum System Requirements
• Installing Ubuntu
• Exercise
Requirements
• Computer System
• Operating System Ubuntu 16.04.1 Desktop Iso Image
• Wubi Installer
• USB minimum 8GB space
• Universal USB Installer/ Power ISO
1
LINUX
Linux was developed by "Linus Torvalds" at the University of Helsinki, with
the help of UNIX programmers from across the Internet.
Just like Windows XP, Windows 7, Windows 8, and Mac OS X, Linux is an
operating system and usually comes bundled with free and open source
software.
Linux is a generic term referring to Unix-like computer operating systems
based on the Linux kernel.
The development of Linux is one of the most prominent examples of free and
open source software collaboration; typically, all the underlying source code
can be used, freely modified, and redistributed by anyone.
Linux is an open-source, free operating system that we will be used to better
understand the concepts and techniques in this operating systems course.
Linux is written primarily in C Language.
From smartphones to cars, supercomputers and home appliances, the Linux
operating system is everywhere.
Linux is actually everywhere. It’s in your phones, in your cars, in your
refrigerators. It runs most of the Internet, the supercomputers making
scientific breakthroughs, and the world's stock exchanges. But before
Linux became the platform to run desktops, servers, and embedded
systems across the globe, it was (and still is) one of the most reliable, secure,
and worry-free operating systems available.
Unix is an operating system that originated at Bell Labs in 1969 as an
interactive time-sharing system.
Unix became the first operating system written in the C language.
2
USES OF LINUX OS
• Linux is used for a variety of applications
• File and Print Server
• E-mail Server
• Fax Server
• Internet Gateway
• Database Server
• ISP Server
• Application Server
• Desktop OS
BASIC LINUX FEATURES
Linux systems excel in many areas, ranging from end user concern such as stability,
speed, and ease of use, to serious concerns such as development and networking.
Some important feature of Linux are:
• Multiprogramming, Multitasking, Timesharing, Multiuser
• High speed
• Support for programming languages
• Virtual memory • Licensing
• Shared libraries
• Portable
• Open Source
• Hierarchical File System
• Shell
• Security
3
KERNEL MODE VS USER MODE
In Kernel mode, the executing code has complete and unrestricted access to
the underlying hardware. It can execute any CPU instruction and reference
any memory address. Kernel mode is generally reserved for the lowest-level,
most trusted functions of the operating system. Crashes in kernel mode are
catastrophic; they will halt the entire PC.
User programs and other system programs works in User Mode which has
no access to system hardware and kernel code.
LINUX SYSTEM ARCHITECTURE
The architecture of a Linux System consists of the following layers:
USER INTERFACE
The user interface (UI) is everything designed into an information device with
which a human being may interact. Two types CLI (Command line interface) and
GUI (Graphical User Interface).
SHELL
An interface to kernel; hides complexity of kernel’s functions from users. Takes
commands from user and executes kernel’s functions.
KERNEL
This is the one piece of the whole that is actually called “Linux”. Kernel is a Core
component of operating system, interacts directly with hardware and provides low
level services to upper layer components. The central nervous system of the Linux
is kernel, the operating system code that runs the whole computer.
4
The kernel is the core of the system and manages the CPU, memory, and peripheral
devices.
HARDWARE LAYER:
Hardware consists of all peripheral devices (RAM/ HDD/ CPU etc).
LINUX FILE SYSTEM
The way the files of an operating system are organized on the disk. All the files are
grouped together in the directory structure. The file-system is arranged in a
hierarchical structure, like an inverted tree. The top of the hierarchy is
traditionally called root (written as a slash /). Linux sorts directories descending
from the root directory according to their importance to the boot process. The File
system hierarchy standard (FHS) governs the unified file system for Linux by
defining a standard set of directories, sub-directories and files. Linux is case
sensitive operating system.
5
LINUX DISTRIBUTIONS
Linux has a number of different versions to suit nearly any type of user. From new
users to hard-core users, you’ll find a “flavor” of Linux to match your needs. These
versions are called distributions (or, in the short form, “distros.”) Nearly every
distribution of Linux can be downloaded for free, burned onto disk (or USB thumb
drive), and installed (on as many machines as you like).
The most popular Linux distributions are:
Ubuntu Linux
6
Linux Mint
Arch Linux
Deepin
Fedora
Debian
openSUSE.
Each distribution has a different take on the desktop. Some opt for very modern
user interfaces such as Ubuntu whereas others stick with a more traditional
desktop environment openSUSE.
INTRODUCTION TO UBUNTU OS
Ubuntu is an ancient African word meaning 'humanity to others'. Ubuntu is a
Debian based Linux operating system (Debian is a computer operating
system that is composed entirely of free software) with Unity as its default
desktop environment. Ubuntu is composed of many software packages, the
majority of which are free software. Free software gives users the freedom to
7
study, adapt/modify, and distribute it. Ubuntu can also run proprietary software.
Ubuntu comes installed with a wide range of software that includes LibreOffice,
Firefox, Empathy, Transmission, and several lightweight games (such as Sudoku
and chess). Ubuntu Official started sending out free compact discs with Ubuntu
Linux in 2004 and quickly became popular for home users (many switching from
Microsoft Windows).
Why use Linux
This is the one question that most people ask. Why bother learning a completely
different computing environment, when the operating system that ships with most
desktops, laptops, and servers works just fine? To answer that question, here is
one another question. Does that operating system you’re currently
using really work “just fine”? Or are you constantly battling viruses, malware,
slowdowns, crashes, costly repairs, and licensing fees?
If you struggle with the above, and want to free yourself from the constant fear of
losing data or having to take your computer in for the “yearly clean up,” Linux
might be the perfect platform for you. Linux has evolved into one of the most
reliable computer ecosystems on the planet. Combine that reliability with zero cost
of entry and you have the perfect solution for a desktop platform. You can install
Linux on as many computers as you like without paying a penny for software or
server licensing.
UBUNTU MINIMUM SYSTEM REQUIREMENTS
For the Ubuntu desktop release 16.04.1 LTS, a PC is recommended with at least:
• 2 GHz dual core processor
• 2 GB of RAM
• 25 GB of free disk space
8
INSTALLING UBUNTU
There are many methods through which you can install Ubuntu in your system.
DOWNLOAD UBUNTU
For downloading Ubuntu’s latest ISO image just go to the following links and
download. Use either official site or BitTorrent.
[Link]
[Link]
9
METHOD 01: USING WUBI INSTALLER
DOWNLOAD WUBI INSTALLER
For downloading Wubi installer just go to the following link:
[Link]
Make sure that:
• Downloaded version of the wubi and Ubuntu image should be same
• Both setups should be at the same location
Now double click on the wubi installer and follow the steps below:
Put the username and password then install, it will extract the files.
1
0
11
Select Reboot now and click Finish. Your computer restarts and the Ubuntu
installation process will automatically will be started.
After completing this, the Windows Boot Manager appears.
Using your keyboard’s up and down arrow keys, select Ubuntu and press Enter.
Ubuntu OS will be booted.
12
NOTE: Since Wubi installs Ubuntu on the same file partition as Windows, there may
be a slight degradation in Ubuntu’s performance over time due to file
fragmentation.
METHOD 02: USING BOOTABLE USB STICK
DOWNLOAD UNIVERSAL USB INSTALLER
The easiest way to get up running with USB is to use the USB installer provided by
[Link].
Download the latest version of Universal USB Installer from the following link:
[Link]
13
CREATING BOOTABLE USB
After finishing download, you should have the ISO image of Ubuntu. Now insert a
USB stick with 8GB of free space, and follow the steps below:
14
Or you can make your USB bootable using Power ISO tool. Power ISO
is a powerful CD / DVD / BD image file processing tool.
For downloading Power ISO, Just go to the following link:
[Link]
In order to install Ubuntu with dual boot option you need to go to the “disk
management” and shrink the volume depending on you. In this case 35000 MBs
shrinked:
15
After shrinking you will have an unallocated space:
Now restart your computer, run “BIOS”, go for the “boot options” and disable fast
boot option.
Select “Bootable USB”, select the option “Install Ubuntu” it will start the installation
process:
16
Follow the steps below:
Continue…..
17
Continue….
Check on “Something else” then continue….
1
8
Now select the free space then click on “+” button…
Keep 2000 MBs for the “swapping area” remaining for the “Ext4 journaling file
system”
Again do this for creating the partition for “swapping area”
19
“Ok” then “Install now”
Continue…
Select the region then Continue…
2
0
Continue…
Insert “username” and “password” then Continue…
21
Restart now
Here you have dual options for booting the operating system
2
2
METHOD 03: Another way of creating bootable USB:
Search for “diskpart”
Click on Yes
2
3
Type list disk
It shows all the disks on your computer. Don’t go for Disk 0! It is for hard
disk.
Go for Disk 1
Type clean
2
4
Create Primary partition
Mark the created partition
Exit window.
Select the USB from This Pc and format it.
2
5
Copy all files of wubi installer to USB
Insert USB in your computer and restart PC.
METHOD 03: USING Oracle Virtual Machine (OVM)
What’s a Virtual Machine?
A virtual machine app creates a virtualized environment—called, simply enough, a
virtual machine—that behaves like a separate computer system, complete with virtual
hardware devices. The VM runs as a process in a window on your current operating
system.
In the VM world, the operating system running on your computer is called the host and
any operating systems running inside VMs are called guests. It helps keep things from
getting too confusing.
Setting Up a Virtual Machine
Open your VM app and click the button to create a new virtual machine.
2
6
You’ll be guided through the process by a wizard that first asks which OS you’ll be
installing. If you type the name of the OS in the “Name” box, the app will most likely
automatically select the type and version for the OS. If it doesn’t—or it guesses wrong—
select those items yourself from the dropdown menus. When you’re done, click “Next.”
2
7
Based on the OS you plan to install, the wizard will preselect some default
settings for you, but you can change them over the screens that follow. You’ll be
asked how much memory to allocate to the VM. If you want something other
than the default, select it here. Otherwise, just click “Next.” And don’t worry,
you’ll be able to change this value later if you need to.
The wizard will also create the virtual hard disk file to be used by the VM.
Unless you already have a virtual hard disk file you want to use, just select the
option to create a new one.
2
8
You’ll also be asked whether to create a dynamically allocated or fixed size disk.
With a dynamically allocated disk, you’ll set a maximum disk size, but the file
will only grow to that size as it needs to. With a fixed size disk, you’ll also set a
size, but the file created will be that large from its creation.
We recommend creating fixed size disks because, while they eat up a little more
disk space, they also perform better making your VM feel a bit more
responsive. Plus, you’ll know how much disk space you’ve used and won’t get
surprised when your VM files start growing.
2
9
You’ll then be able to set the size of the virtual disk. You’re free to go with the default
setting or change the size to suit your needs. Once you click “Create,” the virtual hard
disk is created.
3
0
After that, you’re dumped back into the main VM app window, where your new VM
should show up. Make sure the installation media you need is available to the machine—
usually this involves pointing to an ISO file or real disc through the VM’s settings. You
can run your new VM by selecting it and hitting “Start.”
How to attach an ISO to a Virtual Machine
Right-click on the newly created virtual machine entry (in the left pane of VirtualBox
Manager) and then click Settings button.
31
In the left-pane of Settings, click Storage, double-click on the Controller (located
under Storage tree) to expand the same and see newly created virtual hard drive entry.
3
2
Under IDE Controller There should be an icon that shows a CD with a + sign on it, to
create a new disc drive as shown highlighted in yellow color in the below snapshot:
A box will come up, click Choose Disk and then choose your .iso file.
3
3
EXERCISE
Q1: Using which method did you install Ubuntu? Also list the steps.
Q2: Did you face any problem while installing Ubuntu? (If yes, list the
problems)
Q3: Explain briefly the concept of proprietary. List some proprietary
software by Linux.
Q4: List security features of LINUX.
Q5: List devices that run on LINUX.
3
4
3
5