Submit Search
Upload
Ch4
•
Download as PPT, PDF
•
0 likes
•
23 views
R
rajeshranjithsingh
Follow
process and cpu scheduling
Read less
Read more
Engineering
Report
Share
Report
Share
1 of 34
Download now
Recommended
Ch03 processes
Ch03 processes
Nazir Ahmed
OS_Ch4
OS_Ch4
Supriya Shrivastava
Linux kernel development ch4
Linux kernel development ch4
huangachou
Replication in Distributed Systems
Replication in Distributed Systems
Kavya Barnadhya Hazarika
Cloud computing Module 2 First Part
Cloud computing Module 2 First Part
Soumee Maschatak
Chapter00000000
Chapter00000000
Mani Deepak Choudhry
Process Migration in Heterogeneous Systems
Process Migration in Heterogeneous Systems
ijsrd.com
Process Synchronization
Process Synchronization
Christalin Nelson
Recommended
Ch03 processes
Ch03 processes
Nazir Ahmed
OS_Ch4
OS_Ch4
Supriya Shrivastava
Linux kernel development ch4
Linux kernel development ch4
huangachou
Replication in Distributed Systems
Replication in Distributed Systems
Kavya Barnadhya Hazarika
Cloud computing Module 2 First Part
Cloud computing Module 2 First Part
Soumee Maschatak
Chapter00000000
Chapter00000000
Mani Deepak Choudhry
Process Migration in Heterogeneous Systems
Process Migration in Heterogeneous Systems
ijsrd.com
Process Synchronization
Process Synchronization
Christalin Nelson
CPU Scheduling
CPU Scheduling
Christalin Nelson
resource management
resource management
Ashish Kumar
Chapter 18 - Distributed Coordination
Chapter 18 - Distributed Coordination
Wayne Jones Jnr
RTAI - Earliest Deadline First
RTAI - Earliest Deadline First
Stefano Bragaglia
process management
process management
Ashish Kumar
Session 1 introduction concurrent programming
Session 1 introduction concurrent programming
Eric Verhulst
DevoFlow - Scaling Flow Management for High-Performance Networks
DevoFlow - Scaling Flow Management for High-Performance Networks
Jason TC HOU (侯宗成)
Resource management
Resource management
Dr Sandeep Kumar Poonia
Leveraging Endpoint Flexibility in Data-Intensive Clusters
Leveraging Endpoint Flexibility in Data-Intensive Clusters
Ran Ziv
Task migration in os
Task migration in os
uos lahore pakistan
Lecture 4 process cpu scheduling
Lecture 4 process cpu scheduling
Kumbirai Junior Muzavazi
Process Management-Process Migration
Process Management-Process Migration
MNM Jain Engineering College
Os
Os
Sushma Shinde
Open MPI 2
Open MPI 2
Anshul Sharma
3 process management
3 process management
Dr. Loganathan R
Ch6 cpu scheduling
Ch6 cpu scheduling
Welly Dian Astika
Ds ppt imp.
Ds ppt imp.
Mayank Jain
Communication And Synchronization In Distributed Systems
Communication And Synchronization In Distributed Systems
guest61205606
Ch5 process synchronization
Ch5 process synchronization
Welly Dian Astika
Ch3.processes
Ch3.processes
Syaiful Ahdan
Operating System-Ch4.processes
Operating System-Ch4.processes
Syaiful Ahdan
운영체제론 Ch22
운영체제론 Ch22
Jongmyoung Kim
More Related Content
What's hot
CPU Scheduling
CPU Scheduling
Christalin Nelson
resource management
resource management
Ashish Kumar
Chapter 18 - Distributed Coordination
Chapter 18 - Distributed Coordination
Wayne Jones Jnr
RTAI - Earliest Deadline First
RTAI - Earliest Deadline First
Stefano Bragaglia
process management
process management
Ashish Kumar
Session 1 introduction concurrent programming
Session 1 introduction concurrent programming
Eric Verhulst
DevoFlow - Scaling Flow Management for High-Performance Networks
DevoFlow - Scaling Flow Management for High-Performance Networks
Jason TC HOU (侯宗成)
Resource management
Resource management
Dr Sandeep Kumar Poonia
Leveraging Endpoint Flexibility in Data-Intensive Clusters
Leveraging Endpoint Flexibility in Data-Intensive Clusters
Ran Ziv
Task migration in os
Task migration in os
uos lahore pakistan
Lecture 4 process cpu scheduling
Lecture 4 process cpu scheduling
Kumbirai Junior Muzavazi
Process Management-Process Migration
Process Management-Process Migration
MNM Jain Engineering College
Os
Os
Sushma Shinde
Open MPI 2
Open MPI 2
Anshul Sharma
3 process management
3 process management
Dr. Loganathan R
Ch6 cpu scheduling
Ch6 cpu scheduling
Welly Dian Astika
Ds ppt imp.
Ds ppt imp.
Mayank Jain
Communication And Synchronization In Distributed Systems
Communication And Synchronization In Distributed Systems
guest61205606
Ch5 process synchronization
Ch5 process synchronization
Welly Dian Astika
What's hot
(19)
CPU Scheduling
CPU Scheduling
resource management
resource management
Chapter 18 - Distributed Coordination
Chapter 18 - Distributed Coordination
RTAI - Earliest Deadline First
RTAI - Earliest Deadline First
process management
process management
Session 1 introduction concurrent programming
Session 1 introduction concurrent programming
DevoFlow - Scaling Flow Management for High-Performance Networks
DevoFlow - Scaling Flow Management for High-Performance Networks
Resource management
Resource management
Leveraging Endpoint Flexibility in Data-Intensive Clusters
Leveraging Endpoint Flexibility in Data-Intensive Clusters
Task migration in os
Task migration in os
Lecture 4 process cpu scheduling
Lecture 4 process cpu scheduling
Process Management-Process Migration
Process Management-Process Migration
Os
Os
Open MPI 2
Open MPI 2
3 process management
3 process management
Ch6 cpu scheduling
Ch6 cpu scheduling
Ds ppt imp.
Ds ppt imp.
Communication And Synchronization In Distributed Systems
Communication And Synchronization In Distributed Systems
Ch5 process synchronization
Ch5 process synchronization
Similar to Ch4
Ch3.processes
Ch3.processes
Syaiful Ahdan
Operating System-Ch4.processes
Operating System-Ch4.processes
Syaiful Ahdan
운영체제론 Ch22
운영체제론 Ch22
Jongmyoung Kim
Ch1 introduction os
Ch1 introduction os
Syaiful Ahdan
Architecting for the cloud elasticity security
Architecting for the cloud elasticity security
Len Bass
운영체제론 Ch20
운영체제론 Ch20
Jongmyoung Kim
Ch3 processes
Ch3 processes
Welly Dian Astika
Von Neumann Architecture microcontroller.pptx
Von Neumann Architecture microcontroller.pptx
SUNILNYATI2
Processes
Processes
RaviRaj339
Chapter -2 operating system presentation
Chapter -2 operating system presentation
chnrketan
Lect07
Lect07
Vin Voro
ch13 here is the ppt of this chapter included pictures
ch13 here is the ppt of this chapter included pictures
PranjalRana4
Lecture- 2_Process Management.pdf
Lecture- 2_Process Management.pdf
Harika Pudugosula
Unit - 5 Pipelining.pptx
Unit - 5 Pipelining.pptx
Medicaps University
Operating System : Ch18 distributed coordination
Operating System : Ch18 distributed coordination
Syaiful Ahdan
Ch1
Ch1
sunandakadiwal
Module2 MultiThreads.ppt
Module2 MultiThreads.ppt
shreesha16
Lecture 5 inter process communication
Lecture 5 inter process communication
Kumbirai Junior Muzavazi
Operating System : Ch16.distributed system structures
Operating System : Ch16.distributed system structures
Syaiful Ahdan
SYNCHRONIZATION IN MULTIPROCESSING
SYNCHRONIZATION IN MULTIPROCESSING
Aparna Bhadran
Similar to Ch4
(20)
Ch3.processes
Ch3.processes
Operating System-Ch4.processes
Operating System-Ch4.processes
운영체제론 Ch22
운영체제론 Ch22
Ch1 introduction os
Ch1 introduction os
Architecting for the cloud elasticity security
Architecting for the cloud elasticity security
운영체제론 Ch20
운영체제론 Ch20
Ch3 processes
Ch3 processes
Von Neumann Architecture microcontroller.pptx
Von Neumann Architecture microcontroller.pptx
Processes
Processes
Chapter -2 operating system presentation
Chapter -2 operating system presentation
Lect07
Lect07
ch13 here is the ppt of this chapter included pictures
ch13 here is the ppt of this chapter included pictures
Lecture- 2_Process Management.pdf
Lecture- 2_Process Management.pdf
Unit - 5 Pipelining.pptx
Unit - 5 Pipelining.pptx
Operating System : Ch18 distributed coordination
Operating System : Ch18 distributed coordination
Ch1
Ch1
Module2 MultiThreads.ppt
Module2 MultiThreads.ppt
Lecture 5 inter process communication
Lecture 5 inter process communication
Operating System : Ch16.distributed system structures
Operating System : Ch16.distributed system structures
SYNCHRONIZATION IN MULTIPROCESSING
SYNCHRONIZATION IN MULTIPROCESSING
Recently uploaded
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
9953056974 Low Rate Call Girls In Saket, Delhi NCR
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
ranjana rawat
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur High Profile
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
RajaP95
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writing
rakeshbaidya232001
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
ranjana rawat
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
humanexperienceaaa
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Call Girls in Nagpur High Profile
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
Call Girls in Nagpur High Profile
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Dr.Costas Sachpazis
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Christo Ananth
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
SIVASHANKAR N
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
Soham Mondal
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur High Profile
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
RajaP95
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
M Maged Hegazy, LLM, MBA, CCP, P3O
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
ranjana rawat
247267395-1-Symmetric-and-distributed-shared-memory-architectures-ppt (1).ppt
247267395-1-Symmetric-and-distributed-shared-memory-architectures-ppt (1).ppt
ssuser5c9d4b1
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
ranjana rawat
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
slot gacor bisa pakai pulsa
Recently uploaded
(20)
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
IMPLICATIONS OF THE ABOVE HOLISTIC UNDERSTANDING OF HARMONY ON PROFESSIONAL E...
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writing
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
247267395-1-Symmetric-and-distributed-shared-memory-architectures-ppt (1).ppt
247267395-1-Symmetric-and-distributed-shared-memory-architectures-ppt (1).ppt
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
Ch4
1.
Silberschatz and Galvin
©19994.1 Module 4: Processes • Process Concept • Process Scheduling • Operation on Processes • Cooperating Processes • Interprocess Communication
2.
Silberschatz and Galvin
©19994.2 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
3.
Silberschatz and Galvin
©19994.3 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 process. – terminated: The process has finished execution.
4.
Silberschatz and Galvin
©19994.4 Diagram of Process State
5.
Silberschatz and Galvin
©19994.5 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
6.
Silberschatz and Galvin
©19994.6 Process Control Block (PCB)
7.
Silberschatz and Galvin
©19994.7 CPU Switch From Process to Process
8.
Silberschatz and Galvin
©19994.8 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. • Process migration between the various queues.
9.
Silberschatz and Galvin
©19994.9 Ready Queue And Various I/O Device Queues
10.
Silberschatz and Galvin
©19994.10 Representation of Process Scheduling
11.
Silberschatz and Galvin
©19994.11 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.
12.
Silberschatz and Galvin
©19994.12 Addition of Medium Term Scheduling
13.
Silberschatz and Galvin
©19994.13 Schedulers (Cont.) • Short-term scheduler is invoked very frequently (milliseconds) ⇒ (must be fast). • Long-term scheduler is invoked very infrequently (seconds, minutes) ⇒ (may be slow). • The long-term scheduler controls the degree of multiprogramming. • Processes can be described as either: – I/O-bound process – spends more time doing I/O than computations, many short CPU bursts. – CPU-bound process – spends more time doing computations; few very long CPU bursts.
14.
Silberschatz and Galvin
©19994.14 Context Switch • When CPU switches to another process, the system must save the state of the old process and load the saved state for the new process. • Context-switch time is overhead; the system does no useful work while switching. • Time dependent on hardware support.
15.
Silberschatz and Galvin
©19994.15 Process Creation • Parent process creates children processes, which, in turn create other processes, forming a tree of processes. • Resource sharing – Parent and children share all resources. – Children share subset of parent’s resources. – Parent and child share no resources. • Execution – Parent and children execute concurrently. – Parent waits until children terminate.
16.
Silberschatz and Galvin
©19994.16 Process Creation (Cont.) • Address space – Child duplicate of parent. – Child has a program loaded into it. • UNIX examples – fork system call creates new process – execve system call used after a fork to replace the process’ memory space with a new program.
17.
Silberschatz and Galvin
©19994.17 A Tree of Processes On A Typical UNIX System
18.
Silberschatz and Galvin
©19994.18 Process Termination • Process executes last statement and asks the operating system to decide it (exit). – Output data from child to parent (via wait). – Process’ resources are deallocated by operating system. • Parent may terminate execution of children processes (abort). – Child has exceeded allocated resources. – Task assigned to child is no longer required. – Parent is exiting. Operating system does not allow child to continue if its parent terminates. Cascading termination.
19.
Silberschatz and Galvin
©19994.19 Cooperating Processes • Independent process cannot affect or be affected by the execution of another process. • Cooperating process can affect or be affected by the execution of another process • Advantages of process cooperation – Information sharing – Computation speed-up – Modularity – Convenience
20.
Silberschatz and Galvin
©19994.20 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.
21.
Silberschatz and Galvin
©19994.21 Bounded-Buffer – Shared-Memory Solution • Shared data var n; type item = … ; var buffer. array [0..n–1] of item; in, out: 0..n–1; • Producer process repeat … produce an item in nextp … while in+1 mod n = out do no-op; buffer [in] :=nextp; in :=in+1 mod n; until false;
22.
Silberschatz and Galvin
©19994.22 Bounded-Buffer (Cont.) • Consumer process repeat while in = out do no-op; nextc := buffer [out]; out := out+1 mod n; … consume the item in nextc … until false; • Solution is correct, but can only fill up n–1 buffer.
23.
Silberschatz and Galvin
©19994.23 Threads • A thread (or lightweight process) is a basic unit of CPU utilization; it consists of: – program counter – register set – stack space • A thread shares with its peer threads its: – code section – data section – operating-system resources collectively know as a task. • A traditional or heavyweight process is equal to a task with one thread
24.
Silberschatz and Galvin
©19994.24 Threads (Cont.) • In a multiple threaded task, while one server thread is blocked and waiting, a second thread in the same task can run. – Cooperation of multiple threads in same job confers higher throughput and improved performance. – Applications that require sharing a common buffer (i.e., producer-consumer) benefit from thread utilization. • Threads provide a mechanism that allows sequential processes to make blocking system calls while also achieving parallelism. • Kernel-supported threads (Mach and OS/2). • User-level threads; supported above the kernel, via a set of library calls at the user level (Project Andrew from CMU). • Hybrid approach implements both user-level and kernel- supported threads (Solaris 2).
25.
Silberschatz and Galvin
©19994.25 Multiple Threads within a Task
26.
Silberschatz and Galvin
©19994.26 Threads Support in Solaris 2 • Solaris 2 is a version of UNIX with support for threads at the kernel and user levels, symmetric multiprocessing, and real-time scheduling. • LWP – intermediate level between user-level threads and kernel-level threads. • Resource needs of thread types: – Kernel thread: small data structure and a stack; thread switching does not require changing memory access information – relatively fast. – LWP: PCB with register data, accounting and memory information,; switching between LWPs is relatively slow. – User-level thread: only ned stack and program counter; no kernel involvement means fast switching. Kernel only sees the LWPs that support user-level threads.
27.
Silberschatz and Galvin
©19994.27 Solaris 2 Threads
28.
Silberschatz and Galvin
©19994.28 Interprocess Communication (IPC) • Mechanism for processes to communicate and to synchronize their actions. • Message system – processes communicate with each other without resorting to shared variables. • IPC facility provides two operations: – send(message) – message size fixed or variable – receive(message) • If P and Q wish to communicate, they need to: – establish a communication link between them – exchange messages via send/receive • Implementation of communication link – physical (e.g., shared memory, hardware bus) – logical (e.g., logical properties)
29.
Silberschatz and Galvin
©19994.29 Implementation Questions • How are links established? • Can a link be associated with more than two processes? • How many links can there be between every pair of communicating processes? • What is the capacity of a link? • Is the size of a message that the link can accommodate fixed or variable? • Is a link unidirectional or bi-directional?
30.
Silberschatz and Galvin
©19994.30 Direct Communication • Processes must name each other explicitly: – send (P, message) – send a message to process P – receive(Q, message) – receive a message from process Q • Properties of communication link – Links are established automatically. – A link is associated with exactly one pair of communicating processes. – Between each pair there exists exactly one link. – The link may be unidirectional, but is usually bi-directional.
31.
Silberschatz and Galvin
©19994.31 Indirect Communication • Messages are directed and received from mailboxes (also referred to as ports). – Each mailbox has a unique id. – Processes can communicate only if they share a mailbox. • Properties of communication link – Link established only if processes share a common mailbox – A link may be associated with many processes. – Each pair of processes may share several communication links. – Link may be unidirectional or bi-directional. • Operations – create a new mailbox – send and receive messages through mailbox – destroy a mailbox
32.
Silberschatz and Galvin
©19994.32 Indirect Communication (Continued) • Mailbox sharing – P1, P2, and P3 share mailbox A. – P1, sends; P2 and P3 receive. – Who gets the message? • Solutions – Allow a link to be associated with at most two processes. – Allow only one process at a time to execute a receive operation. – Allow the system to select arbitrarily the receiver. Sender is notified who the receiver was.
33.
Silberschatz and Galvin
©19994.33 Buffering • Queue of messages attached to the link; implemented in one of three ways. 1. Zero capacity – 0 messages Sender must wait for receiver (rendezvous). 2. Bounded capacity – finite length of n messages Sender must wait if link full. 3. Unbounded capacity – infinite length Sender never waits.
34.
Silberschatz and Galvin
©19994.34 Exception Conditions – Error Recovery • Process terminates • Lost messages • Scrambled Messages
Download now