Solaris CS 450-2 Dr. Abzug Alex Blood Mike Henry James Sheasley David Waterman.

Slides:



Advertisements
Similar presentations
Processes and Threads Chapter 3 and 4 Operating Systems: Internals and Design Principles, 6/E William Stallings Patricia Roy Manatee Community College,
Advertisements

Chapter 9: Virtual Memory
CprE 458/558: Real-Time Systems (G. Manimaran)1 CprE 458/558: Real-Time Systems Resource Access Control Protocols.
Operating Systems Process Scheduling (Ch 3.2, )
Bilgisayar Mühendisliği Bölümü GYTE - Bilgisayar Mühendisliği Bölümü Multithreading the SunOS Kernel J. R. Eykholt, S. R. Kleiman, S. Barton, R. Faulkner,
Chapter 9: Virtual-Memory Management. 9.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 9: Virtual Memory Background Demand Paging.
Chapter 5 CPU Scheduling. CPU Scheduling Topics: Basic Concepts Scheduling Criteria Scheduling Algorithms Multiple-Processor Scheduling Real-Time Scheduling.
Threads Irfan Khan Myo Thein What Are Threads ? a light, fine, string like length of material made up of two or more fibers or strands of spun cotton,
Chapter 10 Operating Systems. 2 Chapter Goals Describe the two main responsibilities of an operating system Define memory and process management Explain.
1 Process Lifetime Parent Child. 2 Process Performance Issues " The maximum number of processes allowed is 30,000. " Executables that use shared libraries.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 6: CPU Scheduling Basic Concepts Scheduling Criteria Scheduling Algorithms.
Cs238 CPU Scheduling Dr. Alan R. Davis.
Operating System Process Scheduling (Ch 4.2, )
Operating System Support Focus on Architecture
Introduction to Operating Systems – Windows process and thread management In this lecture we will cover Threads and processes in Windows Thread priority.
1 Thursday, June 15, 2006 Confucius says: He who play in root, eventually kill tree.
Concurrency: Mutual Exclusion, Synchronization, Deadlock, and Starvation in Representative Operating Systems.
Cs238 CPU Scheduling Dr. Alan R. Davis. CPU Scheduling The objective of multiprogramming is to have some process running at all times, to maximize CPU.
Chapter 11 Operating Systems
Job scheduling Queue discipline.
1 Inside the Windows NT Scheduler, Part 1 Assigning CPU time in a uniprocessor environment by Mark Russinovich Windows NT Magazine - July 1997 Inside the.
1Chapter 05, Fall 2008 CPU Scheduling The CPU scheduler (sometimes called the dispatcher or short-term scheduler): Selects a process from the ready queue.
Chapter 3 Operating Systems Introduction to CS 1 st Semester, 2015 Sanghyun Park.
Chapter 8 Windows Outline Programming Windows 2000 System structure Processes and threads in Windows 2000 Memory management The Windows 2000 file.
Chapter 5: CPU Scheduling (Continuation). 5.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Feb 2, 2005 Determining Length.
Chapter 10 Operating Systems *. 2 Chapter Goals Describe the main responsibilities of an operating system Define memory and process management Explain.
Processes and Threads.
1 Previous lecture review n Out of basic scheduling techniques none is a clear winner: u FCFS - simple but unfair u RR - more overhead than FCFS may not.
CS 153 Design of Operating Systems Spring 2015 Lecture 11: Scheduling & Deadlock.
Scheduling Basic scheduling policies, for OS schedulers (threads, tasks, processes) or thread library schedulers Review of Context Switching overheads.
Chapter 10 Operating Systems.
Processes and Threads Processes have two characteristics: – Resource ownership - process includes a virtual address space to hold the process image – Scheduling/execution.
Chapter 101 Multiprocessor and Real- Time Scheduling Chapter 10.
SWE202 Review. Processes Process State As a process executes, it changes state – new: The process is being created – running: Instructions are being.
Operating Systems Process Management.
Review Questions on Chapter III—Scheduling COSC 4330/6310 Summer 2013.
XOberon Operating System CLAUDIA MARIN CS 550 Fall 2005.
What Every Developer Should Know about the Kernel Dr. Michael L. Collard 1.
Scheduling Lecture 6. What is Scheduling? An O/S often has many pending tasks. –Threads, async callbacks, device input. The order may matter. –Policy,
Lecture 7: Scheduling preemptive/non-preemptive scheduler CPU bursts
Review for Quiz-2 Applied Operating System Concepts Chap.s 1,2,6,7 - ECE3055b, Spring 2005.
Processes & Threads Introduction to Operating Systems: Module 5.
CS 390 Unix Programming Environment
T HREADS Lecture 5 1 L. Mohammad R.Alkafagee. H EAVYWEIGHT - PROCESSES The cooperation of traditional processes also known as heavyweight processes which.
Silberschatz, Galvin and Gagne ©2011 Operating System Concepts Essentials – 8 th Edition Chapter 2: The Linux System Part 3.
Chapter 3: Processes. 3.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts - 7 th Edition, Feb 7, 2006 Chapter 3: Processes Process Concept.
1 CPU Scheduling Basic Concepts Scheduling Criteria Scheduling Algorithms Multiple-Processor Scheduling Real-Time Scheduling.
Copyright © Curt Hill More on Operating Systems Continuation of Introduction.
1 Uniprocessor Scheduling Chapter 3. 2 Alternating Sequence of CPU And I/O Bursts.
Lecture 4 CPU scheduling. Basic Concepts Single Process  one process at a time Maximum CPU utilization obtained with multiprogramming CPU idle :waiting.
CPU scheduling.  Single Process  one process at a time  Maximum CPU utilization obtained with multiprogramming  CPU idle :waiting time is wasted 2.
 In a single-processor system, only one process can run at a time; any others must wait until the CPU is free and can be rescheduled.  The objective.
Processes Chapter 3. Processes in Distributed Systems Processes and threads –Introduction to threads –Distinction between threads and processes Threads.
Lab 2 Processes CPIT 260. Lab Policy Lab grades Yahoo Group : CPIT_260_LAB_ AssessmentsMark Daily Practice5 Practical.
CPU Scheduling Scheduling processes (or kernel-level threads) onto the cpu is one of the most important OS functions. The cpu is an expensive resource.
Processes and Threads Chapter 3 and 4 Operating Systems: Internals and Design Principles, 6/E William Stallings Patricia Roy Manatee Community College,
REAL-TIME OPERATING SYSTEMS
Chapter 6: CPU Scheduling (Cont’d)
Process Management Process Concept Why only the global variables?
EEE Embedded Systems Design Process in Operating Systems 서강대학교 전자공학과
Applied Operating System Concepts -
Virtual Memory Management
Chapter 15 – Part 1 The Internal Operating System
Chapter 5: CPU Scheduling
Chapter 2: The Linux System Part 3
TDC 311 Process Scheduling.
Outline Scheduling algorithms Multi-processor scheduling
CPU scheduling decisions may take place when a process:
Process Scheduling Decide which process should run and for how long
Shortest-Job-First (SJR) Scheduling
Presentation transcript:

Solaris CS Dr. Abzug Alex Blood Mike Henry James Sheasley David Waterman

Introduction Brief History Multiprocessor Support Dealing With Deadlock CPU Scheduling Virtual Memory Conclusion

Brief History AT&T’s Bell Labs 1969 Berkley Standard Distribution 1977 Department of Defense AT&T Sun Microsystems Alliance: Unix System V Release 4 Solaris 9 OE Solaris 9 OE x86 Early Access (Dec. 2)

Multiprocessing The Solaris kernel includes: Concurrency on symmetric multiprocessors Adaptive mutual-exclusion locks Interrupts handled as independent threads Fully preemptible, soft real-time support Lightweight Processes

Interrupts Handled As Threads When an interrupt occurs, a new thread is associated with it Partially initialized threads are created beforehand by the kernel to save time when an interrupt occurs The interrupt data is pushed onto the stack of the partially initialized thread, using minimal resources

Soft Real-Time Support The kernel is preemptible at most points, but not all When the kernel is in a non-preemptible state, there is a time limit defined by the hardware before it has to enter a preemptible state

Lightweight Processes Kernel-supported threads of control in a user process Each LWP is associated with a kernel thread

Lightweight Processes (Cont) LWPs share address space with the process, and process resources LWPs allow a user process to have thousands of threads without overwhelming the kernel

Dealing With Deadlocks Prevention by treating interrupts as threads Prevention using mutexes Detection by priority inheritance mechanism Do nothing, when priority inheritance mechanism does not detect the deadlock

Solaris CPU Scheduling James J. Sheasley

Process Scheduling Process States Running Sleeping Ready Scheduling Classes Timesharing Interactive System Real Time

Timesharing  Regular user work. The CPU is rotated between threads at the same priority by time slicing. Compute-bound operations have their priority lowered and I/O-bound operations have their priorities raised.

Interactive Interactive class. This is the same as the Time Sharing class with the addition of a priority increase that is given to the task in the active window. The active window has the highest priority among normal user processes.

System Kernel priorities. This class is used for system threads. The CPU is not shared amongst these threads by time slicing. These system threads run until finished or pre-empted. Fixed priority levels are utilized in this class of processes.

Real Time Processes that require immediate system access, such as critical hardware systems. Interrupt handling is the only classification that gets higher priority that Real Time. Threads will share the CPU through time slicing if they have the same priority. Real time threads have a priority that is constant for the duration of their existence.

Scheduling Class Priorities ClassPriority Time Sharing 0-59 Interactive0-59 System60-99 Interrupt ClassPriority Time Sharing 0-59 Interactive0-59 System60-99 Real Time Interrupt

Time Slicing ts_quantum  the default length of time assigned to a process with the specified priority. ts_tqexp the new priority that is assigned to a process that uses its entire time quantum. ts_slpret  the new priority assigned to a process that blocks before using its entire time quantum. ts_maxwait  If a thread does not receive CPU time during a time interval of ts_maxwait, its priority is raised to ts_lwait. ts_lwait

Thundering Heard Multiple threads waiting on a single resource. All threads awoken when resource becomes free. Additional “inherited” priority property attempts to limit “mad dash” for the resource.

Virtual Memory Demand Paging - Second Chance Two Handed Algorithm Clears, then checks periodically Done in Unison Difference is the handspread

Page Faults Moving page to free list sends it to be written to swap Minor page fault – Page is reclaimed before it can be overwritten Major page fault – Page must be brought in back from swap

Minimal Paging Paging does not happen until free memory falls below lotsfree (1/64 of memory) Page Scanner will scan between a boundry (slowscan to fastscan) Generally, most parameters are tunable by the sysadmin if necessary.

Soft Swapping Tries to keep memory above desfree (half of lotsfree) for a 30 second average If unsucessful, soft swapping occurs. Only swaps idle processes (default is 20 seconds)

Hard Swapping Trying to avoid thrashing 30 second average falls below minfree and current is below desfree Even running jobs can be swapped Favors long running or large processes

Unswappable Processes Realtime Executed by a signal Exiting Zombie System Thread Blocking a higher priority thread

Priority Paging (Solaris 2.6) Cache Pollution hurting performance Program Data now favored over File Cache Enabled 2x lotsfree Only free file cache when free memory is between lotsfree and cachefree Pager gets confused if the file has the executable bit set

Cyclical Page Cache (Solaris 8) Two seperate lists for file cache and program data Sun Claims: Higher Page Reclaims Higher Free Memory Values “Zero” Scan Rates

Conclusion “The Network is the computer” – Sun MicroSystems Solaris 9 OE Questions?