Download Windows2000-Spr-2001-sect-2-group

yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Document related concepts

Copland (operating system) wikipedia, lookup

DNIX wikipedia, lookup

Distributed operating system wikipedia, lookup

VS/9 wikipedia, lookup

Spring (operating system) wikipedia, lookup

Unix security wikipedia, lookup

Windows Phone 8.1 wikipedia, lookup

CP/M wikipedia, lookup

OS-tan wikipedia, lookup

Batch file wikipedia, lookup

Burroughs MCP wikipedia, lookup

OS/2 wikipedia, lookup

Windows NT startup process wikipedia, lookup

Process management (computing) wikipedia, lookup

OS 2200 wikipedia, lookup

Thread (computing) wikipedia, lookup

Amanda Johnson
Hannah Young
Josh Taylor
Rich Carroll
Troy Gladhill
Saunders Roesser
Windows 2000 Flavors
Windows 2000 Professional
Windows 2000 Server
Windows 2000 Advanced Server
Windows 2000 Datacenter Server
• Built Upon Windows NT 4.0
• Combined Features of Windows 9x and NT
.Coms that Use Windows 2000
Data Return
Windows 2000 Features
File Protection
Driver Certification
Full 32 Bit OS
Reduction in
• Internet Integration
• Latest Hardware
4 gig Ram (Pro)
Multiple Users
Internet Connection
Processor Modes
• User Mode
– Environmental subsystems
– Integral subsystems
• Kernel Mode
– The Executive
– Device Drivers
– Microkernel
– HAL (Hardware Abstraction Layer)
Processing Scheme
• Windows 2000 is a “multi-threaded, multitasking operating system capable of running
on computer systems with multiple
• Symmetric multiprocessing
Processes and Threads
• Process: one instance of a running
application and all the memory and other
resources associated with it.
• Thread: one path of execution through the
application's code.
• Multiple threads per process?
– In Windows 2000, a process may contain one or
many threads
Scheduling Threads
• Interrupts (Preemption): used to evenly
distribute time amongst the different
applications that are running
• Concurrency: creates the illusion that the
threads are running in parallel for
machines with one processor.
• Symmetric Multi-Processing (SMP): used
for machines with multiple processors
Consideration for Scheduling
• execution priority: 0 - 31
• Priority 31 reserved for extremely critical
tasks (ex. real-time applications)
• Priority 0 used for certain idle-time tasks
that are performed only when nothing else
is going on.
• Most threads run at priority levels from 7 to
Priority Rules
• High-priority threads are always executed
before low-priority threads.
• Threads with low priority never preempt
threads with high priority.
• If two or more threads have the same
priority, the one that has been executed least
recently is executed next.
Watching Threads in Action
• System Monitor: included in Windows
2000 O/S, displays the number of threads
currently running on the system.
• Why is the count over 10 when nothing is
running other than System Monitor?
– The Windows operating system uses threads
itself for things like fault handling etc.
When Threads Cause
• Two problems
– Starvation occurs when one or more threads in
an application are blocked from gaining access
to a resource and thus cannot make progress.
– Deadlock occurs when two or more threads are
waiting on a condition that cannot be satisfied.
(The ultimate form of starvation.)
Dealing with Deadlock in
Windows 2000
• Mutual exclusion: designed to guarantee
that certain sections of code (critical
sections) will not be executed by more than
one process simultaneously.
• Spinlocks: mutual exclusion mechanism
that stall the processor until a lock is
achieved for a critical section.
Avoidance Aid for
– a Win32-based application that can be used to
effectively analyze and design multithreaded
applications and to help you detect and
eliminate deadlock from your program.
Allowable States
• Process States
– No information was available about Windows
2000 Process States
• Thread States
– One of six different states:
Thread States
Mutual Exclusion and
• Family of objects
• Two levels
– Kernel
– User mode threads
Mutual Exclusion and
Synchronization: Kernel
• Must protect global data structures during
critical sections
• Uses two techniques
– change IRQL
– spinlocks
• Spinlocks only for multiprocessor hardware
– require ownership
Mutual Exclusion and
Synchronization: User Level
Require more synchronization object types
Spinlocks not adequate
Thread requests access to object
Mutual Exclusion and
Synchronization: Object Types
Critical section
Memory Management
• Virtual memory system
– Memory Manager
• Paging
– Demand-paging algorithm
File System
• NTFS – Primary File System
• Support for: Fat16, Fat32, CDFS, NFS,
File System Features
• Disk Quota Support
• Distributed File
• Distributed Link
• Distributed
Authoring and
• Indexing
• Encrypting File
• Removable Storage
and Remote
• Disk Management
• User/Group
Process Management Data
Kernel Process
Process ID
Quota Block
Exception LPC
Debugging LPC
Access Token
Handle Table
Device Map
Memory Management Data
• Virtual Address Space Descriptor
• Working Set Information
• Virtual Memory Information
• Designed to be highly responsive
• Makes use of a priority-driven preemptive
scheduler with a flexible system of priority levels
• Priorities in Win2K are organized into two classes:
– Real Time - for threads requiring immediate attention
– Variable
• Each class consists of 16 priority levels
– Real Time – 16 through 32
– Variable – 0 through 15
Scheduling Continued
• Threads of lower priority are preempted so the
higher priority threads can have access to the
processor when they are ready
• In the real time class, where all threads have a
fixed priority that never changes, threads of equal
priority are in a round-robin queue
• In the variable priority class, a thread’s priority
begins at some initial assigned value and then may
change, up or down, during the thread’s lifetime
– FIFO queue at each priority level, but a process may
migrate to one of the other queues within the variable
priority class
Scheduling Continued
• Variable Class
– If a thread is interrupted because it has used up
its current time quantum, the Win2K executive
lowers its priority
– If a thread is interrupted to wait on an I/O
event, the Win2K executive raises its priority
– Interactive threads tend to have the highest
priorities within the variable priority class
Multiprocessor Scheduling
• In a multiprocessor system with N processors, the
(N-1) highest priority threads are always active,
running exclusively on the (N-1) extra processors
• The remaining, lower-priority, threads share the
single remaining processor
• However, if a thread is ready to execute but the
only available processors are not in its processor
affinity set, then that thread is forced to wait and
the executive schedules the next available thread