Configure SQL Server to improve database performance

Source: Internet
Author: User

I. Preface

After the new installation of SQL Server 2005/2008, We need to configure SQL Server Based on the Server's hardware and software facilities to achieve better performance. However, the default configuration is used in most cases.

Ii. Configuration

1. Server attribute page configuration

(1). Security

Server logon permission authentication: Generally, Hybrid Authentication (SQL Server and Windows identity) is used)

(2). Memory/Processors

Automatically set processor affinity mask for all processors: you can set the number of processors Automatically allocated by SQL Server. If the Server load is heavy, it is recommended that SQL Server not assign tasks to all processors, we recommend that you keep two CPUs for the OS.

Automatically set I/O affinity mask for all processors: Automatic IO balancing

(3). Database Setting

Default index fill factor: it is very important to set the page fill percentage. If set to 80: indicates that when the index is created or re-built, the data page will retain 20% of the space for future insertion or modification. This will produce a small number of page splits and improve performance.

Compress backup option: In Server backup, compress is used to reduce IO, but CPU operations are increased.

(4). Connection

Maximum number of concurrent connection: sets the Maximum number of connections.

Use query governor prevent long-running queries: Use the query manager to block time-consuming queries.

Allow remote connections to this server: selected by default

2: SQL Server Configuration Manage (SQL Server 2008 Enterprise Edition)

(1). SQL Server Services

Start, pause, restart, or stop the service

Set the Service Startup method (Automatic, Disable, Manual)

You can also set an account for startup.

Configure startup parameters

In addition, you can set the FILESTREAM attribute in SQL Server.

(2). SQL Server Network Configuration

Shared Memory: it is the simplest protocol available for use and has no configurable settings. Because the client of the Shared Memory Protocol can only connect to the SQL Server instance running on the same computer, it is useless for most database activities.

TCP/IP: TCP/IP is a common protocol widely used on the Internet. It communicates with computers with different hardware structures and operating systems in the Interconnect Network. TCP/IP includes the network traffic standard and provides advanced security functions. It is currently the most commonly used protocol in business.

Named Pipes: a protocol developed for LAN. A part of the memory is used by a process to transmit information to another process. Therefore, the output of a process is the input of another process. The second process can be local on the same computer as the first process) or remote on a networked computer ).

VIA: the virtual interface adapter (VIA) protocol is used together with the VIA hardware. The VIA protocol is not recommended. This function will be deleted in later versions of Microsoft SQL Server.

Suggestion: Generally, TCP/IP works better in a slow LAN, WAN, or dial-up network. When the network speed is not a problem, Named Pipes is a better choice, because it is more powerful, easier to use, and has more configuration options.

(3). SQL Native Client 10.0 Configuration

Client Protocols

Aliases

Protocol is the same as 2). You can specify more configurations.

3. sp_configure/reconfigure

Displays or changes the global configuration settings of the current server. Many configurations need to be set through sp_configure.

Syntax:

 
 
  1. sp_configure [ [ @configname = ] 'option_name'   
  2.     [ , [ @configvalue = ] 'value' ] ]   
  3. reconfigure 

For example:

To configure advanced options with sp_configure, you must first run sp_configure when the "show advanced options" option is set to 1, and then run RECONFIGURE:

 
 
  1. sp_configure 'show advanced option', '1';  
  2. reconfigure 

Distributed Application query:

 
 
  1. sp_configure 'Ad Hoc Distributed Queries','1'  
  2. reconfigure 

Iv. Summary

SQL configuration involves a lot of aspects. I can only talk a few words about my limited skill. I will find more in the future and share it with me.

Original article title: SQL Server performance tuning series (5) -- SQL Server Configuration

Link: http://www.cnblogs.com/changbluesky/archive/2010/08/16/1800497.html

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.