Operating Systems: Comparison of Various Operating System
Operating Systems: Comparison of Various Operating System
COMPARISON OF
VARIOUS OPERATING
SYSTEM
PRESENTED BY
• An operating system acts as an intermediary between the user of a computer and computer
hardware. The purpose of an operating system is to provide an environment in which a user
can execute programs conveniently and efficiently.
• An operating system is a software that manages computer hardware. The hardware must
provide appropriate mechanisms to ensure the correct operation of the computer system and
to prevent user programs from interfering with the proper operation of the system
Popular Operating Systems are
•1. MS-DOS:
• MS-DOS which is short for Microsoft Disk Operating System is a non-graphical command
line operating system developed for IBM compatible computers with x86 microprocessor.
The operating system used a command line interface for the user to input commands to
navigate, open and manipulate files on their computer.
FEATURES
It is a single user operating system meaning only one user can operate at a time.
It is a light weight operating system allowing users to have direct access to the BIOS and its
underlying hardware.
Loads data and programs from external sources and bring them into the internal memory so
they can be used on the computer.
Enables the computer to perform input and output operations such as taking commands from
keyboard, printing information on the screen.
It is very helpful in making file management like creating, editing, deleting files, etc.
It also controls and manages other external devices such as the printer, keyboard or external
hard drive using various drive utilities.
Drawbacks:
It does not support graphical interface hence mouse cannot be used to operate it.
It does not support multiprogramming meaning it can only have one process in the
ram.
It has difficulty in memory access when addressing more than 640 MB of RAM
WINDOWS
It comes preloaded with many productivity tools which helps to complete all types of
everyday tasks on your computer.
Windows has a very large user base so there is a much larger selection of available software
programs, utilities.
Windows is backward compatible meaning old programs can run on newer versions.
Hardware is automatically detected eliminating need of manually installing any device drivers .
Drawbacks:
Windows can be expensive since the OS is paid license and majority of its applications are
paid products.
Windows has high computer resource requirement like it should have high ram capacity, a
lot of hard drive space and good graphics card.
Windows slows and hangs up if the user loads up many programs at the same time.
Windows includes network sharing that can be useful if user has a network with many PCs.
Windows is vulnerable to virus attacks since it has a huge user base and users have to
update OS to keep up-to-date with security patches.
LINUX
• The Linux OS is an open source operating system project that is a freely
distributed, cross-platform operating system developed based on UNIX.
This operating system is developed by Linus Torvalds. The name Linux
comes from the Linux kernel. It is basically the system software on a
computer that allows apps and users to perform some specific task on the
computer. The development of Linux operating system pioneered the open
source development and became the symbol of software collaboration.
FEATURES
Linux is free can be downloaded from the Internet or redistribute it under GNU licenses and
has the best community support.
Linux OS is easily portable which means it can be installed on various types of devices like
mobile, tablet computers.
BASH is the Linux interpreter program which can be used to execute commands.
Linux provides multiple levels of file structures i.e. hierarchical structure in which all the files
required by the system and those that are created by the user are arranged.
Linux provides user security using authentication features and also threat detection and
solution is very fast because Linux is mainly community driven.
Drawbacks:
There’s no standard edition of Linux hence confusing for users and also becoming familiar
with the Linux may be a problem for new users.
More difficult to find applications to support user needs since Linux does not dominate
the market.
Since some applications are developed specifically for Windows and Mac, those might not
be compatible with linux and sometimes users might not have much of a choice to choose
between different applications like in Windows or Mac since most apps are developed for
operating systems that have a huge user base.
Some hardware may not be incompatible with Linux since it has patchier support for
drivers which may result in malfunction.
UNIX
The UNIX is an Operating System that is truly the base of all Operating Systems like
Ubuntu, Solaris, POSIX, etc. It was developed in the 1970s by Ken Thompson, Dennis Ritchie,
and others in the AT&T Laboratories. It was originally meant for programmers developing
software rather than non-programmers.
Unix and the C were found by AT&T and distributed to government and academic institutions,
which led to both being ported to a wider variety of machine families than any other
operating system. The main focus that was brought by the developers in this operating
system was the Kernel. Unix was considered to be the heart of the operating System.
.
FEATURES
•Fu ll m u lt i t a s k i n g w i t h p r o t e c t e d me mo r y . M u lt i p le u s e rs c a n ru n m ul ti p l e p r o gr a m s ea c h a t th e s a m e t im e
w i t ho u t i n t e rf e r in g w i t h e a c h o t h e r o r c r a s h i ng t h e s y st em .
•V e ry e f f i c i e nt v ir t u a l m e m o ry , s o m a n y p ro g r a m s c a n r u n w i th a m o d e st a mo u nt o f p h ys i ca l m e mo r y.
•A c c e s s c o n t r o l s a n d s e c u r i t y . A l l u s e r s mu s t b e a u t h e n t i c a te d b y a v a l i d a cco u nt a n d p a s s w o r d t o u s e
t h e s y s t e m a t a ll A r i c h s e t o f s m a l l c o m m a n d s a nd u t il i t i e s th a t d o s p ec i f i c ta s ks w el l -- no t c lu tt ere d
u p w i t h lo t s o f s p e c i a l o p t i o n s . U ni x i s a w e l l- s t o c k e d t o o lb o x, no t a gi a nt d o -i t-a ll S w is s A r my K n i f e.
•A b i li t y t o s t r i ng c o m m a n d s a nd u t i li t ie s t o g e t h e r in u nl i m i ted w a ys t o a c co m p li s h m o r e co m p l i ca t ed t a s ks
- - no t l im i t e d t o p re c o nf ig u r e d c o m b i na t i o ns o r m e n u s , a s i n p er s o na l c o m p ut er s ys t ems .
•A p o w e r f u ll y u ni f ie d f il e s y st e m . E v e r y t h i n g i s a f i le : d a ta , p r o gr a ms , a n d a l l p h ys i ca l d ev i ces . E nt ir e
f i le s y s t e m a p p e a rs a s a s in g le l a r g e t r e e o f n e s t e d d i r ect o r i es , reg a rd les s o f h o w ma ny d if f er en t
p h y s i c a l d e v i c e s ( d i s k s ) a r e in c l u d e d .
Drawbacks:
• The traditional command line shell interface is user hostile -- des igned for the
programmer, not the casual user.
• Commands often have cryptic names and g ive very little response to tell the user what
they are doing . Much use of special keyboard characters - little typos have unexpected
results.
• To use Unix well, you need to understand some of the main design features. Its power
comes from knowing how to make commands and programs interact with each other, not
just from treating each as a fixed black box.
• Richness of utilities (over 400 standard ones) often overwhelms novices. Documentation
is short on examples and tutorials to help you fig ure out how to use the many tools
provided to accomplish various kinds of tasks.
ANDROID
• Android is the mobile operating system developed by Google. These days android is a
very popular OS in the market. Over 2 million apps are available in g oogle play store to
download and install on the android device. Android OS is used by about 2 billion people
all over the world and this is most used OS nowadays. There is a large range of devices
which use android including watches, cars audio player, android TV, PC, tablets and
smartphones. Android was first time named by Android Inc. then Google acquired android
in 2005 in $50 million. Most of the an droid core developers were hired by Google and
they built more features in the software. In early days android only supports physical
QUERTY keyboards and was not touch screen. But when mobile companies started
laun ching touch screen mobiles then Google decided to launch android OS that only
supports touch screens. Later Google marketed its mobile OS to mobile companies and it
becomes renowned.
Features
Millions of apps:-
• Users have a vast choice to choose which apps they need. Apps are categorized into topics and every topic has
large amount of apps to download.
• You can also install third-party apps. These apps can be downloaded from different websites. Users are flexible in
choosing which apps they want to download either from google play store or any other website. You just need to
authorize the app to be downloaded.
• All the notifications of apps, messages, emails, low battery are displayed nicely. Users can access the notification
by just sliding from top to bottom. You can also see the notifications in lock mode.
• With a mobile hotspot, you can share your device internet with other devices or with PC. This can help saving
money also. If you living in a house then you can share your internet with your family members and they don’t need
to buy separate internet packages.
Drawbacks
Apps run in the background:-
• In the older version of Android, most apps always run in the background and come to foreground as they
wish. But in new version of android apps cannot automatically come to foreground. As some apps run in
the background then it consumes mobile battery and your device battery vanishes quickly.
• Learning and developing android apps is hard because there are a variety of screen sizes and to make
app adaptive to all screen sizes is challenging for the developers
• As android is a very large operating system that consumes lot of storage and some default apps also
comes with operating system so low specification devices run slow.
Virus protection:-
• iOS has this tremendous advantage of being very simple and compatible with each subsequent upgrade.
• Letting users multi-task is surely one of the big draws that the iOS has over and above any other operating system.
Those wanting to work on their iPhones or iPads can continue to do so while listening to music without any interruption.
• Big time fans of iPhones will vouch for the fact that these devices generate less heat even when in use for long hours.
The reason for this is that iPhone batteries are known to be far more efficient and generate less heat than those that
run on other operating systems. A lot of users prefer the operating system and its proprietary devices only because
they can continue to play games uninterrupted for long hours without heating issues.
• Apple phones and other devices offer hassle-free use because of the strict security processes that the platform offers.
Devices running on this platform do not have chances of contracting virus or other malicious codes as apps and features
are tested for the specific platform before being loaded for use. Both fingerprint and face detection sensors are
supported by the platform ensuring double security checks.
Drawbacks
No widget support for iOS apps that are also costly
• iOS supports only apps made specifically for the platform and does not support any external widgets to enhance their
features. Moreover, with so many restrictions, apps made for the iOS have to fulfill several specifications that
naturally raise their development costs making them expensive for the end buyer.
• The platform runs only on devices made by the company and so there is a limitation when it comes to using devices
running on iOS. As a user, even if you like the additional feature that any other device outside the company offers,
you’re not in a position to use it as iOS runs only on hardware coming from the Apple factory.
• NFC is the feature that enables communication between devices close by. But the sad part is that iOS devices do not
support NFC. Also, unlike devices running on other platforms, Apple phones do not come with radio pre-loaded on them.
Users wanting to listen to radio on the iPhones have to do so by downloading radio apps.
App sizes are usually too big consuming too much space
• With specific features and characteristics made specifically for the iOS, apps made for the platform become very heavy
taking up a lot of storage space of the device.!
Windows Linux UNIX Android iOS
Manufacturer Microsoft Inc. Linux is developed as Three biggest distributions are Open source OS Apple Inc. closed,
open source OS under Solaris running (Oracle), AIXon designed &developed with components
the GNU project by the (IBM) & HP-UX Hewlett Packard. by Android Inc. Google that are source
Originator, Linus And Apple Makes OSX, an Unix is now the current openly
Torvalds and many based OS owner
others.
Development and Developed and Linux is Open Sourced Unix system has various flavors, OHA (Open Handset Apple Inc.
Distribution distributed by and distributed by most of which are developed by Alliance) developed and
Microsoft. various vendors. AT&T with other commercial distributed iOS
vendors and non-profit orgs.
Computer x86, x86-64 x86, x86-64, PowerPC, Available on PA-RISC and Itanium Android-x86 powered ARM
Architecture SPARC, Alpha, Others machines. Solaris also available by AMD and Intelx86
Supported for x86/x64 based systems. OSX is processors.
PowerPC(10.0-10.5)/x86(10.4)/x6
4 (10.5-10.8)
Target System Workstation, Personal Desktop/Server Workstation, 8086 UNIX Consumer, Smartphone, music
Type Computer, Media Centre, Depends on Personal Computer, system, PDP- Enterprise, system player,
Tablet PC, Embedded. Distribution embedded 11/70 system education Tablet system/
computer
File System NTFS, FAT & exFAT with ext2, ext3, HFS+, HFS, MFS jfs, gpfs, hfs, Ext4 HFS+, FTP
Supported ISO 9660; UDF, 3rd Party ex4,ReiserFS,FAT, (Mac OS 8.0 and hfs+, ufs, xfs, zfs
driver that supports file ISO 9660,UDF, before) AFP, with format
system ext2, and ext3, NFS, and others. ISO 9660, FAT, UDF
ReiserFS, and HFS
User Friendly for Very User Friendly Depends on Very User Friendly Unix is user- Very User Very User Friendly
Lay Users Distribution. More friendly. It's just Friendly
friendlier to users choosy about
than Unix who its friends
are
ARCHITECTURE
DOS LINUX
MS-DOS operating system is split into various The Linux system basically works on 4 layers
layers and each of the layers have different
Hardware,kernel,shell,Applications.
functionalities. In DOS each layer has connected
with one another.
KERNAL :- Monolithic Kernel
Windows has 2 main components :- kernel mode The architecture of Unix is divided into kernel,
and user mode. hardware, shell, files and directories in which the
kernel manages the connections related to hardware,
applications and commands.
ANDROID
KE R N EL : - H ybrid t yp e ( XN U Kernel
o f Da rw in)
DOS WINDOWS UNIX LINUX Android IOS
MOSH
Command.com CMD Originaly bourne Bash shell Blink Shell
SHELL shell but now
compatible with
Terminal many others
DOS does not GUI is internal KDE and Gnome Common Desktop
GUI have GUI part of Windows Environment User Default
OS. Interface & user
Navigation interface ·
bookmark_b Cocoa
order Touch
UNIX ANDROID IOS
Windows Linux
Compatibility Can coexist on Linux has few Unix does not have as many Better than iOS Compatibility is
local networks programs and programs and games as Windows fair
with Windows, games like
BSD, Macs, and Windows. But is
other Unix-like more compatible
systems. More and scalable than
compatible. Unix
Process
Synchronization
Process Synchronization in Linux
Process synchronization in Linux involves providing a time slice for each process so that
they g et the required time for execution.
The process can be created using the fork() comman d in Linux. The creating process is
called the parent process and the created process is the child process. A child process
can have only one parent but a parent proces s may have many children . Both the parent
and child processes have the same memory image, open files an d environment strings.
However, they have distin ct address spaces.
There are some processes that are still running even though their parent process has terminated or
finished. These are known as orphan processes. Processes can be orphaned intentionally or
unintentionally. An intentionally orphaned process runs in the background without any manual
support. This is usually done to start an indefinitely running service or to complete a long-running
job without user attention.
An unintentionally orphaned process is created when its parent process crashes or terminates.
Unintentional orphan processes can be avoided using the process group mechanism.
Daemon Processes
Some processes run in the background and are not in the direct control of the user. These are
k n o w n a s d a e m o n p r o c e s s e s . T h e s e p r o c e s s e s a r e u s u a l l y s t a r t e d w h e n t h e s y s t e m i s bo o t s t r a p p e d
and they terminate when the system is shut down.
Usually the daemon processes have a parent process that is the init process. This is because the
i n i t p r o c e s s u s u a l l y a d o p t s t h e d a e m o n p r o c e s s a f t e r t h e p a r e n t p r o c e s s fo r k s t h e d a e m o n p r o c e s s
a n d t e r m i n a te s .
Process Synchronization in Windows
Win do ws oper ati ng syst em is a multith read ed ker nel t ha t pro vid e s uppo r t for real t ime
applicatio n a nd multiproce ssors. On un iprocessor s ys te m, Wi nd ows pr ov ides in terr upt
ma sks to pro te ct access to global resources. It pr ote cts acce ss t o glob al re so ur ce us in g
s pin lo ck. The ke rn el uses spin locks only to prote ct sh or t cod e se gmen t like So lari s. The
ke rne l en sures that while holdin g a spinlock, a threa d wi ll nev er b e pree mpted.
Win do ws pro vi de dispatche r obje ct for thread syn chr on izatio n acco rdi ng to s ev era l
d iffer en t mechan isms in cludin g mutexe s, sema pho re s, ev en ts and t imer s. The s ys tem
pr otects shar ed dat a by requiring a thread to ga in o wner shi p o f a mutex fo r acces si ng the
d ata an d whe n it i s fin ished, relea se s the ownersh ip.
Ev en ts acts as a con dition a l variable t o n ot ify a wai ting thr ead when des ired con diti on
o ccurs .
Tim ers a re use d to n otify on e or more thre ad when t ime expir ed.
Dispatcher objects may be either signaled state or a non-signaled state.
Signaled state indicates that an object is available and a thread will not block when
acquiring the object.
Non-signaled state indicates that an object is not available and a thread will block when
trying to acquire the object.
The below figure shows the state transitions of a mutex lock dispatcher object −
Process Synchronization in Solaris(Unix based OS)
S o l a r i s i m p l e m e n t s v a r i e t y o f l o c k s t o s u p p o rt m u l t i t a s k i n g , m u l t i t h r e a d i n g a n d m u l t i p r o c e s s i n g . I t
uses adaptive mutexes, conditional variables, semaphores, read-write locks, turnstiles to control
a c c e s s t o c r i t i c a l s e c ti o n s .
An adaptive mutex uses for protecting every critical data item which are only accessed by short
code segments.
O n A m u l t i p r o c e s s o r s y s t e m i t s ta r t s a s a s t a n d a r d s e ma p h o r e s p i n - l o c k . I f t h e l o c k i s h e l d b y a
t h r e a d w h i c h i s r u n n i n g o n a n o th e r C P U t h e n t h e t h r e a d s p i n s . I f th e l o c k i s h e l d b y a t h r e a d w h i c h
i s c u r r e n t l y i n r u n s t a te , t h e t h r e a d b l o c k s , g o i n g t o s l e e p u n t i l i t i s a w a k e n e d b y t h e s i g n a l o f
releasing the lock.
T h e s p i n - w a i t i n g m e t h o d i s e x c e e d i n g l y i n e f fi c i e n t i f c o d e s e g m e n t i s l o n g e r . S o c o n d i t i o n a l
v a r i a b l e s , s e m a p h o r e s a r e u s e d fo r t h e m .
S o l a r i s p r o v i d e s R e a d - W r i t e l o c k t o p r o t e c t th e d a t a a r e fr e q u e n t l y a c c e s s e d b y l o n g s e c t i o n o f
code usually in read-only manner.
It uses turnstiles to order the list of threads waiting to acquire either an adaptive
mutex or read-writer lock. Turnstile is a queue structure containing threads blocked on
a lock. They are per lock holding thread, not per object. Turnstiles are organized
according to priority-inheritance which gives the running thread the highest of the
priorities of the threads in its turnstiles to prevent priority inversion.
Locking mechanisms are used by kernel is also used by user-level threads, so that the
locks are available both inside and outside of the kernel. The difference is only that
priority-in heritance in only used in kernel, user-level thread does not provide this
functionality.
To optimize Solaris performance, developers refin e the locking methods as locks are
used frequently and typically for crucial kernel functions, tuning their implemen tations
and use to g ain great performance.
Process Synchronization in MS-DOS
Programs can’t break out middle of DOS routine and then restart routine from
somewhere else.
Interrupt handlers allow the saving of all information about parent program
that allow its proper restart after child program has finished.
Process Synchronization in ANDROID
In Andro id, ev ery tim e w h en us er s t a rt up a a p plicat io n, it w ill genera t e a L inux p ro ces s a nd a
m a in t hrea d. N o rma lly, a ll co mp o nen ts o f a n o ngo in g a pp lica t io n a re ma int a ined in t his pro ces s
a nd t h rea d. I f res o urces are run ning o ut , Andro id w o uld t ry to s t o p s o me t hrea ds t o k eep
runn ing t hi s a pp licat io n.
M e s s ag e Q u e u e i s i n v o l v e d t o s t o r e t h e m e s s a g e s pu b l i s h e d b y h an d l e r . I t i s m a i n t ai n e d b y t h e
t h r e ad .
T h r o u g h H a n d l er , a n i n s t an c e c o u l d b e s e n t . Ev e r y h an d l e r i s r e l a te d w i th u n i q u e th r e a d a n d
i t s m e s s ag e q ue u e . W h e n a H an d l e r i s c r e at e d , i t i s b o u n d to th e m e s s ag e q ue u e o f th e t h r e a d
t h a t c r e a te d i t. O n d e fa u l t, i t w i l l o n l y a s s o c ia t e d w i th t h e t h r e ad s th at c r e at e d . T h a t m e an s ,
i f t h e t h r e ad s s e n d m e s s a g e t o o t h e r s , i t w i l l o n l y b e s e n t t o t h e a s s o c i at e d m e s s ag e q u e u e .
L o o pe r i s l i k e a “ b r i d g e ” b e t w e e n h a n d l e r a n d m e s s a g e q ue u e . A p pl i c a t i o n t h r e a d s fi r s t p u t th e
m e s s ag e to l oo p e r t h r o u g h h a n d l e r , t h e n l o o pe r pu t th e m e s s ag e i nt o m e s s ag e qu e ue . M e a n w h i l e ,
l o o pe r b r o ad c a s t th e m e s s ag e to al l h an d l e r s fo r t h e t h r e a d s .
Process Synchronization in IOS
Each process (application) in Mac OS X or iPhone OS is made up of one or more
threads, each of which represents a single path of execution through the
application’s code. Every application starts with a single thread, which runs the
application’s main function.
Applications can spawn additional threads, each of which executes the code of a
specific function. When an application spawns a new thread, that thread
becomes an independent entity inside of the application’s process space. Each
thread has its own execution stack and is scheduled for runtime separately by
the kernel. A thread can communicate with other threads and other processes,
perform I/O operations, and do anything else you might need it to do.
Because they are inside the same process space, however, all threads in a sing le
application share the same virtual memory space and have the same access rig hts as the
process itself. Threads itself in iPhone OS costs allocation memories from kernel and
the programer’s space.
Creating threads is inv olving different methods, such as using NSThread, POSIX
Threads and etc. Threads created usin g these techniques inherit a default set of
attributes, determined by the technology you use. To terminate a thread, the
recommended way is to let it exit its entry point routine normally, rather than killing
threads explicitly because this would poten tially result in memory leak.
What is Interprocess Communication?
Interprocess communication is the mechanism provided by the operating system
that allows processes to communicate with each other. This communication could
involve a process letting another process know that some event has occurred or
the transferring of data from one process to another.
Sem a p h o r e - A s em a p h o r e i s a v a r i a b l e t h a t c o nt r o l s t h e a c c e s s t o a c o m m o n r es o u r c e b y m u l t i p l e
p r o c e s s e s . T h e tw o t y p es o f s e m a p h o r e s a r e b i n a r y s em a p h o r e s a n d c o u n t i n g s em a p h o r es .
Mu t u a l Ex c l u s i o n – M u t u a l e xc l u s i o n r e q u i r e s t h a t o n l y o n e p r o c e s s t h r e a d c a n e n t e r t h e c r i t i c a l
s e c t i o n a t a t i m e. T h i s i s u s ef u l f o r s y nc h r o ni z a t i o n a n d a l s o p r e v e n t s r a c e c o n d i t i o n s .
B a r r i e r - A ba r r i er d o e s no t a l l o w i nd i v i du a l p r o c e s s e s t o p r o c e e d u n t i l a l l t h e p r o c e s s e s r e a c h i t .
Ma n y p a r a l l el l a n g u a g e s a nd c o l l e c t i v e r o u t i ne s i m p o s e b a r r i e r s .
Sp i n l o c k - T h i s i s a t y p e o f l o c k . T h e p r o c es s e s t r y i n g t o a c q u i r e t h i s l o c k w a i t i n a l o o p w h i l e
c h ec k i n g i f t h e l o c k i s a v a i l a b l e o r no t . T h i s i s kno w n a s bu s y w a i t i n g b e c a u s e t h e p r o c e s s i s n o t
d o i ng a n y u s e f u l o p e r a t i o n e v en t h o u gh i t i s a c t i v e .
Approaches to Interprocess Communication
T h e d i f f e r e n t a p p r o a c h e s t o i m p l e m e n t i n t e r p r o c e s s c o m m u n i c a t i o n a r e g iv e n a s f o l l o w s −
P ip e - A p i p e i s a d a t a c h a n n e l t h a t i s u n id ir e c t i o n a l . T w o p ip e s c a n b e u s e d t o c r e a t e a t w o - w a y
d a t a c h a n n e l b e t w ee n t w o p r o c e s s e s . T h is u s e s s t a n d a r d i n p u t a n d o u t p u t m e t h o d s . P ip e s a r e u s e d
in all POSIX systems as well as Windows operating systems.
S o c k e t - T h e s o c ke t is t h e e n d p o in t f o r s e n d i n g o r r e c e i v in g d a t a i n a n e t w o r k . T h i s is t r u e f o r
d a t a s e n t b e t w e e n p r o c e s s e s o n t h e s a m e c o m p u t e r o r d a t a s e n t b e t w e e n d if f e r e n t c o m p u t e r s o n
t h e s a m e n e t w o r k. M o s t o f t h e o p e r a t i n g s y s t e m s u s e s o c k e t s f o r i n t e r p r o c e s s c o m m u n ic a t i o n .
F i l e - A f i l e is a d a t a r e c o r d t h a t m a y b e s t o r e d o n a d i s k o r a c q u ir e d o n d e m a n d b y a f i l e s e r v e r .
M u l t i p l e p r o c e s s e s c a n a c c e s s a f i l e a s r e q u i r e d . A l l o p e r a t in g s y s t e m s u s e f i l e s f o r d a t a s t o r a g e .
S i g n a l - S ig n a l s a r e u s e f u l i n in t e r p r o c e s s c o m m u n ic a t i o n in a l i m i t e d w a y . T h e y a r e s y s t e m
m e s s a g e s t h a t a r e s e n t f r o m o n e p r o c e s s t o a n o t h e r . N o r m a l l y , s ig n a l s a r e n o t u s e d t o t r a n s f e r
data but are used for remote commands between processes.
S hared Me mo ry - S ha red memo ry is t he memo ry t ha t
ca n be s imult a neo us ly a cces s ed by mult iple pro ces s es .
T his is do ne s o t ha t t h e pro ces s es ca n co mmu nica t e
w it h ea ch o t her . A ll PO SI X s ys tems , a s w ell as
Wi ndo w s o p erat ing s yst ems us e s h a red m em o ry.
MS DOS
Uni-programming system
WINDOWS
Quantum based preemptive priority
scheduling algorithm
UNIX
Multi-level feedback queue
LINUX
Time-sharing Algorithm
IOS
Uses a priority – queue based
scheduling system
ANDROID
Priority based preemptive task
scheduling
L a z y a l l o c a t o r . T h e V i r t u a l M e m o r y m a n a g e r o f t h e o p e r a t i n g
system use Demand Paging to overcome the space limitation of
Physical memory.
W i n d o w s 1 0 i m p l e m e n ts a L R U - a p p r o x i m a t i o n c l o c k a l g o r i t h m
for page replacement.
•T h e r e p l a c e m e n t p o l i c y i s a c o m bi n a t i o n o f g l o b a l a n d l o c a l .
b e c a u s e i t i s a l l o c a t i n g m a n y s t r u c t u r e s w h i c h a r e a l r e a d y p o w e r o f t w o , l i k e f r a me s .
• T h e b u d d y s y s t em i s a m e mo r y a l l o c a t i o n a n d m a n a g e m e n t a l g o r i t h m t h a t m a n a g e s m e mo r y i n p o w e r
o f t w o i n c r e m e n t s . A s s u m e th e m e m o r y s i z e i s 2 U , s u p p o s e a s i z e o f S i s r e q u i r e d .
• I f 2 U - 1 <S <= 2 U : A l l o c a t e t h e w h o l e b l o c k
• E l s e : R e c u r s i v e l y d i v i d e t h e b l o c k e q u a l l y a n d t e s t t h e c o n d i ti o n a t e a c h ti me , w h e n i t s a t i s f i e s ,
allocate the block and get out the loop.
• S y s te m a l s o k e e p t h e r e c o r d o f a l l t h e u n a l l o c a t e d b l o c k s e a c h a n d c a n me r g e t h e s e d i f fe r e n t s i z e
blocks to make one big chunk.
• Advantage –
D i s a d va n t a g e –
E x a mp l e –
Consider a system having buddy system with physical address space
128 KB. Calculate the size of partition for 18 KB process.
Solution –
I t d i vi d e s b y 2 , t i l l p o s s i b l e t o g e t m i n i m u m b l o c k
to fit 18 KB.
ANDROID
• The A ndro id Run tim e ( AR T ) and Dalv ik v irt ua l ma chine us e pa ging a nd memo ry- ma p ping
(mm a pp ing) t o m ana ge m em o ry. T his mea ns t h a t a ny m emo ry a n a p p mo dif ies —w het her by
a llo ca t ing new o bjects o r t o uching mma p ped pa ges —rema ins res ident in R AM a nd ca nno t be
pa ged o ut .
Most file systems make use of an underlying data storage device such as Hard Disks
that offers access to an array of fixed-size blocks which is the smallest logical amount
of disk space that can be allocated to hold a file.
F ile systems typically have directories which associate file names with files, usually by
connecting the file name to an index in a file allocation table of some sort, such as the
F AT in a DOS file system, or an inode in a Unix-like file system.
F ile names are simple strings, and per-file Metadata is maintained which is the
bookkeeping information, typically associated with each file within a file system.
Metadata could contain file attributes such as file size, data and time of creation or
modification o f the file, owner of the file, access permissions etc.
Types of File System
File system types can be classified into disk file systems, n etwork file systems and
flash file systems.
A disk file system is a file system designed for the storage of files on a data storag e
device, most commonly a disk drive e.g. FAT, NTFS, etx2, ext3 etc.
A network file system is a file system that acts as a client for a remote file access
protocol, providing access to files on a server e.g. NFS, SMB etc.
A flash file system is a file system designed for storing files on flash memory devices.
File System and OS
Operating systems provide a file system, as a file system is an integral part of any modern
operating system.
Windows Operating system supports FAT and NTFS File Systems
Linux popularly supports ext4 File Systems and Ext, Ext2, Ext3, JFS, XFS, btrfs and swap are also
available
Other flavors of Operating Systems may support other File Systems like
UFS in many UNIX Operating Systems and
APFS In MAC,IOS
Android supports FAT32/Ext3/Ext4 file system.
The MS-DOS filesystem is File Allocation Table, or FAT16 (FAT for short).
All Operating Systems provide a user interface like Command Line (CLI) or File Browser to access
and manage File System information.
File System FAT, NTFS Ext4, Ext, Ext2, FAT UFS FAT32/Ext3/Ext4 APFS
Ext3, JFS, XFS,
btrfs and swap
Properties of File System
Sparse file is a type of computer file that attempts to use file system space more
efficiently when the file its elf is partially empty.
Data deduplication is a techn ique for eliminating duplicate copies of repeating data
FILE SYSTEM SPARSE FILES Filesystem-level Data deduplicati
encryption on
FAT PARTIAL NO NO
TYPES:
Single-level directory –
Tree-structured directory –
WINDOWS MS-DOS
UNIX LINUX
ANDROID IOS