Você está na página 1de 69

Agenda

Why 64-bit?

Challenges in a 32-bit Environment

How does 64-bit Architecture Augment 32-bit Capabilities Benefits of SQL Server 2000 64-bit

Scalability High Availability

Server and Database Consolidation with 64-bit Interoperability and Management Q&A

Why 64-bit ?

Nine out of Ten times database is blamed for slow performance


Applications are bound to be have inefficient code Developers will always write un-optimized queries

As soon as you conquer a bottleneck another one pops up


Remarkable improvements in hardware Scale-Up is the BEST way to lower TCO

Why 64-bit ?

In order to better understand what 64-bit architecture offers us, we will review:

Compare 32-bit limitations to 64-bit Intel Itanium 2 architecture Microsoft Windows 2003 64-bit changes SQL Server 2000 64-bit changes

SQL Server 32-bit Scalability

Scales well for the most part for large transaction and data warehousing applications
Supports

Up to 32 CPUs Up to 64 GB RAM Fiber mode Clustering for failover VLDB/Terabyte databases Parallelism throughout

I/O, query plans, query execution, index creation

Why 64-bit?

Memory Management

Max memory supported is 4GB Kernel reserves 2 GB


As a result SQL Server can only utilize 2 GB Can use /3GB switch in boot.ini

Kernel gets 1 GB and SQL Server gets 3 GB

Procedure Cache is limited to 4 GB per instance

Practical limit is less than 3 GB

Limited scope for Pagelife expectancy MemToLeave is reserved at 256 MB


Used for out of process, higher than 8K memory request Can be changed by using startup switch g

No such limitations in 64-bit

Why 64-bit?
SQL Server 32-bit Win 32 Subsystem (Csrss.exe) My 32-bit Application

User Mode Kernel Mode

Windows Kernel Manager

Max virtual addressing is limited to 4 GB Windows OS splits 2 GB each between User and Kernel

In Windows 2003 64-bit, Kernel and User mode split 8 Terabytes each

Why 64-bit?
SQL Server Address Space

In 64-bit /3GB and/or /PAE not used

Server Net-Lib DLLs Open Data Services Code

SQL Server Code

Distributed Query OLE DB Providers OLE Automation Objects Extended Stored Procedures Memory Pool System Data Structures

Starts with 2 GB 3 GB with /3GB Switch in boot.ini 64 GB with AWE /PAE switch in boot.ini

Procedure Cache

Procedure Cache Maximum 4 GB

Buffer Cache

Log Cache Connection Context

Why 64-bit?

Memory

AWE not used in 64-bit

AWE (Address Windowing Extension)


Allows SQL Server to utilize up to 64 GB RAM Requires /PAE switch in boot.ini Not same as real memory, only available to buffer pages Pages are mapped and unmapped
Virtual Address Space Physical memory
64 GB 4 GB

AWE Window

AWE Memory

User Address Space

0 GB

Why 64-bit?
Distribution of RAM in SQL Server Memory Pool

250000

200000 Data Pages Free Pages Page Life Expectancy 100000 Procedure Cache Pages Total Pages Avg. # of 8K pages 50000

150000

0 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

Time 6:00 am till 8:00 pm

Real-world ERP stress test analysis on memory contention Higher procedure cache = lower buffer cache = lower cache hit ratio = slower performance

Why 64-bit?
SQL Compiles Verses Auto-Param Attempts

60

50

40 Auto-Param Attempts/sec 30 Batch Requests/sec SQL Compiles/sec

20

10

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

Time 6:00 am till 8:00 pm

Real-world ERP stress test analysis on memory contention


Higher procedure cache use can be attributed to higher SQL compiles Application inefficiency

Why 64-bit?

CPU

Increased CPU parallelism and scheduling benefits in 64-bit

SQL Server runs as a single process


Multiple thread divided in to UMS objects A thread executes code within the processs address space Fibers are light weight threads Supported through light weight pooling configuration option Performance improvement noticed in servers with over 12 CPUs Optimizes SQL Server thread management Designed to maximize CPU capabilities

SQL Server supports Fiber mode


User Mode Scheduler (UMS)

User Mode Scheduler


CPU 0 CPU 1 CPU 2
Workers in Runnable status assigned to CPU by UMS Scheduler

CPU n

UMS Scheduler
Query Results

UMS Scheduler Worker Pool

UMS Scheduler Worker Pool

UMS Scheduler Worker Pool

Network

Worker Pool

Workers

Workers

Workers

Workers

UMS Work Queue

UMS Work Queue

UMS Work Queue

Work requests assigned to workers in pool

UMS Work Queue

Work Requests

Network

Context Switching

CPU

Operating System does preemptive scheduling for CPU contention Can result in excess Context Switching

OS spends more resources on context switching and less resources doing the actual work Is a result of processor or disk queues OS performs memory block updates for each thread swapped

Context Switching
Context Switching and Performance
160 140 120 100 80 60 40 20 0 5

144 114 86 89 61 21 3 8 Load Factor Context Switches/Sec 6 15 6 Transactions/Sec % Total Processor 104 95 77 Avg Disk Queue

Higher CPU or I/O contention = Higher context switching = Lower SQL Server throughput

Context Switching is less of an issue on 64-bit

32-bit I/O

I/O limitations

I/O queues can lead to higher context switching

Windows API

32-bit calls to the disk sub system

Multi-Instance

Cannot effectively use dynamic memory Easy to hit the ceiling with maximum hardware utilization Need to implement CPU affinity

Multi-Instance on 32-bit

Multi-Instance

Memory above 4 GB is only available for buffer pages A single runaway query can cause all instances to suffer Application usage is dynamic and user load is unpredictable

Need to allow single instance adapt to its own hardware affinity SQL Server works best with dynamic configuration of memory and CPU rather than affinitizing hardware resources

Multi-Instance is much easier in 64-bit

Reasons To Stay With 32-bit


If the queries are not memory intensive Fiber mode is not an issue

High levels of CPU parallelisms is not required


Maintenance window is fairly flexible Large scale consolidation is not required Applications and queries are well tuned Mostly running in-house built applications

Agenda

Challenges in a 32-bit Environment

How does 64-bit Architecture Augment 32bit Capabilities


Benefits of SQL Server 2000 64-bit

Scalability High Availability

Server and Database Consolidation with 64-bit Interoperability and Management Q&A

Intel Itanium 2 Architecture

Madison is Intel's third-generation 64-bit processor


30-to-50 percent greater performance than McKinley Large "flat" or linear memory addressability

264 = 18 billion GB memory addressability Allows pinning of large data sets Allows CPUs to process more data and numerical computations at a time

128 floating-point and 128 integer registers

Best suited for multi-threaded applications that leverage true parallelism on the processor

Intel Itanium 2 Architecture

Design Goals

Improved throughput Better on-chip cache management Improved multiprocessor performance Increased on-die optimization for specific tasks such as encryption Performance and scalability optimized Better parallel processing Floating point performance Manage high or unpredictable work loads Complex data sets High performance for large memory resident data sets

Intel Itanium 2 Architecture

Intel Itanium 2 Architecture

Intel Itanium 2 Architecture

Based on Explicitly Parallel Instructional Computing (EPIC) technology

Can process large number of instructions simultaneously "predication"

Ability to maximize parallel processing by predicting lines of code before they go through compiler Ensures the caching of data and instructions to the CPU before it is actually required Allows for more processing during each clock cycle

"speculation"

High degree of parallelism

Intel Itanium 2 Architecture

Windows 2003 64-bit

64-bit systems can theoretically address

264 = 18 billion GB memory addressability 64-bit Windows Server 2003 is built with a maximum of 16 Terabyte memory addressability 64-bit edition of Windows Server 2003 Datacenter Edition supports up to 512 GB memory

32-bit Intel architecture is limited to a maximum of 32 processors; 64-bit technology removes that barrier Noticeable performance improvements with Fiber mode

Windows 2003 64-bit

Enterprise Edition 1-8 processors, 64GB, 8-Node Cluster Service

Feature

Enterprise Edition Supported

Datacenter Edition Supported

Non-uniform memory support (NUMA)

Memory CPUs

64 GB 8 Supported

512 GB 64 Supported

Datacenter Server 64 CPUs, 512 GB, Improved SMP Scaling, 8 Node cluster

Network load balancing

Clustering Services

8 nodes

8 nodes

Windows Memory Architecture

Windows 32-bit and 64-bit comparison


Comparison of 64-bit and 32-bit Architectures
Architectural Component 64-bit Windows 32-bit Windows

Virtual memory
Paging file size Hyperspace Paged pool Non-paged pool

*16 terabytes
512 terabytes 8 GB 128 GB 128 GB

4 GB
16 terabytes 4 MB 470 MB 256 MB

System cache
System PTEs

1 terabyte
128 GB

1 GB
660 MB
Source: Windows Server 2003 64-bit Edition Technical Overview

* 8 Terabytes User and 8 Terabytes Kernel

Windows Memory Architecture

Virtual Memory

Extends available physical memory by use of page file On disk file used to extend physical memory by way of swapping pages Special memory region used to map process working set Region in system memory used by Kernel-mode components to allocate system memory Paged pool memory can be swapped

Paging File

Hyperspace

Paged Pool

Windows Memory Architecture

Non-paged Pool

Memory pool that is resident (not paged) and is used by Kernel-mode

System Cache

Used to map open files

System PTEs

System Page Table Entries used to map kernel stack, memory descriptors and I/O space

Windows 2003 64-bit

CPU and I/O Benefits

CPU parallelism

Better scheduling Less resource contention Better multiprocessing Faster file allocation Multipath I/O

Fast file I/O


Provides more than one physical path to access storage Extra support points protect against data loss and system failure

Windows System Resource Manager (WSRM)

Allows effective management of CPU and memory on large scale-up architectures

Windows 2003 64-bit

WSRM Features:

Set hardware allocation policies for applications


For example CPU or memory usage targets or limits Apply policies on a date/time schedule

Fix working set size by process Manage committed memory (pagefile usage) Generate, store, view, and export resource utilization accounting records for management, service level agreement (SLA) tracking, and charge-back purposes

Makes SQL Server administration easy as resource management is handled by the OS Benefits Server consolidation implementations

SQL Server 2000 64-bit

Fully recompiled code base in 64-bit


Design Goals

Improve database performance for large complex queries through large memory addressability Reduce disk swapping as compared to large memory on 32-bit server Code-compatible T-SQL No changes in on-disk database files Easy upgrade/migration

Default configuration values are the same Better leverage hardware with dynamic and adaptive algorithms

SQL Server 2000 64-bit Error Log


Contents of C:\Program Files\Microsoft SQL Server\MSSQL\LOG\ERRORLOG: --------------------------------------------------------------------2003-10-11 16:32:31.53 server Microsoft SQL Server 2000 - 8.00.760 (Intel IA-64) Feb 6 2003 16:07:24 Copyright (c) 1988-2003 Microsoft Corporation Enterprise Edition (64-bit) on Windows NT 5.2 (Build 3790: )

2003-10-11 16:32:31.53 server Copyright (C) 1988-2002 Microsoft Corporation. 2003-10-11 16:32:31.53 server All rights reserved. 2003-10-11 16:32:31.53 server Server Process ID is 1404. 2003-10-11 16:32:31.53 server Logging SQL Server messages in file 2003-10-11 16:32:31.54 server SQL Server is starting at priority class 'high'(16 CPUs detected). 2003-10-11 16:32:31.55 server Large Page Extensions enabled. 2003-10-11 16:32:31.55 server Large Page Granularity: 16777216 2003-10-11 16:32:31.55 server Large Page Allocated: 32MB 2003-10-11 16:32:32.33 server SQL Server configured for fiber mode processing. 2003-10-11 16:32:32.33 server Processor affinity turned ON, processor mask 0xfffc 2003-10-11 16:32:32.33 server Using dynamic lock allocation. [2500] Lock Blocks, [5000] Lock Owner Blocks. 2003-10-11 16:32:32.48 server Attempting to initialize Distributed Transaction Coordinator. 2003-10-11 16:32:34.50 server I/O affinity turned ON, processor mask 0x0000000000000001 2003-10-11 16:32:34.63 spid2 Starting up database 'master'. 2003-10-11 16:32:34.78 server Using 'SSNETLIB.DLL' version '8.0.760'. 2003-10-11 16:32:34.78 spid5 Starting up database 'model'. 2003-10-11 16:32:41.20 spid2 Recovery complete.

SQL Server 2000 64-bit

Analysis Services 64-bit

Can effectively use larger memory addressability for higher performance Benefits from parallelism in partition processing Cube queries and processing is much faster Very large dimensions and member properties can be supported in memory Due to large buffer pool avoids use of temporary files during processing

Several orders of magnitude more and larger replicas possible with out impacting overall performance or amount of memory allocated to other objects

SQL Server 2000 64-bit

Reporting Services for SQL Server 2000

Report authoring

Build custom applications using the Web services Publish and manage report definitions as a Web service

Report management

Report delivery

Supports on-demand (pull) and event-based (push) report delivery

32-bit version available in Beta 2 64-bit version will be available in Yukon time frame

Upgrading SQL Server 2000 32-bit to 64-bit

As simple as detach a SQL Server 2000 32bit database and attach it to a SQL Server 2000 64-bit server Can also use BACKUP DATABASE Little more involved if:

Multiple databases are moved to one 64-bit server Multiple servers are moved to one instance 64bit Multiple databases/servers are moved to multiple instances 64-bit

Agenda

Challenges in a 32-bit Environment


How does 64-bit Architecture Augment 32-bit Capabilities

Benefits of SQL Server 2000 64-bit

Scalability
High Availability

Server and Database Consolidation with 64-bit Interoperability and Management

Q&A

Benefits of SQL Server 2000 64-bit

Applications that can benefit from SQL Server 64-bit:


High transaction OLTP Data warehousing and analysis (BI) Global-scale Web services E-commerce applications with an unbounded number of users Statistical modeling and analysis Geo-spatial applications

Large data row lookups Large data growths (database size) Large growth in number of users

Benefits of SQL Server 2000 64-bit

Applications that involve multiple parallel threads of work, where performance would be enhanced by true parallelism on the processor Applications that use complex and compute-intensive calculations Applications performing data encryption and decryption Improved query performance

Using VLDBs with many concurrent users Query plans that use in-memory hash joins, merge joins, hash aggregates and sorts

Benefits of SQL Server 2000 64-bit

Relational Engine leverages 64-bit for faster execution of complex queries


Higher degree of CPU parallelism Faster and more accurate threading model Faster query processing & index building Faster I/O (read verses write) Large memory support (512 GB) Improved support for fiber mode

Storage Engine leverages better I/O threading and multipath I/O UMS is more efficient due to Itanium2 architecture enhancements

Application Benefits

Application can

Support large number of users

Increase performance through caching Store and manipulate large data sets in memory Can leverage 64-bit API set

In addition

Existing 32-bit applications can run normally using Windows on Windows 64-bit (WOW64-bit) 32-bit and 64-bit applications can run side-by-side

Why OLTP Benefits from 64-bit ?


Small transactions are more thread intensive


64-bit provides the faster thread execution mode

Faster I/O Windows Multipath I/O


Lower Context Switching with lower CPU queues Logical reads are faster as more data can be cached Avoid page faults

Why Data Warehousing (BI) Benefits from 64-bit ?

MOLAP dimension processing capabilities expanded beyond 8 million members Faster aggregation processing due to 64-bit memory addressability

Complex joins, grouping and sorting is faster with in-memory execution


Large buffer reads are faster with parallelism Disk I/O is minimized with large buffer caching

Benefits of SQL Server 2000 64-bit

TPC Performance

Source: www.microsoft.com Windows/SQL Server 64-bit TPC-C Performance

Scaling Line of Business Applications

SAP Benchmark
Advanced Planner and Optimizer (APO) Demand Planning (DP)
586,319
600,000 500,000 400,000 300,000 200,000 100,000 0 474,162

Record Performance

586,319 planning scenarios per hour 24% performance advantage over IBM 4 Times better scaling than HP

157,555

Unisys

ES7000

IBM p690

HP

rx5670

Scaling Line of Business Applications

Seibel Benchmark

Results:
Siebel 7 Architecture on Unisys ES7000 / Windows 2003 servers and Microsoft SQL Server 2000 (64bit) easily scales to 30,000 concurrent users. Vertical scalability The Siebel 7 Server showed excellent scalability within a Unisys application server. Horizontal scalability The benchmark demonstrates scalability across multiple Unisys servers without degradation. Supporting Siebel 7 Server application services with 3302 database connections on the Unisys ES7000.

Benefits of SQL Server 2000 64-bit

Analysis Services (OLAP) Improvements


Exponentially faster Cube building process

Quick millisecond query lookups due to large memory support MOLAP dimension processing capabilities expanded beyond 8 million members MOLAP cube processing in parallel twice as fast as sequential processing MDX queries can scale nicely from 8 to 16 processors

Benefits of SQL Server 2000 64-bit

Analysis Services (OLAP) Benchmark

Figure 8 depicts that using 64-bit processing of 4, 8, 16 and 32 million member dimensions were processed. 32-bit was not able to process over 8 million members.

Benefits of SQL Server 2000 64-bit

Analysis Services (OLAP) Benchmark

Figure 11 summarizes the resulting cube processing rates when tested with both 8 CPUs and 16 CPUs. Cube processing rate is defined as a number of fact rows processed per minute.

High Performance & Availability Like Mainframe and UNIX, But at Low TCO

Increased productivity Lower cost of ownership New application opportunities 64-bit offers what mainframe and UNIX traditionally offer Unlimited I/O capacity with UNISYS platform Itanium 2 chips are the fastest on the planet TRUE Scaling UP on SQL Server has just begun !

Agenda

Challenges in a 32-bit Environment


How does 64-bit Architecture Augment 32-bit Capabilities

Benefits of SQL Server 2000 64-bit

Scalability

High Availability

Server and Database Consolidation with 64-bit Interoperability and Management Q&A

64-bit Clustering
Up to 8 Nodes Supported
Client PCs

Virtual SQL Server A


Node 1

Public Network Heartbeat

Virtual SQL Server B


Node 2

Private Net
Local Disk

Local Disk

Node 3 Node 5 Node 7

Disk A
Node 4

Disk B

Node 6 Node 8

Cluster Failover Memory & CPU Configuration Planning


If you poured contents from one glass into another

Would all contents fit into one glass?


Memory Resources CPU Resources

64-Bit dynamically manages memory

64-bit Clustering

Nodes limited only by the number supported by the operating system Cannot upgrade 32-bit cluster install to 64-bit

Install 64-bit Windows 2003 Install 64-bit SQL Server Not supported on Windows NT and 2000 Use VFI utility to verify if a resource is 32-bit or 64bit

Does not support 32-bit cluster resources

64-bit Clustering

Utilities supported

Service manager and server network utility All command line utilities are supported

Remote administration through client tools installed on 32-bit


Enterprise Manager Query Analyzer Profiler

64-bit Clustering

Services available on SQL Server 2000 64-bit:


SQL Server service

SQL Agent service Full-Text Search Analysis Services Replication

Not available

SQL Mail

SQL Agent Mail can be configured by Enterprise Manager Can use sp_oa* Command line dtsrun.exe is supported

Graphical DTS

Agenda

Challenges in a 32-bit Environment


How does 64-bit Architecture Augment 32-bit Capabilities

Benefits of SQL Server 2000 64-bit


Scalability High Availability

Server and Database Consolidation with 64-bit


Interoperability and Management Q&A

Server and Database consolidation

Server consolidation

More than just a user database

Database consolidation
Multi-instances Great fit for Server and Database consolidations TRUE scale-up with 64-bit

Consolidation

Consolidation is the process of bundling of:


Multiple SQL Server machines in to one machine Multiple SQL Server instances in to one instance Multiple SQL Server databases in to one instance

Consolidation involved considerable planning but results can be remarkable Is based on leveraging better, more reliable and more powerful hardware such as UNISYS Can significantly drop the TCO

Reduced overall cost of management

Requires benchmarks for a successful deployment

Why Consolidate on 64-bit ?

Reduced Costs

License costs

Better utilization of hardware resources Reduced cost of management

64-bit allows for unlimited hardware expansion WSRM

Allows of allocation of hardware resources amongst multiple SQL Server instances

SQL Server 2000 performs best with default dynamic and adaptive algorithms

Consolidation Framework
Criteria
OLTP verses Data warehousing SQL Server Transactions/sec to BatchRequest/sec ratio Number of concurrent active users Degree of deviation between resource utilization over a period of time DOP for batch process and complex queries Uptime requirements Response time requirements Ownership and management Network requirements

Considerations
Mix the types of applications to avoid contention High volume of transactions can lead to I/O bottleneck In Sysprocesses look for active user count Helpful in planning for hardware upgrades

Allows for better utilization of hardware Allows for proper use of WSRM configuration User requirements must be evaluated for each application that is consolidated Requires skilled DBA Will benefit linked servers and Replication

Security
Departmental charge backs

First evaluate security requirements


WSRM allows for

Consolidation Scenario

Windows 2000 Advanced Server Windows 2003 64-bit Data Center Server SQL Server 2000 Enterprise Edition SQL Server 2000 64-bit

8 GB RAM 8 CPUs to 32 GB RAM 32 CPUs 512 GB RAM 64 CPUs Single/multiple SQL Server Instances

ES7000 Orion 560

WSRM Affinity
HR

8 CPUs 16 32 64

Finance
SAN RAID Drive H Drive F T R Maintenance Accounting Reporting

Agenda

Challenges in a 32-bit Environment


How does 64-bit Architecture Augment 32-bit Capabilities

Benefits of SQL Server 2000 64-bit


Scalability High Availability

Server and Database Consolidation with 64-bit

Interoperability and Management


Q&A

Interoperability and Management

Existing 32-bit applications run in WOW64


WoW64 Windows for Windows 64-bit

32-bit Windows compatibility environment Sits on top of 64-bit Windows

32-bit and 64-bit applications can run side by side


No loss of functionality Easy incremental transition from 32-bit to 64-bit

Investment in 32-bit is protected

No support for 16-bit applications

Interoperability and Management

OS level compatibility

Directory structure and filename has not changed

Kernel32, user32

SysWoW64 directory contains 32-bit content of SYSTEM32 directory

WinSxS directory for 32-bit applications running side by side on 64-bit Program Files directory has separate directories for 32-bit applications and 64-bit applications

Default 32-bit applications install path -- C:\Program Files (x86)\ Default 64-bit applications install path -- C:\Program Files\ Applications can be easily identified

Protects against developer errors

Does not allow mixing of 32-bit controls in a 64-bit process

Interoperability and Management

OS level compatibility

Support for coexistence of 32-bit and 64-bit COM components

Separate HKEY_LOCAL_MACHINE\Software registry trees for 32-bit and 64 bit 32-bit keys are located under HKEY_LOCAL_MACHINE\Software\WOW6432Node Can use Regedit.exe to view registry Registry reflector

Copies compatible keys between the two trees

Interoperability and Management

OS level compatibility

Windows Management Instrumentations (WMI)


Can be used as command line utility to verify applications Some commands


CPU get <parameters> for CPU related info Path Win32_Process list all process on local system Path Win32_Process call /? list all methods you can call on the process type

Windows 2003 Resource Kit Tools and Administration Tools Pack available for 64-bit

http://www.microsoft.com/downloads/

SQL Server level compatibility


Tools available in 32-bit version only Can use Enterprise Manager to manage both 32-bit and 64-bit SQL Servers

64-bit Readiness

Database

SQL Server 2000 Enterprise Edition (64-bit)

Business Applications

Baan, JD Edwards, SAP, SAS, Siebel

IT Infrastructure

Anti-Virus: Computer Associates eTrust, Symantec Antivirus Backup/Restore: Legato Systems Management: BMC, OpenView, Tivoli Application Platform: BEA WebLogic

A Summary of Todays Session

SQL Server 32-bit is suitable for most medium to large scale applications

To extend beyond 32-bit capabilities consider 64-bit

SQL Server 2000 64-bit is built on top of a rock-solid foundation


Intel Itanium2 architecture Microsoft Windows 2003 64-bit

SQL Server 2000 64-bit provides:


Significant reduction in TCO, Scalability and Reliability Scaling-Up is much simpler Large-scale server consolidation Simple upgrade and migration paths Interoperability and ease of management

Você também pode gostar