This document discusses the slides for Unit 2 of the Operating Systems course. It includes an index of lecture topics that will be covered, such as process concepts and threads, scheduling criteria and algorithms, thread scheduling, case studies of UNIX/Linux and Windows operating systems, and revision. Key concepts that will be covered include processes and threads, process state diagrams, process control blocks, CPU scheduling queues, producer-consumer problem solutions, scheduling criteria and algorithms like FCFS, SJF, priority and round robin, and thread scheduling models.
This presentation includes a detail of various real time operating systems and it focuses on Vx Works. It will also help you understand what not is a RTOS.
RTOS-MicroC/OS-II
It is a priority-based real-time multitasking operating system kernel for microprocessors, written mainly in the C programming language.It is intended for use in embedded systems.
How to Measure RTOS Performance – Colin Walls
In the world of smart phones and tablet PCs memory might be cheap, but in the more constrained universe of deeply embedded devices, it is still a precious resource. This is one of the many reasons why most 16- and 32-bit embedded designs rely on the services of a scalable real-time operating system (RTOS). An RTOS allows product designers to focus on the added value of their solution while delegating efficient resource (memory, peripheral, etc.) management. In addition to footprint advantages, an RTOS operates with a degree of determinism that is an essential requirement for a variety of embedded applications. This paper takes a look at “typical” reported performance metrics for an RTOS in the embedded industry.
This presentation includes a detail of various real time operating systems and it focuses on Vx Works. It will also help you understand what not is a RTOS.
RTOS-MicroC/OS-II
It is a priority-based real-time multitasking operating system kernel for microprocessors, written mainly in the C programming language.It is intended for use in embedded systems.
How to Measure RTOS Performance – Colin Walls
In the world of smart phones and tablet PCs memory might be cheap, but in the more constrained universe of deeply embedded devices, it is still a precious resource. This is one of the many reasons why most 16- and 32-bit embedded designs rely on the services of a scalable real-time operating system (RTOS). An RTOS allows product designers to focus on the added value of their solution while delegating efficient resource (memory, peripheral, etc.) management. In addition to footprint advantages, an RTOS operates with a degree of determinism that is an essential requirement for a variety of embedded applications. This paper takes a look at “typical” reported performance metrics for an RTOS in the embedded industry.
Embedded System,
Real Time Operating System Concept
Architecture of kernel
Task
Task States
Task scheduler
ISR
Semaphores
Mailbox
Message queues
Pipes
Events
Timers
Memory management
Introduction to Ucos II RTOS
Study of kernel structure of Ucos II
Synchronization in Ucos II
Inter-task communication in Ucos II
Memory management in Ucos II
Porting of RTOS.
UNIT IV FILE SYSTEMS AND I/O SYSTEMS 9
Mass Storage system – Overview of Mass Storage Structure, Disk Structure, Disk Scheduling and Management, swap space management; File-System Interface – File concept, Access methods, Directory Structure, Directory organization, File system mounting, File Sharing and Protection; File System Implementation- File System Structure, Directory implementation, Allocation Methods, Free Space Management, Efficiency and Performance, Recovery; I/O Systems – I/O Hardware, Application I/O interface, Kernel I/O subsystem, Streams, Performance.
Real-time systems are those systems in which the correctness of the system depends not only on the logical result of computation, but also on the time at which the results are produced.
In the given presentation, process overview,process management scheduling typesand some more basic concepts were explained.
Kindly refere the presentation.
Gives an overview about Process, PCB, Process States, Process Operations, Scheduling, Schedulers, Interprocess communication, shared memory and message passing systems
Concept of processes, process scheduling, operations on processes, inter-process communication,
communication in Client-Server-Systems, overview & benefits of threads.
Please open this file with MS Office 2013 or higher version.
This presentation contains information of old version Operating system which is Os/2(Operating system name).
Embedded System,
Real Time Operating System Concept
Architecture of kernel
Task
Task States
Task scheduler
ISR
Semaphores
Mailbox
Message queues
Pipes
Events
Timers
Memory management
Introduction to Ucos II RTOS
Study of kernel structure of Ucos II
Synchronization in Ucos II
Inter-task communication in Ucos II
Memory management in Ucos II
Porting of RTOS.
UNIT IV FILE SYSTEMS AND I/O SYSTEMS 9
Mass Storage system – Overview of Mass Storage Structure, Disk Structure, Disk Scheduling and Management, swap space management; File-System Interface – File concept, Access methods, Directory Structure, Directory organization, File system mounting, File Sharing and Protection; File System Implementation- File System Structure, Directory implementation, Allocation Methods, Free Space Management, Efficiency and Performance, Recovery; I/O Systems – I/O Hardware, Application I/O interface, Kernel I/O subsystem, Streams, Performance.
Real-time systems are those systems in which the correctness of the system depends not only on the logical result of computation, but also on the time at which the results are produced.
In the given presentation, process overview,process management scheduling typesand some more basic concepts were explained.
Kindly refere the presentation.
Gives an overview about Process, PCB, Process States, Process Operations, Scheduling, Schedulers, Interprocess communication, shared memory and message passing systems
Concept of processes, process scheduling, operations on processes, inter-process communication,
communication in Client-Server-Systems, overview & benefits of threads.
Please open this file with MS Office 2013 or higher version.
This presentation contains information of old version Operating system which is Os/2(Operating system name).
This was a group assignment for our Operating Systems module. Our group was asked to present on IBM's operating system, OS/2. My role was to research the architecture behind OS/2
INTRODUCTION: One popular RTOS For the E.S development is microCOS-ll for noncommercial use, it is free ware .jean J.labrosse designed it in 1992 it is well developed for a no.of applications.it is available from micrium it is popularly known as MUCOS (or) UCOS.
Maximum CPU utilization obtained with multiprogramming
CPU–I/O Burst Cycle – Process execution consists of a cycle of CPU execution and I/O wait
CPU burst followed by I/O burst
CPU burst distribution is of main concern
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Generating a custom Ruby SDK for your web service or Rails API using Smithyg2nightmarescribd
Have you ever wanted a Ruby client API to communicate with your web service? Smithy is a protocol-agnostic language for defining services and SDKs. Smithy Ruby is an implementation of Smithy that generates a Ruby SDK using a Smithy model. In this talk, we will explore Smithy and Smithy Ruby to learn how to generate custom feature-rich SDKs that can communicate with any web service, such as a Rails JSON API.
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
Here is something new! In our next Connector Corner webinar, we will demonstrate how you can use a single workflow to:
Create a campaign using Mailchimp with merge tags/fields
Send an interactive Slack channel message (using buttons)
Have the message received by managers and peers along with a test email for review
But there’s more:
In a second workflow supporting the same use case, you’ll see:
Your campaign sent to target colleagues for approval
If the “Approve” button is clicked, a Jira/Zendesk ticket is created for the marketing design team
But—if the “Reject” button is pushed, colleagues will be alerted via Slack message
Join us to learn more about this new, human-in-the-loop capability, brought to you by Integration Service connectors.
And...
Speakers:
Akshay Agnihotri, Product Manager
Charlie Greenberg, Host
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Albert Hoitingh
In this session I delve into the encryption technology used in Microsoft 365 and Microsoft Purview. Including the concepts of Customer Key and Double Key Encryption.
JMeter webinar - integration with InfluxDB and GrafanaRTTS
Watch this recorded webinar about real-time monitoring of application performance. See how to integrate Apache JMeter, the open-source leader in performance testing, with InfluxDB, the open-source time-series database, and Grafana, the open-source analytics and visualization application.
In this webinar, we will review the benefits of leveraging InfluxDB and Grafana when executing load tests and demonstrate how these tools are used to visualize performance metrics.
Length: 30 minutes
Session Overview
-------------------------------------------
During this webinar, we will cover the following topics while demonstrating the integrations of JMeter, InfluxDB and Grafana:
- What out-of-the-box solutions are available for real-time monitoring JMeter tests?
- What are the benefits of integrating InfluxDB and Grafana into the load testing stack?
- Which features are provided by Grafana?
- Demonstration of InfluxDB and Grafana using a practice web application
To view the webinar recording, go to:
https://www.rttsweb.com/jmeter-integration-webinar
Elevating Tactical DDD Patterns Through Object CalisthenicsDorra BARTAGUIZ
After immersing yourself in the blue book and its red counterpart, attending DDD-focused conferences, and applying tactical patterns, you're left with a crucial question: How do I ensure my design is effective? Tactical patterns within Domain-Driven Design (DDD) serve as guiding principles for creating clear and manageable domain models. However, achieving success with these patterns requires additional guidance. Interestingly, we've observed that a set of constraints initially designed for training purposes remarkably aligns with effective pattern implementation, offering a more ‘mechanical’ approach. Let's explore together how Object Calisthenics can elevate the design of your tactical DDD patterns, offering concrete help for those venturing into DDD for the first time!
State of ICS and IoT Cyber Threat Landscape Report 2024 previewPrayukth K V
The IoT and OT threat landscape report has been prepared by the Threat Research Team at Sectrio using data from Sectrio, cyber threat intelligence farming facilities spread across over 85 cities around the world. In addition, Sectrio also runs AI-based advanced threat and payload engagement facilities that serve as sinks to attract and engage sophisticated threat actors, and newer malware including new variants and latent threats that are at an earlier stage of development.
The latest edition of the OT/ICS and IoT security Threat Landscape Report 2024 also covers:
State of global ICS asset and network exposure
Sectoral targets and attacks as well as the cost of ransom
Global APT activity, AI usage, actor and tactic profiles, and implications
Rise in volumes of AI-powered cyberattacks
Major cyber events in 2024
Malware and malicious payload trends
Cyberattack types and targets
Vulnerability exploit attempts on CVEs
Attacks on counties – USA
Expansion of bot farms – how, where, and why
In-depth analysis of the cyber threat landscape across North America, South America, Europe, APAC, and the Middle East
Why are attacks on smart factories rising?
Cyber risk predictions
Axis of attacks – Europe
Systemic attacks in the Middle East
Download the full report from here:
https://sectrio.com/resources/ot-threat-landscape-reports/sectrio-releases-ot-ics-and-iot-security-threat-landscape-report-2024/
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Neuro-symbolic is not enough, we need neuro-*semantic*Frank van Harmelen
Neuro-symbolic (NeSy) AI is on the rise. However, simply machine learning on just any symbolic structure is not sufficient to really harvest the gains of NeSy. These will only be gained when the symbolic structures have an actual semantics. I give an operational definition of semantics as “predictable inference”.
All of this illustrated with link prediction over knowledge graphs, but the argument is general.
Neuro-symbolic is not enough, we need neuro-*semantic*
Os2
1. OPERATING SYTEMS
B.TECH II YR (TERM 08-09)
UNIT 2 PPT SLIDES
TEXT BOOKS:
Operating System Concepts- Abraham Silberchatz,
Peter B. Galvin, Greg Gagne 7th Edition, John
Wiley
Operating systems- A Concept based Approach-
D.M.Dhamdhere, 2nd Edition, TMH.
No. of slides: 52
2. INDEX
UNIT 2 PPT SLIDES
S.NO. TOPIC LECTURE NO. PPTSLIDES
1. Process concepts threads L9 L9.1 to L9.10
2. scheduling-criteria alg L10 L10.1 to L10.7
4. scheduling-criteria alg L11 L11.1 to L11.7
5. Algorithms evaluation L12 L12.1 to L12.6
5. Thread scheduling L13 L13.1 to L13.11
6. Case studies UNIX,LINUX L14 L14.1 to L14.4
7. Windows L15 L15.1 to L15.2
8. REVISION L16
3. Process Concept
• An operating system executes a variety of
programs:
– Batch system – jobs
– Time-shared systems – user programs or tasks
• Textbook uses the terms job and process
almost interchangeably
• Process – a program in execution; process
execution must progress in sequential fashion
• A process includes:
– program counter
– stack
– data section
4. Process State
• As a process executes, it changes state
– new: The process is being created
– running: Instructions are being executed
– waiting: The process is waiting for some event
to occur
– ready: The process is waiting to be assigned
to a processor
– terminated: The process has finished
execution
6. Process Control Block (PCB)
Information associated with each process
• Process state
• Program counter
• CPU registers
• CPU scheduling information
• Memory-management information
• Accounting information
• I/O status information
9. Process Scheduling Queues
• Job queue – set of all processes in the
system
• Ready queue – set of all processes
residing in main memory, ready and waiting
to execute
• Device queues – set of processes waiting
for an I/O device
• Processes migrate among the various
queues
12. Schedulers
• Long-term scheduler (or job scheduler) –
selects which processes should be brought
into the ready queue
• Short-term scheduler (or CPU scheduler) –
selects which process should be executed
next and allocates CPU
13. Producer-Consumer Problem
• Paradigm for cooperating processes,
producer process produces information that
is consumed by a consumer process
– unbounded-buffer places no practical limit on
the size of the buffer
– bounded-buffer assumes that there is a fixed
buffer size
14. Bounded-Buffer – Shared-Memory Solution
• Shared data
#define BUFFER_SIZE 10
typedef struct {
...
} item;
item buffer[BUFFER_SIZE];
int in = 0;
int out = 0;
• Solution is correct, but can only use
BUFFER_SIZE-1 elements
15. Bounded-Buffer – Producer
while (true) {
/* Produce an item */
while (((in = (in + 1)
% BUFFER SIZE count) == out)
; /* do nothing -- no
free buffers */
buffer[in] = item;
in = (in + 1) % BUFFER
SIZE;
16. Bounded Buffer – Consumer
while (true) {
while (in == out)
; // do nothing
-- nothing to consume
// remove an item from the
buffer
item = buffer[out];
out = (out + 1) % BUFFER
SIZE;
17. Scheduling Criteria
• CPU utilization – keep the CPU as busy as possible
• Throughput – # of processes that complete their
execution per time unit
• Turnaround time – amount of time to execute a
particular process
• Waiting time – amount of time a process has been
waiting in the ready queue
• Response time – amount of time it takes from when
a request was submitted until the first response is
produced, not output (for time-sharing environment)
18. Scheduling Algorithm Optimization
Criteria
• Max CPU utilization
• Max throughput
• Min turnaround time
• Min waiting time
• Min response time
19. First-Come, First-Served (FCFS) Scheduling
ProcessBurst Time
P1 24
P2 3
P3 3
• Suppose that the processes arrive in
the order: P1 , P2 , P3
The Gantt Chart for the schedule is:
P1 P2 P3
0 24 27 30
20. FCFS Scheduling (Cont)
Suppose that the processes arrive in the order
P2 , P3 , P 1
• The Gantt chart for the schedule is:
Waiting time for P1 = 6; P2 = 0; P3 = 3
• Average waiting time: (6 + 0 + 3)/3 = 3
• Much better than previous case
• Convoy effect short process behind long process
P2 P3 P1
0 3 6 30
21. Shortest-Job-First (SJF)
Scheduling
• Associate with each process the length of
its next CPU burst. Use these lengths to
schedule the process with the shortest
time
• SJF is optimal – gives minimum average
waiting time for a given set of processes
– The difficulty is knowing the length of the next
CPU request
22. Determining Length of Next CPU Burst
• Can only estimate the length
• Can be done by using the length of previous CPU bursts,
using exponential averaging
τ n = 1 = α t n + ( 1 − α )τ n .
1. t n = actual length of n th CPU burst
2. τ n +1 = predicted value for the next CPU burst
3. α , 0 ≤ α ≤ 1
4. Define :
23. Examples of Exponential Averaging
∀ α =0
τn+1 = τn
– Recent history does not count
∀ α =1
– τn+1 = α tn
– Only the actual last CPU burst counts
• If we expand the formula, we get:
τn+1 = α tn+(1 - α)α tn -1 + …
+(1 - α )j α tn -j + …
+(1 - α )n +1 τ0
• Since both α and (1 - α) are less than or equal
24. Priority Scheduling
• A priority number (integer) is associated with each process
• The CPU is allocated to the process with the highest priority
(smallest integer ≡ highest priority)
– Preemptive
– nonpreemptive
• SJF is a priority scheduling where priority is the predicted next
CPU burst time
• Problem ≡ Starvation – low priority processes may never
execute
• Solution ≡ Aging – as time progresses increase the priority of
the process
25. Round Robin (RR)
• Each process gets a small unit of CPU time (time quantum), usually 10-100
milliseconds. After this time has elapsed, the process is preempted and
added to the end of the ready queue.
• If there are n processes in the ready queue and the time quantum is q, then
each process gets 1/n of the CPU time in chunks of at most q time units at
once. No process waits more than (n-1)q time units.
• Performance
– q large ⇒ FIFO
– q small ⇒ q must be large with respect to context switch, otherwise
overhead is too high
Process Burst Time
P1 24
P2 3
P1 P2 P3 P1 P1 P1 P1 P1
P3 3
0 4 7 10 14 18 22 26 30
The Gantt chart is:
Typically, higher average turnaround than SJF, but better response
28. Algorithm Evaluation
• Deterministic modeling – takes a particular
predetermined workload and defines the
performance of each algorithm for that
workload
• Queueing models
• Implementation
31. Time-Slicing
Since the JVM Doesn’t Ensure Time-
Slicing, the yield() Method
May Be Used:
while (true) {
// perform CPU-intensive task
...
Thread.yield();
}
32. Thread Priorities
Priority Comment
Thread.MIN_PRIORITY Minimum Thread
Priority
Thread.MAX_PRIORITY Maximum Thread
Priority
Thread.NORM_PRIORITY Default Thread
Priority
Priorities May Be Set Using setPriority() method:
setPriority(Thread.NORM_PRIORITY + 2);
34. User Threads
• Thread management done by user-level
threads library
• Three primary thread libraries:
– POSIX Pthreads
– Win32 threads
Kernel
– Java threads Threads
• Supported by the Kernel
• Examples
– Windows XP/2000
– Solaris
– Linux
– Tru64 UNIX
– Mac OS X
35. Thread Scheduling
• Distinction between user-level and kernel-level
threads
• Many-to-one and many-to-many models, thread
library schedules user-level threads to run on
LWP
– Known as process-contention scope (PCS) since
scheduling competition is within the process
Kernel thread scheduled onto available CPU is
system-contention scope (SCS) –
competition among all threads in system
36. Pthread Scheduling
• API allows specifying either PCS or
SCS during thread creation
– PTHREAD SCOPE PROCESS schedules
threads using PCS scheduling
– PTHREAD SCOPE SYSTEM schedules
threads using SCS scheduling.
37. Pthread Scheduling API
#include <pthread.h>
#include <stdio.h>
#define NUM THREADS 5
int main(int argc, char *argv[])
{
int i;
pthread t tid[NUM THREADS];
pthread attr t attr;
/* get the default attributes */
pthread attr init(&attr);
/* set the scheduling algorithm to PROCESS or
SYSTEM */
pthread attr setscope(&attr, PTHREAD SCOPE
SYSTEM);
/* set the scheduling policy - FIFO, RT, or
OTHER */
pthread attr setschedpolicy(&attr, SCHED OTHER);
/* create the threads */
for (i = 0; i < NUM THREADS; i++)
38. Pthread Scheduling API
/* now join on each thread */
for (i = 0; i < NUM THREADS; i++)
pthread join(tid[i], NULL);
}
/* Each thread will begin control in
this function */
void *runner(void *param)
{
printf("I am a threadn");
pthread exit(0);
}
39. Multiple-Processor Scheduling
• CPU scheduling more complex when multiple CPUs are
available
• Homogeneous processors within a multiprocessor
• Asymmetric multiprocessing – only one processor accesses
the system data structures, alleviating the need for data sharing
• Symmetric multiprocessing (SMP) – each processor is self-
scheduling, all processes in common ready queue, or each has
its own private queue of ready processes
• Processor affinity – process has affinity for processor on
which it is currently running
– soft affinity
– hard affinity
40. Thread Libraries
• Thread library provides programmer with
API for creating and managing threads
• Two primary ways of implementing
– Library entirely in user space
– Kernel-level library supported by the OS
41. Pthreads
• May be provided either as user-level or
kernel-level
• A POSIX standard (IEEE 1003.1c) API for
thread creation and synchronization
• API specifies behavior of the thread library,
implementation is up to development of the
library
• Common in UNIX operating systems
(Solaris, Linux, Mac OS X)
42. Threading Issues
• Semantics of fork() and exec() system calls
• Thread cancellation of target thread
– Asynchronous or deferred
• Signal handling
• Thread pools
• Thread-specific data
• Scheduler activations
43. Thread Cancellation
• Terminating a thread before it has finished
• Two general approaches:
– Asynchronous cancellation terminates the
target thread immediately
– Deferred cancellation allows the target thread to
periodically check if it should be cancelled
44. Linux Threads
Linux refers to them as tasks rather than threads
Thread creation is done through clone() system call
clone() allows a child task to share the address space of the parent task (process)
47. Windows XP Threads
• Implements the one-to-one mapping, kernel-level
• Each thread contains
– A thread id
– Register set
– Separate user and kernel stacks
– Private data storage area
• The register set, stacks, and private storage area are
known as the context of the threads
• The primary data structures of a thread include:
– ETHREAD (executive thread block)
– KTHREAD (kernel thread block)
– TEB (thread environment block)
50. Linux Scheduling
• Constant order O(1) scheduling time
• Two priority ranges: time-sharing and
real-time
• Real-time range from 0 to 99 and
nice value from 100 to 140
• (figure 5.15)
51. Examples of IPC Systems – Windows XP
• Message-passing centric via local procedure call (LPC) facility
– Only works between processes on the same system
– Uses ports (like mailboxes) to establish and maintain
communication channels
– Communication works as follows:
• The client opens a handle to the subsystem’s connection
port object
• The client sends a connection request
• The server creates two private communication ports and
returns the handle to one of them to the client
• The client and server use the corresponding port handle
to send messages or callbacks and to listen for replies