OSYMICROPROJECTFINAL
OSYMICROPROJECTFINAL
Micro-Project On
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
MAHARASHTRA STATE
BOARD OF TECHNICAL
EDUCATION
Certificate
th
This is to certify that Mr./Ms. of 5 Semester of Diploma in COMPUTER TECHNOLOGY of
Institute, SHIVAJIRAO SAMARTH JONDHALE POLYTECHNIC (Code:0147) has completed the
Micro Project satisfactorily in Subject: OSY for the academic year (2022- 2023) as prescribed in
the curriculum.
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
II
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
INDEX
I
1 TITLE
CERTIFICATE II
2
III
INDEX
3
4 ABSTRACT 1
5
INTRODUCTION 2
6 LITERATURE SURVEY 3
7
PROPOSED SYSTEM 4
PAGE REPLACEMENT 5
8
ALGORITM
9 CONCLUSION 9
10 REFERENCE 9
III
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
ABSTRACT
operating system (OS), Software that controls the operation of a computer, directs the input
and output of data, keeps track of files, and controls the processing of computer programs. Its
roles include managing the functioning of the computer hardware, running the applications
programs, serving as an interface between the computer and the user, and allocating computer
resources to various functions. When several jobs reside in the computer simultaneously and
share resources (multitasking), the OS allocates fixed amounts of CPU time and memory in
turn or allows one job to read data while another writes to a printer and still another performs
computations. Through a process called time-sharing, a large computer can handle interaction
with hundreds of users simultaneously, giving each the perception of being the sole user.
Modern computer operating systems are becoming increasingly machine-independent,
capable of running on any hardware platform; a widely used platform-independent operating
system in use today on mainframe computers is UNIX. Most personal computers run on
Microsoft’s Windows operating system, which grew out of and eventually replaced MS-
DOS. The operating system is the performance of a computer system hardware abstraction,
through which people control the hardware, and to use the resources of the computer system.
Course groups is proposed, using a variety of measures to uphold the theory and practice,
both innovative strategies to improve teaching effectiveness, develop computer applications
personnel. In order to cultivate the students' basic knowledge, practical ability, innovation
and system design capability for the subject to course through software and hardware as a
method.
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
1
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
1. INTRODUCTION
An operating system (OS) manages all other applications and programs in a computer, and it is
loaded into the computer by a boot program. It enables applications to interact with a
computer’s hardware. Through a designated application programmer interface, the application
programmers request services from the operating system (API). The kernel is the software that
contains the operating system’s core components. To run other programmers, every computer
has to have at least one operating system installed.
Operating System
Windows, Linux, and Android are examples of operating systems that enable the user to use
programs like MS Office, Notepad, and games on the computer or mobile phone. It is
necessary to have at least one operating system installed in the computer in order to run basic
programs like browsers.
• An operating system (OS) is the programme that controls all other
application programmes in a computer after being installed into the system first
by a boot programme.
• Running system (OS), Computer operating system software that coordinates data
input and output, manages files, and regulates the execution of computer
programmes
Page Replacement Algorithm decides which page to remove, also called swap out when a new
page needs to be loaded into the main memory. Page Replacement happens when a requested
page is not present in the main memory and the available space is not sufficient for allocation
to the requested page.When the page that was selected for replacement was paged out, and
referenced again, it has to read in from disk, and this requires for I/O completion. This process
determines the quality of the page replacement algorithm: the lesser the time waiting for page-
ins, the better is the algorithm.A page replacement algorithm tries to select which pages
should be replaced so as to minimize the total number of page misses. There are many
different page replacement algorithms. These algorithms are evaluated by running them on a
particular string of memory reference and computing the number of page faults. The fewer is
the page faults the better is the algorithm for that situation.Page Replacement Algorithms are
First In First Out (FIFO),Least Recently Used (LRU) & Optimal Page Replacement.
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
2. LITERATURE SURVEY
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
3. PROPOSED SYSTEM
In this research, we proposed a new concept for page replacement, which is based on block
reading of pages from the secondary store-age. As we know that disc, access is time consuming
because of the complex mechanism of secondary storage, which lead to slow processing of
data. It is always better to read a block of data whenever there is frequent disc access. In
my research, whenever there will be a page fault, instead of reading a missed page only, I
retrieve asset of pages equal to number of frames allotted for that process. By this way, we can
definitely minimize number of page miss, which will improve hit ratio too.
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
Page replacement algorithms are the techniques using which an Operating System decides
which memory pages to swap out, write to disk when a page of memory needs to be allocated.
Paging happens whenever a page fault occurs and a free page cannot be used for allocation
purpose accounting to reason that pages are not available or the number of free pages is lower
than required pages. When the page that was selected for replacement and was paged out, is
referenced again, it has to read in from disk, and this requires for I/O completion. This process
determines the quality of the page replacement algorithm: the lesser the time waiting for page-
ins, the better is the algorithm. A page replacement algorithm looks at the limited information
about accessing the pages provided by hardware, and tries to select which pages should be
replaced to minimize the total number of page misses, while balancing it with the costs of
primary storage and processor time of the algorithm itself. There are many different page
replacement algorithms. We evaluate an algorithm by running it on a particular string of
memory reference and computing the number of page faults.
FIFO (First in First out) Page Replacement Algorithm − It is one of the simplest page
replacement algorithm. The oldest page, which has spent the longest time in memory is
chosen and replaced. This algorithm is implemented with the help of FIFO queue to hold
the pages in memory. A page is inserted at the rear end of the queue and is replaced at
the front of the queue. Advantages and disadvantages of FIFO Algorithm:- FIFO is easy
to understand, It is very easy to implement, Not always good at performance. It may
replace an active page to bring a new one and thus may cause a page fault of that
page immediately.
EXAMPLE
5
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
Implementation FIFO
LRU (Least Recently Used) Algorithm − The Least Recently algorithm replaces the page that has
not been used for the longest period of time. It is based on the observation that pages that have
not been used for long time will probably remain unused for the longest time and are to be
replaced.
Advantages and disadvantages of LRU Algorithm:-
Implementation
LRU
1-frame= No of page fault -20
2-frame= No of page fault -17
3-frame= No of page fault - 12
4-frame= No of page fault – 8
5-frame=No of page fault -7
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
EXAMPLE
Imlementation OPR
1-frame=No of page fault-20
2-frame=No of page fault-13
3-frame=No of page fault-9
4-frame=No of page fault-8
5-frame=No of page fault-7
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
String 2-1 2 3 4 2 1 5 6 2 1 2 3 7 6 3 2 1 2 3 6
1-FRAME 20 20 20
STING 1
2-FRAME 15 17 13
3-FRAME 15 12 9
4-FRAME 10 8 8
5-FRAME 9 7 7
1-FRAME 20 20 20
STRING 2
2-FRAME 18 18 15
3-FRAME 15 16 11
4-FRAME 10 14 8
5-FRAME 8 10 7
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
CONCLUSION:
REFERENCES
Textbook/OSY
https://www.geeksforgeeks.org/operating-systems/
https://www.educba.com/operating-system/
https://www.wikipedia.com
Computer Department
Shivajirao.S.Jondhale Polytechnic, Ambernath
Program Title: Make a comparative statement to calculate page fault for given reference string by
using different page replacement algorithm.
10
Computer Department