Groups | Blog | Home
all groups > sql server clustering > august 2007 >

sql server clustering : Load balancing



aposql
8/29/2007 5:02:05 PM
We have some sp transactions that take minutes to process and tend hog the
cpu resources slowing other requests on a busy website. I have a few
questions.

1. Can a specific cost be assinged to a stored procedure, so as to allow for
the execution of the sp without maxing out the cpu?

2. Should we break out the sp transacation into smaller nested transactions
and use the sql agent to process the transaction?

3 Could we use a cluster and the dtc to assign specific sp to one SQL server
to handle long requests and use the second sql server to handle basic
requests?

4 Other thoughts?

I would appreciate comments and ideas to point me in the right direction.
Geoff N. Hiten
8/30/2007 12:00:00 AM
Comments inline
[quoted text, click to view]
Not really. You can set the maximum degree of parallelism os as to not max
out all the CPUs in a multi-CPU system.

[quoted text, click to view]
As a general rule, SQL does much better at processing lots of small
transactions rather than one large transaction. This is not a universal
rule, just a general guideline.

[quoted text, click to view]
If these are summary or analysis type queries, then you may want to run them
against a copy of the data. Snapshots, replication, mirroring, and log
shipping are all options to create copes of your database for analysis and
ETL sourcing. You may need to take the firs steps towards a reporting and
data warehousing environment.


[quoted text, click to view]
aposql
8/30/2007 7:26:01 PM
Thank you for your thoughts. Does the DTC not allow the specification of
running procedures against a specific server to a single data set.

Also could a clr procedure be used to allow for the management of memory and
resources?

[quoted text, click to view]
Geoff N. Hiten
8/31/2007 9:44:39 AM
More inline

[quoted text, click to view]

Not really. DTC is designed to handle transactions across multiple servers.

[quoted text, click to view]

I don't even want to go there. That is so deep into the guts of how SQL
manages memory and CPU that the odds of success are pretty low. You would
be better off writing your own database engine.


--
Geoff N. Hiten
Senior SQL Infrastructure Consultant
Microsoft SQL Server MVP

AddThis Social Bookmark Button