Os Notes PDF
Os Notes PDF
UNIT -1
UNIT -3
UNIT -4
Deadlock: Shared resources, resource allocation and scheduling, resource
graph models, deadlock detection, deadlock avoidance, deadlock prevention
algorithms Device management: devices and their characteristics, device
drivers, device handling, disk scheduling algorithms and policies
Device management:
Block device: it stores information in fixed-size block, each one with its own
address.exampledisk.
Character device: delivers or accepts a stream of characters. The individual
characters are not addressable. For example printers, keyboards etc.
Network device: For transmitting data packets.
• Keep tracks of all devices and the program which is responsible to perform
this is called I/O controller.
• Monitoring the status of each device such as storage drivers, printers and
other peripheral devices.
• Enforcing preset policies and taking a decision which process gets the device
when and for how long.
TYPES OF DEVICES
The OS peripheral devices can be categorized into 3: Dedicated, Shared, and
Virtual. The differences among them are the functions of the characteristics of the
devices as well as how they are managed by the Device Manager.
Dedicated devices:-
Shared devices:-
Virtual Devices:-
These devices are the combination of the first two types and they are dedicated
devices which are transformed into shared devices. For example, a printer
converted into a shareable device via spooling program which re-routes all the
print requests to a disk. A print job is not sent straight to the printer, instead, it goes
to the disk(spool)until it is fully prepared with all the necessary sequences and
formatting, then it goes to the printers. This technique can transform one printer
into several virtual printers which leads to better performance and use.
Polling:-
In this, a CPU continuously checks the device status for exchanging data. The plus
point is that it is simple and the negative point is – Busy-waiting.
Interrupt-driven I/Os:-
A device controller notifies the corresponding device driver about the availability
of the device. The advantages can be a more efficient use of CPU cycles and the
drawbacks can be data copying and movements and slow for character devices-one
interrupt per keyboard input.
Note:-
A device controller performs conversion between serial bit stream and a block of
bytes, do error correction if necessary and has 2 main components; a device
registers to communicate with the CPU and a Data buffer that an OS can read or
write.
To perform data movements additional controller bought into use. The benefit of
such a method is that CPU is not involved in copying data but a con is that a
process cannot access in-transit data.
Double buffering:
This methodology access advice makes use of two buffers so that while one is
being used, the other is being filled. Such a way is quite popular in graphics and
animation so that the viewer does not see the line-by-line scanning.
UNIT -5
File management: file concept, types and structures, directory structure, cases
studies, access methods and matrices, file security, user authentication
UNIT -6
UNIX and Linux operating systems as case studies; Time OS and case studies
of Mobile OS
The Kernel
Memory Management
• Hardware layer − Hardware consists of all peripheral devices (RAM/ HDD/ CPU
• Utilities − Utility programs that provide the user most of the functionalities of an
operating systems.
Memory management is one of the most complex activity done by Linux kernel. It has various
concepts/issues associated with it.
• The memory management subsystem is one of the most important parts of the operating system. Since
the early days of computing, there has been a need for more memory than exists physically in a system.
Strategies have been developed to overcome this limitation and the most successful of these is virtual
memory. Virtual memory makes the system appear to have more memory than it actually has by sharing it
between competing processes as they need it.
• Virtual memory does more than just make your computer's memory go further. The memory
management subsystem provides:
Protection:- Each process in the system has its own virtual address space. These virtual address
spaces are completely separate from each other and so a process running one application cannot affect
another. Also, the hardware virtual memory mechanisms allow areas of memory to be protected against
writing. This protects code and data from being overwritten by rogue applications.
Memory Mapping:- Memory mapping is used to map image and data files into a processes
address space. In memory mapping, the contents of a file are linked directly into the virtual address space
of a process.
Some commands in linux
Scheduling in Linux
1. Real-time FIFO. 2. Real-time round robin. 3. Timesharing.
Difference between UNIX AND LINUX
Difference between WINDOWS AND LINUX
BASIS FOR COMPARISON LINUX WINDOWS
Customizable Yes No
attacks.
File system EXT2, EXT3, EXT4, Reisers FS, XFS FAT, FAT32, NTFS and ReFS
and JFS
Definition
A real-time operating system (RTOS) is an operating system (OS) intended to
serve real-time applications that process data as it comes in, typically without
buffer delays. Processing time requirements (including any OS delay) are
measured in tenths of seconds or shorter increments of time. A real-time system is
a time bound system which has well defined fixed time constraints. Processing
must be done within the defined constraints or the system will fail. They either
are event driven or time sharing. Event driven systems switch between tasks based
on their priorities while time sharing systems switch the task based on clock
interrupts.
The primary functions of the real time operating system are to:
1. Manage the processor and other system resources to meet the requirements of an
application.
3. Move the data efficiently among processes and to perform coordination among
these processes.
Examples of real time processing are:
1. Airlines reservation system.
2. Air traffic control system.
3. Systems that provide immediate updating.
4. Systems that provide up to the minute information on stock prices.
5. Defense application systems like as RADAR.
Scheduling Algorithms
• Cooperative scheduling
• Preemptive scheduling
Memory management
Memory management is one of the most important subsystems of any operating
system for computer control systems, and is even more critical in a RTOS than in
standard operating systems. Firstly, the speed of memory allocation is important in
a RTOS. A standard memory allocation scheme scans a linked list of indeterminate
length to find a free memory block; however, memory allocation has to occur in a
fixed time in a RTOS. Secondly, memory can become fragmented as free regions
become separated by regions that are in use, causing a program to stall, unable to
get memory, even though there is theoretically enough available. Memory
allocation algorithms that slowly accumulate fragmentation may work perfectly
well for desktop machines rebooted every day or so but are unacceptable for
embedded systems that often run for months without rebooting.
Much like the Linux or Windows operating system controls your desktop or laptop
computer, a mobile operating system is the software platform on top of which
other programs can run on mobile devices. The operating system is responsible for
determining the functions and features available on your device, such as thumb
wheel, keyboards, WAP, synchronization with applications, email, text
messaging and more. The mobile OS will also determine which third-party
applications (mobile apps) can be used on your device.
Feature Android iOS Windows 10 Mobile BlackBerry 10
Google, Open Handset
Developed by Apple Inc. Microsoft BlackBerry Ltd.
Alliance