Windows Server 2008 R2 Dev Session 01
-
Upload
clint-edmonson -
Category
Technology
-
view
2.097 -
download
1
description
Transcript of Windows Server 2008 R2 Dev Session 01
What Developers Should Know About Windows® Server 2008 R2
CLINT EDMONSONARCHITECT EVANGELIST
Agenda
Powerful, efficient, and extensible!
“Not Your Average R2…”
The Core Web Application Platform
Ubiquitous and Extensible Platform Technologies
Windows Server 2008 R2Platform Enhancements
Virtualization
Power Efficiency
64-bit Kernel
Multicore & NUMA
Performance, Efficiency & ExtensibilityKernel Changes Windows® 7 (x64) and Windows ® Server 2008 R2 are
based on same kernel Enhancements in many areas:
Multi-core and many-core processing Removal of several coarse-grained locks Desktop and registry memory management optimizations Process & Power efficiency Virtualization Security Management
User Mode Scheduling (UMS)Designed for Performance
Limitation of Fibers is that the kernel doesn’t know about them Some system calls have state associated with underling
thread If Fibers run on multiple threads, state can become
corrupt
UMS solves thread state problem by separating user-mode thread and kernel-mode thread Runtime creates enough threads for concurrency
demands Each thread has user-mode thread (UT) and kernel-mode
thread (KT) state Switching between user-threads doesn’t switch kernel
thread When a user-mode thread goes into kernel mode, it
switches to the corresponding kernel thread
Thread1
Thread2
Cooperative “User-Mode” SchedulingDesigned for Performance UMS enables high-performance multi-threaded apps Concurrent runtimes like ConcRT (Visual Studio) will use UMS
Cooperative Scheduling
Core 2
Thread3
Non-running threads
Core 1
Thread4
Thread5
Thread6
Core 2Core 1
KernelThread
2
KernelThread
1
UserThread
3
KernelThread
3
UserThread
4
KernelThread
4
UserThread
5
KernelThread
5
UserThread
6
KernelThread
6
Thread Scheduling
Kernel
Application UserThread
2
UserThread
1
Removal of Coarse-Grained Locks
Locks serialize access to kernel data structures Prevents multiple threads from simultaneously modifying
data Inhibits scaling because threads must wait for their turn
(contention) Examples:
Dispatcher Lock Memory Manager PFN Lock Cache Manager Virtual Address Control Block (VACB) Lock Object Manager Type Lock
Either replaced with lock-free algorithms or with finer-grained synchronization mechanisms
Memory Optimizations Desktop Window Manager (DWM) re-architecture
reduces memory footprint per window by 50% Registry moved from mapped files to paged pool
Improves performance because views into registry file don’t need to be mapped and unmapped
Working set management improvements: Working set is amount of RAM memory manager assigns
to process or kernel memory type Memory manager uses more information for better tuning System cache, paged pool, and pageable system code
each have own working set Before were in the same working set Now, each tuned according to specific usage, which improves
memory usage
Intelligent Timer CoalescingDesigned for Efficiency
Staying idle requires minimizing timer interrupts Before, periodic timers had independent cycles even
when period was the same New timer APIs permit timer coalescing
Application or driver specifies tolerable delay Timer system shifts timer firing to align periods on a
coalescing interval: 50ms, 100ms, 250ms, 1s
Timer tick15.6 ms
Periodic Timer Events
Windows 7
Windows® Vista
“Trigger-Start” ServicesDesigned for Efficiency
Previously, services typically started at system boot and ran until shutdown
Services can now specify specific start and stop conditions (triggers): Device class arrival and removal
Bthserv: start on Bluetooth device class arrival IP address arrival and removal
Lmhosts: start on first and stop on last IP address availability Firewall port event
Browser: open of NS and DGM ports Domain join and unjoin
W32Time: start on join, stop on un-join Custom Event Tracing for Windows (ETW) event
Appid: start when Security Rollup Package (SRP) enabled
Triggers are stored in service registry key
Trigger-Start ServicesInspecting Service Trigger Events
demo
Native VHD SupportDeveloped for Extensibility Support for fixed, dynamic and differencing VHDs Mount VHD files as new volumes Boot from VHD file VHD driver integrates the virtual volume into the NTFS or FAT file
system Performance within 10% of physical volumes ( with fixed size VHDs) Use the VHD API to create, mount, and utilize VHD files (virtdisk.dll)
F:\
C:\
VHD
Windows
Virtual Hard DisksEasy To Manage & User
demo
Guest Partition
Enterprise baseVHD
3
Physical Server HardwareCPU, memory, disk, and network
Maintenance OS1
Hypervisor
Host Partition
Server CoreVHD
Host Differencing
VHD
2
Guest Partition Guest Partition
Guest Differencing
VHD
WebVHD
Service 1Bits
Server Core base VHD
Guest Differencing
VHD
WorkerVHD
Service 2Bits
Guest Differencing
VHD
WorkerVHD
Service 3Bits
4
5
6
7
Agenda
New opportunities for .NET and ASP.NET applications!
The Core Web Application Platform
Ubiquitous and Extensible Platform Technologies
“Not Your Average R2…”
The Server Core Web Application Platform
Server, Server Roles (for example
only)
ServerWith .NetFx, Shell,
Tools, etc.
Server CoreSecurity, TCP/IP, File Systems, RPC,plus other Core Server Sub-Systems
Server Core Server Roles and Optional Features
GUI, Shell, IE, Media, Mail, Etc.
.NET2.0
.NET3/3.5
ASP.NET IIS PS
DNSDHC
PAD File
ADLDS
PrintMedia Serve
r
Cert Server
Hyper-V
TSADF
SWDS etc
Server Core Architecture
WoW64
Windows PowerShell™ 2.0Integrated with Windows Remote Management New integrated debugger New optional GUI environment Seamless integration with remoting and domain identity Extend your applications with a custom PowerShell object-model
PowerShell™ 2.0Integrated Scripting Environment
demo
Agenda
Your applications extend the platform!
Ubiquitous and Extensible Platform Technologies
“Not Your Average R2…”
The Core Web Application Platform
Windows Web Services APIAnother Option for Web Services
Web services targeted at unmanaged code No dependency on .NET framework
Allows both client and server endpoints Interoperability with WS-* SOAP stacks Windows Communication Foundation (WCF) ASP .NET XML Web Services (ASMX) Non-Microsoft stacks
System component of Windows Server 2008 R2 System component of Windows 7 Available for Windows XP, Windows Vista ®, Windows Server
2003, Windows Server 2008 Libraries included in Windows 7 SDK
Learn More About Windows Server 2008 R2
Resources
Microsoft.com http://www.microsoft.com/windowsserver2008/en/us/
R2.aspx
MSDN Channel9 http://channel9.msdn.com/tags/W2K8R2
MSDN Code Gallery http://code.msdn.microsoft.com/w2k8r2
MSDN Server Develop Center http://msdn.microsoft.com/en-us/windowsserver
© 2009 Microsoft Corporation. All rights reserved. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the
date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.