Wednesday, March 21, 2012
parallelism sql 2000
I've been reading some docs about parallelism but I'm still not sure how it
works. My doubt is:
To work with parallelism, do I need to use partitioned tables/index? If yes,
how?
I'm using a dell power edge 6000 with 4 processors.
kind regards
BertoliYou don't need to have partitioned tables to use parallelism. All you need
are multiple CPU's. Parallelism is the striping of a query across multiple
CPU's. In many cases, this speed up the query. In a minority of cases, it
slows down the query. However, you can turn off parallelism for that query
by using OPTION (MAXDOP 1).
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Toronto, ON Canada
.
"Bertoli" <bertoli@.bertoli.com.br> wrote in message
news:%23ZJszXxYGHA.3532@.TK2MSFTNGP05.phx.gbl...
Dear friends,
I've been reading some docs about parallelism but I'm still not sure how it
works. My doubt is:
To work with parallelism, do I need to use partitioned tables/index? If yes,
how?
I'm using a dell power edge 6000 with 4 processors.
kind regards
Bertoli|||SQL Server will parallelize queries as it is able (if you allow it to do
so). You do NOT need to create partitioned tables to use this feature.
Keith Kratochvil
"Bertoli" <bertoli@.bertoli.com.br> wrote in message
news:%23ZJszXxYGHA.3532@.TK2MSFTNGP05.phx.gbl...
> Dear friends,
> I've been reading some docs about parallelism but I'm still not sure how
> it
> works. My doubt is:
> To work with parallelism, do I need to use partitioned tables/index? If
> yes,
> how?
> I'm using a dell power edge 6000 with 4 processors.
> kind regards
> Bertoli
>|||tks guys
Bertoli
"Bertoli" <bertoli@.bertoli.com.br> escreveu na mensagem
news:%23ZJszXxYGHA.3532@.TK2MSFTNGP05.phx.gbl...
> Dear friends,
> I've been reading some docs about parallelism but I'm still not sure how
it
> works. My doubt is:
> To work with parallelism, do I need to use partitioned tables/index? If
yes,
> how?
> I'm using a dell power edge 6000 with 4 processors.
> kind regards
> Bertoli
>|||You can get more info from BOL by searching for
* Max degree of parallelism
Thanks
Ajay Rengunthwar
parallelism sql 2000
I've been reading some docs about parallelism but I'm still not sure how it
works. My doubt is:
To work with parallelism, do I need to use partitioned tables/index? If yes,
how?
I'm using a dell power edge 6000 with 4 processors.
kind regards
BertoliYou don't need to have partitioned tables to use parallelism. All you need
are multiple CPU's. Parallelism is the striping of a query across multiple
CPU's. In many cases, this speed up the query. In a minority of cases, it
slows down the query. However, you can turn off parallelism for that query
by using OPTION (MAXDOP 1).
--
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Toronto, ON Canada
.
"Bertoli" <bertoli@.bertoli.com.br> wrote in message
news:%23ZJszXxYGHA.3532@.TK2MSFTNGP05.phx.gbl...
Dear friends,
I've been reading some docs about parallelism but I'm still not sure how it
works. My doubt is:
To work with parallelism, do I need to use partitioned tables/index? If yes,
how?
I'm using a dell power edge 6000 with 4 processors.
kind regards
Bertoli|||SQL Server will parallelize queries as it is able (if you allow it to do
so). You do NOT need to create partitioned tables to use this feature.
--
Keith Kratochvil
"Bertoli" <bertoli@.bertoli.com.br> wrote in message
news:%23ZJszXxYGHA.3532@.TK2MSFTNGP05.phx.gbl...
> Dear friends,
> I've been reading some docs about parallelism but I'm still not sure how
> it
> works. My doubt is:
> To work with parallelism, do I need to use partitioned tables/index? If
> yes,
> how?
> I'm using a dell power edge 6000 with 4 processors.
> kind regards
> Bertoli
>|||tks guys
Bertoli
"Bertoli" <bertoli@.bertoli.com.br> escreveu na mensagem
news:%23ZJszXxYGHA.3532@.TK2MSFTNGP05.phx.gbl...
> Dear friends,
> I've been reading some docs about parallelism but I'm still not sure how
it
> works. My doubt is:
> To work with parallelism, do I need to use partitioned tables/index? If
yes,
> how?
> I'm using a dell power edge 6000 with 4 processors.
> kind regards
> Bertoli
>|||You can get more info from BOL by searching for
* Max degree of parallelism
Thanks
Ajay Rengunthwar
Parallelism Question
a query in parallel make such a dramatic difference to performance ?
We have a reasonably simple query which brings in data from a few none
complex views. If we run it on our 2x2.4Ghz Xeon server it takes 6
minutes plus to run. If we run this on the same server with
OPTION(MAXDOP 1) at the end of the same query it takes less than a
second.
Examining the execution plan, the only difference I have been able to
see is that parallelism is taking up 96% of the run time when using
two processors. This drops when using the one so a sort takes up the
vast majority of the time for the query to run.
OK, so running in parallel should mean that it's run in various parts
and then 'joined up' later for performance gains, but how can it get
it so wrong (timewise) ?
If this is the case, will I see a significant difference changing our
server to use a single processor, which seems completely the wrong
approach (or should I do this on each query in each app - eek) ?
Do we have a problem that we don't know about that causes it to take
this long ?
What can we do ? Ideally, using both processors would seem to be
preferrable.We've changed the server to use a single processor at the moment and
the report that my query is based on works almost instantly. We're
waiting to see what effect this has for other users, but so far,
no-one has complained.
Are we wasting a second processor ?|||"Ryan" <ryanofford@.hotmail.com> wrote in message
news:7802b79d.0312160816.68d60164@.posting.google.c om...
> We've changed the server to use a single processor at the moment and
> the report that my query is based on works almost instantly. We're
> waiting to see what effect this has for other users, but so far,
> no-one has complained.
> Are we wasting a second processor ?
No. There are definitely times it can help.
You may want to open a ticket with MS. In general, when the query optimizer
finds such a poor optimization they consider it a bug. (If you can, review
Kalen Delaney's article in this month's SQL Server Magazine.)
Parallelism query
I have a sql 2000 server with 8 processors, server settings are as
default. I read on Technet that it is good practise to remove the
highest no. processors from being used for parallelism, corresponding
to the no. of NICs in the server. One of our 3rd party developers has
recommended only allowing one processor to be used as there is a
performance hit by the server working out which processor to use. Does
anyone have a definitive answer to this? I suspect he's wrong but I'd
like some hard evidence if possible, thanks.
Kev
Hi Kev,
Requirement for multi processors/Degree of parallelism depends upon the kind
of transaction thats been executed on the server.
If your nature of query includes more of insert, delete and update statments
(doesn't include heavy complicated queries), then query optimizer is wasting
its time evaluating each query to see if it can take advantage of
parallelism.
On the other hand, if the nature of queries include complex joins,
correlated subqueries, which takes maximum amount of time to execute the
query, then it makes sense to have DOP > 1.
You can read more about this at
http://www.sql-server-performance.co...n_settings.asp
- - - - - - - - -
Thanks
Yogish
"Network SI (UK) Ltd" wrote:
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on Technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>
|||Your third party developer doesn't know what he is talking about. There is
overhead when you use query parallelism (of course) but that doesn't mean
you shouldn't use it. 2 processors working at 90% of their capacity still
return the results quicker than 1 processor working at 100%. Depending on
how your server is used, it is usually be a good idea to limit the maximum
number of processors that can be used per query, so that one query doesn't
block all the processors. What the ideal limit is, is something you have to
experiment with, depending on the number of large select queries vs.
insert/update/inserts and the performance you want of them respectively. For
example, if performance of updates is of the highest importance, and
performance of reporting on the server is of less importance, you would set
the maximum number of processors for parallelism to 1. On the other side of
the scale is something like a staging/processing server for a datawarehouse,
where there's mostly only one process running at a time. In that case you
set the maximum number of processors for parallelism to the number of
physical processors you have.
I don't completely agree with the Technet recommendation. Multiple
connections can share one NIC, and processor usage and network traffic are
usually somewhat correlated, but it is by no means straightforward.
SELECT * FROM multi_million_row_table
will cause a lot of network traffic, but not a lot of processor activity,
where
SELECT * FROM multi_million_row_table WHERE unindexed_column = <some value>
will cause less network traffic, but more processor activity.
Jacco Schalkwijk
SQL Server MVP
"Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on Technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>
|||Following the logic of the 3rd party developer why not just scrap the big
iron and by a cheap server box?
Try a few configurations and use whichever works best for you. I suspect
that you should be able to enable 6,7, or even all 8 processors. I assume
that you are talking about 8 physical processors (not 4 physical with
hyperthreading enabled).
Keith
"Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on Technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>
|||Thank you for the 3 quick replies, confirming my feelings. Does anyone have
any 'Best Practise' recommendations or is it best to suck it and see?
Kev
Network SI (UK) Ltd
"Keith Kratochvil" wrote:
> Following the logic of the 3rd party developer why not just scrap the big
> iron and by a cheap server box?
> Try a few configurations and use whichever works best for you. I suspect
> that you should be able to enable 6,7, or even all 8 processors. I assume
> that you are talking about 8 physical processors (not 4 physical with
> hyperthreading enabled).
> --
> Keith
>
> "Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
> news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
>
>
|||Best thing would be to experiment and get some baseline. Get the a few of
the largest queries you have and run them with MAXDOP(1) to MAXDOP(8) (so
only those query are limited in the number of processors), and see what the
execution times are. It's pretty easy to create a script and run the whole
thing at a quiet time over the weekend or so
Jacco Schalkwijk
SQL Server MVP
"Network SI (UK) Ltd" <NetworkSIUKLtd@.discussions.microsoft.com> wrote in
message news:36784A55-E20F-4E2B-AE6B-BF38C4671F7E@.microsoft.com...[vbcol=seagreen]
> Thank you for the 3 quick replies, confirming my feelings. Does anyone
> have
> any 'Best Practise' recommendations or is it best to suck it and see?
> Kev
>
> --
> Network SI (UK) Ltd
>
> "Keith Kratochvil" wrote:
Parallelism query
I have a sql 2000 server with 8 processors, server settings are as
default. I read on technet that it is good practise to remove the
highest no. processors from being used for parallelism, corresponding
to the no. of NICs in the server. One of our 3rd party developers has
recommended only allowing one processor to be used as there is a
performance hit by the server working out which processor to use. Does
anyone have a definitive answer to this? I suspect he's wrong but I'd
like some hard evidence if possible, thanks.
KevHi Kev,
Requirement for multi processors/Degree of parallelism depends upon the kind
of transaction thats been executed on the server.
If your nature of query includes more of insert, delete and update statments
(doesn't include heavy complicated queries), then query optimizer is wasting
its time evaluating each query to see if it can take advantage of
parallelism.
On the other hand, if the nature of queries include complex joins,
correlated subqueries, which takes maximum amount of time to execute the
query, then it makes sense to have DOP > 1.
You can read more about this at
http://www.sql-server-performance.c...on_settings.asp
- - - - - - - - -
Thanks
Yogish
"Network SI (UK) Ltd" wrote:
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>|||Your third party developer doesn't know what he is talking about. There is
overhead when you use query parallelism (of course) but that doesn't mean
you shouldn't use it. 2 processors working at 90% of their capacity still
return the results quicker than 1 processor working at 100%. Depending on
how your server is used, it is usually be a good idea to limit the maximum
number of processors that can be used per query, so that one query doesn't
block all the processors. What the ideal limit is, is something you have to
experiment with, depending on the number of large select queries vs.
insert/update/inserts and the performance you want of them respectively. For
example, if performance of updates is of the highest importance, and
performance of reporting on the server is of less importance, you would set
the maximum number of processors for parallelism to 1. On the other side of
the scale is something like a staging/processing server for a datawarehouse,
where there's mostly only one process running at a time. In that case you
set the maximum number of processors for parallelism to the number of
physical processors you have.
I don't completely agree with the technet recommendation. Multiple
connections can share one NIC, and processor usage and network traffic are
usually somewhat correlated, but it is by no means straightforward.
SELECT * FROM multi_million_row_table
will cause a lot of network traffic, but not a lot of processor activity,
where
SELECT * FROM multi_million_row_table WHERE unindexed_column = <some value>
will cause less network traffic, but more processor activity.
Jacco Schalkwijk
SQL Server MVP
"Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>|||Following the logic of the 3rd party developer why not just scrap the big
iron and by a cheap server box?
Try a few configurations and use whichever works best for you. I suspect
that you should be able to enable 6,7, or even all 8 processors. I assume
that you are talking about 8 physical processors (not 4 physical with
hyperthreading enabled).
Keith
"Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>|||Thank you for the 3 quick replies, confirming my feelings. Does anyone have
any 'Best Practise' recommendations or is it best to suck it and see?
Kev
Network SI (UK) Ltd
"Keith Kratochvil" wrote:
> Following the logic of the 3rd party developer why not just scrap the big
> iron and by a cheap server box?
> Try a few configurations and use whichever works best for you. I suspect
> that you should be able to enable 6,7, or even all 8 processors. I assume
> that you are talking about 8 physical processors (not 4 physical with
> hyperthreading enabled).
> --
> Keith
>
> "Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in messa
ge
> news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
>
>|||Best thing would be to experiment and get some baseline. Get the a few of
the largest queries you have and run them with MAXDOP(1) to MAXDOP(8) (so
only those query are limited in the number of processors), and see what the
execution times are. It's pretty easy to create a script and run the whole
thing at a quiet time over the weekend or so
Jacco Schalkwijk
SQL Server MVP
"Network SI (UK) Ltd" <NetworkSIUKLtd@.discussions.microsoft.com> wrote in
message news:36784A55-E20F-4E2B-AE6B-BF38C4671F7E@.microsoft.com...[vbcol=seagreen]
> Thank you for the 3 quick replies, confirming my feelings. Does anyone
> have
> any 'Best Practise' recommendations or is it best to suck it and see?
> Kev
>
> --
> Network SI (UK) Ltd
>
> "Keith Kratochvil" wrote:
>sql
Parallelism query
I have a sql 2000 server with 8 processors, server settings are as
default. I read on Technet that it is good practise to remove the
highest no. processors from being used for parallelism, corresponding
to the no. of NICs in the server. One of our 3rd party developers has
recommended only allowing one processor to be used as there is a
performance hit by the server working out which processor to use. Does
anyone have a definitive answer to this? I suspect he's wrong but I'd
like some hard evidence if possible, thanks.
KevHi Kev,
Requirement for multi processors/Degree of parallelism depends upon the kind
of transaction thats been executed on the server.
If your nature of query includes more of insert, delete and update statments
(doesn't include heavy complicated queries), then query optimizer is wasting
its time evaluating each query to see if it can take advantage of
parallelism.
On the other hand, if the nature of queries include complex joins,
correlated subqueries, which takes maximum amount of time to execute the
query, then it makes sense to have DOP > 1.
You can read more about this at
http://www.sql-server-performance.com/sql_server_configuration_settings.asp
--
- - - - - - - - -
Thanks
Yogish
"Network SI (UK) Ltd" wrote:
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on Technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>|||Your third party developer doesn't know what he is talking about. There is
overhead when you use query parallelism (of course) but that doesn't mean
you shouldn't use it. 2 processors working at 90% of their capacity still
return the results quicker than 1 processor working at 100%. Depending on
how your server is used, it is usually be a good idea to limit the maximum
number of processors that can be used per query, so that one query doesn't
block all the processors. What the ideal limit is, is something you have to
experiment with, depending on the number of large select queries vs.
insert/update/inserts and the performance you want of them respectively. For
example, if performance of updates is of the highest importance, and
performance of reporting on the server is of less importance, you would set
the maximum number of processors for parallelism to 1. On the other side of
the scale is something like a staging/processing server for a datawarehouse,
where there's mostly only one process running at a time. In that case you
set the maximum number of processors for parallelism to the number of
physical processors you have.
I don't completely agree with the Technet recommendation. Multiple
connections can share one NIC, and processor usage and network traffic are
usually somewhat correlated, but it is by no means straightforward.
SELECT * FROM multi_million_row_table
will cause a lot of network traffic, but not a lot of processor activity,
where
SELECT * FROM multi_million_row_table WHERE unindexed_column = <some value>
will cause less network traffic, but more processor activity.
--
Jacco Schalkwijk
SQL Server MVP
"Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on Technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>|||Following the logic of the 3rd party developer why not just scrap the big
iron and by a cheap server box?
Try a few configurations and use whichever works best for you. I suspect
that you should be able to enable 6,7, or even all 8 processors. I assume
that you are talking about 8 physical processors (not 4 physical with
hyperthreading enabled).
--
Keith
"Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
> Hi,
>
> I have a sql 2000 server with 8 processors, server settings are as
> default. I read on Technet that it is good practise to remove the
> highest no. processors from being used for parallelism, corresponding
> to the no. of NICs in the server. One of our 3rd party developers has
> recommended only allowing one processor to be used as there is a
> performance hit by the server working out which processor to use. Does
> anyone have a definitive answer to this? I suspect he's wrong but I'd
> like some hard evidence if possible, thanks.
> Kev
>|||Thank you for the 3 quick replies, confirming my feelings. Does anyone have
any 'Best Practise' recommendations or is it best to suck it and see?
Kev
Network SI (UK) Ltd
"Keith Kratochvil" wrote:
> Following the logic of the 3rd party developer why not just scrap the big
> iron and by a cheap server box?
> Try a few configurations and use whichever works best for you. I suspect
> that you should be able to enable 6,7, or even all 8 processors. I assume
> that you are talking about 8 physical processors (not 4 physical with
> hyperthreading enabled).
> --
> Keith
>
> "Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in message
> news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
> > Hi,
> >
> >
> > I have a sql 2000 server with 8 processors, server settings are as
> > default. I read on Technet that it is good practise to remove the
> > highest no. processors from being used for parallelism, corresponding
> > to the no. of NICs in the server. One of our 3rd party developers has
> > recommended only allowing one processor to be used as there is a
> > performance hit by the server working out which processor to use. Does
> > anyone have a definitive answer to this? I suspect he's wrong but I'd
> > like some hard evidence if possible, thanks.
> >
> > Kev
> >
>
>|||Best thing would be to experiment and get some baseline. Get the a few of
the largest queries you have and run them with MAXDOP(1) to MAXDOP(8) (so
only those query are limited in the number of processors), and see what the
execution times are. It's pretty easy to create a script and run the whole
thing at a quiet time over the weekend or so
--
Jacco Schalkwijk
SQL Server MVP
"Network SI (UK) Ltd" <NetworkSIUKLtd@.discussions.microsoft.com> wrote in
message news:36784A55-E20F-4E2B-AE6B-BF38C4671F7E@.microsoft.com...
> Thank you for the 3 quick replies, confirming my feelings. Does anyone
> have
> any 'Best Practise' recommendations or is it best to suck it and see?
> Kev
>
> --
> Network SI (UK) Ltd
>
> "Keith Kratochvil" wrote:
>> Following the logic of the 3rd party developer why not just scrap the big
>> iron and by a cheap server box?
>> Try a few configurations and use whichever works best for you. I suspect
>> that you should be able to enable 6,7, or even all 8 processors. I
>> assume
>> that you are talking about 8 physical processors (not 4 physical with
>> hyperthreading enabled).
>> --
>> Keith
>>
>> "Network SI (UK) Ltd" <Kev Smart@.discussions.microsoft.com> wrote in
>> message
>> news:575D585F-2F48-4761-9479-1328DFE31E73@.microsoft.com...
>> > Hi,
>> >
>> >
>> > I have a sql 2000 server with 8 processors, server settings are as
>> > default. I read on Technet that it is good practise to remove the
>> > highest no. processors from being used for parallelism, corresponding
>> > to the no. of NICs in the server. One of our 3rd party developers has
>> > recommended only allowing one processor to be used as there is a
>> > performance hit by the server working out which processor to use. Does
>> > anyone have a definitive answer to this? I suspect he's wrong but I'd
>> > like some hard evidence if possible, thanks.
>> >
>> > Kev
>> >
>>
Parallelism problem?
My environment configuration is:
* 4 processor Xeon 2000 Intell Machine with hyperthreading on (OS sees 8
virtual processors) with 4GB memory
* Win 2K advanced
* SQL 2K Enterprise (sp3a)
This is the problem I experience. Consider this query on a table
(StatisticsConsultation) containing 1 mln records.
SELECT COUNT(*) FROM Clinic
join StatisticsConsultation on StatisticsConsultation.ClinicId = Clinic.ClinicId
join vwDoctor D on StatisticsConsultation.DoctorId = D.DoctorId
join Specialty on StatisticsConsultation.SpecialtyId = Specialty.SpecialtyId
join vwPerson P on StatisticsConsultation.PersonId = P.PersonId where
Clinic.RegionId = 345
the result of the query is the number about 800.000.
When the server is allocated only for that query it takes 4 seconds
(parallelism used)
When there is a background process which constantly uses only 1 processor
out of 8
(other resources are not highly utilised) the time rises up to 25 seconds.
1 .When I specify MAXDOP 1 option the query takes 7 seconds with the
backgroud process.
Can anyone explain me why this happens? Is it parallelism bag?
2. The above query when revriten
SELECT COUNT(*) FROM Clinic
join StatisticsConsultation on StatisticsConsultation.ClinicId = Clinic.ClinicId where Clinic.RegionId = 345
takes only 1 sec in comparison to 4 seconds. Why SQL Server doesn't optimize
it correctly?
Thank you in advance,
Regards,
Tomaszparallelism is a very operation to optimize for all cases.
this is one area where the SQL Server default setting
needs to be investigated.
I would test the query with MAXDOP 1, 2 & 4
most definitely, not allow use of more than the physical
processors.
I think you will find 1 or 2 is preferred when taking into
account overall response times for multiple users, and 4
for off hours maintainence
the last query is different, the extra joins could affect
row count
>--Original Message--
>Hi All,
>My environment configuration is:
>* 4 processor Xeon 2000 Intell Machine with
hyperthreading on (OS sees 8
>virtual processors) with 4GB memory
>* Win 2K advanced
>* SQL 2K Enterprise (sp3a)
>This is the problem I experience. Consider this query on
a table
>(StatisticsConsultation) containing 1 mln records.
>SELECT COUNT(*) FROM Clinic
> join StatisticsConsultation on
StatisticsConsultation.ClinicId =>Clinic.ClinicId
> join vwDoctor D on StatisticsConsultation.DoctorId =D.DoctorId
> join Specialty on StatisticsConsultation.SpecialtyId =>Specialty.SpecialtyId
> join vwPerson P on StatisticsConsultation.PersonId =P.PersonId where
>Clinic.RegionId = 345
>the result of the query is the number about 800.000.
>When the server is allocated only for that query it takes
4 seconds
>(parallelism used)
>When there is a background process which constantly uses
only 1 processor
>out of 8
>(other resources are not highly utilised) the time rises
up to 25 seconds.
>1 .When I specify MAXDOP 1 option the query takes 7
seconds with the
>backgroud process.
>Can anyone explain me why this happens? Is it parallelism
bag?
>2. The above query when revriten
>SELECT COUNT(*) FROM Clinic
> join StatisticsConsultation on
StatisticsConsultation.ClinicId =>Clinic.ClinicId where Clinic.RegionId = 345
>takes only 1 sec in comparison to 4 seconds. Why SQL
Server doesn't optimize
>it correctly?
>Thank you in advance,
>Regards,
>Tomasz
>
>.
>
parallelism on the fly
I want him to simplify the sp or have his project's DBA do it, and I even offered to take a hack but... you know.It can be done at the query level. I think you add
select *
from pubs..authors
option (maxdop 1)
Standard qualifications apply of test with/without the query hint every once in a while to see if the data distribution now favors the parallel query.|||thank you.
Parallelism in SSIS
Hi,
I would just like to confirm something with you guys...
Am I correct in saying that you dont need multiple connections to the same DB in a SSIS package in order to achieve parallel processing across multiple SQL tasks. In other words, I have 2 SQL tasks executing different stored procedures on the same DB that I want to run in parallel. They should be able to share one connection and still process in parallel, correct?
With that in mind, would the processing be faster if they each had their own connection?
Thanks in advance.
GBez wrote:
Hi,
I would just like to confirm something with you guys...
Am I correct in saying that you dont need multiple connections to the same DB in a SSIS package in order to achieve parallel processing across multiple SQL tasks. In other words, I have 2 SQL tasks executing different stored procedures on the same DB that I want to run in parallel. They should be able to share one connection and still process in parallel, correct?
They can share a connection manager but they still maintain seperate connections to the database. This is a good thing by the way.
GBez wrote:
With that in mind, would the processing be faster if they each had their own connection?
No. it wouldn't make any difference.
-Jamie
Parallelism and performance
We have a stored procedure that runs slow when the execution plan uses
parallelism vs. if does not.
My Question is when is it helpful to have parallelism and when not. Also is
it advisable to configure the sql server to not use parallelism at all.
Thanks
RahulSometimes SQL Server just creates parallel plans which do not perform well, although this seems to
be less and less of an issue with each release (and service pack). You can disable parallelism by:
MAXDOP 1 optimizer hint in the query
sp_configure and set "max degree of parallelism" to 1, will affect all queries
The "cost threshold for parallelism" affects the threshold for when parallel plans are considered
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Rahul" <reach_aggarwal@.hotmail.com> wrote in message news:e0QcAwyOHHA.1248@.TK2MSFTNGP02.phx.gbl...
> Hi,
> We have a stored procedure that runs slow when the execution plan uses parallelism vs. if does
> not.
> My Question is when is it helpful to have parallelism and when not. Also is it advisable to
> configure the sql server to not use parallelism at all.
> Thanks
> Rahul
>|||On Thu, 18 Jan 2007 19:18:26 +0100, "Tibor Karaszi"
<tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote:
>Sometimes SQL Server just creates parallel plans which do not perform well, although this seems to
>be less and less of an issue with each release (and service pack). You can disable parallelism by:
>MAXDOP 1 optimizer hint in the query
>sp_configure and set "max degree of parallelism" to 1, will affect all queries
>The "cost threshold for parallelism" affects the threshold for when parallel plans are considered
Hey Tibor, I had 21 copies of my SPID yesterday on a select query, on
a box with four processors.
I think that set a new personal best for me!
J.|||Sounds like a query that needs optimization:).
--
Andrew J. Kelly SQL MVP
"JXStern" <JXSternChangeX2R@.gte.net> wrote in message
news:ovi0r2tt33p1do0ialubbtbn5ujlfua75a@.4ax.com...
> On Thu, 18 Jan 2007 19:18:26 +0100, "Tibor Karaszi"
> <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote:
>>Sometimes SQL Server just creates parallel plans which do not perform
>>well, although this seems to
>>be less and less of an issue with each release (and service pack). You can
>>disable parallelism by:
>>MAXDOP 1 optimizer hint in the query
>>sp_configure and set "max degree of parallelism" to 1, will affect all
>>queries
>>The "cost threshold for parallelism" affects the threshold for when
>>parallel plans are considered
> Hey Tibor, I had 21 copies of my SPID yesterday on a select query, on
> a box with four processors.
> I think that set a new personal best for me!
> J.
>|||On Fri, 19 Jan 2007 09:50:24 -0500, "Andrew J. Kelly"
<sqlmvpnooospam@.shadhawk.com> wrote:
>Sounds like a query that needs optimization:).
There must have been at least 21 rows to check!
J.sql
Parallelism and performance
We have a stored procedure that runs slow when the execution plan uses
parallelism vs. if does not.
My Question is when is it helpful to have parallelism and when not. Also is
it advisable to configure the sql server to not use parallelism at all.
Thanks
Rahul
On Thu, 18 Jan 2007 19:18:26 +0100, "Tibor Karaszi"
<tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote:
>Sometimes SQL Server just creates parallel plans which do not perform well, although this seems to
>be less and less of an issue with each release (and service pack). You can disable parallelism by:
>MAXDOP 1 optimizer hint in the query
>sp_configure and set "max degree of parallelism" to 1, will affect all queries
>The "cost threshold for parallelism" affects the threshold for when parallel plans are considered
Hey Tibor, I had 21 copies of my SPID yesterday on a select query, on
a box with four processors.
I think that set a new personal best for me!
J.
|||Sounds like a query that needs optimization
Andrew J. Kelly SQL MVP
"JXStern" <JXSternChangeX2R@.gte.net> wrote in message
news:ovi0r2tt33p1do0ialubbtbn5ujlfua75a@.4ax.com...
> On Thu, 18 Jan 2007 19:18:26 +0100, "Tibor Karaszi"
> <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote:
>
> Hey Tibor, I had 21 copies of my SPID yesterday on a select query, on
> a box with four processors.
> I think that set a new personal best for me!
> J.
>
|||On Fri, 19 Jan 2007 09:50:24 -0500, "Andrew J. Kelly"
<sqlmvpnooospam@.shadhawk.com> wrote:
>Sounds like a query that needs optimization
There must have been at least 21 rows to check!
J.
Parallelism and performance
We have a stored procedure that runs slow when the execution plan uses
parallelism vs. if does not.
My Question is when is it helpful to have parallelism and when not. Also is
it advisable to configure the sql server to not use parallelism at all.
Thanks
RahulSometimes SQL Server just creates parallel plans which do not perform well,
although this seems to
be less and less of an issue with each release (and service pack). You can d
isable parallelism by:
MAXDOP 1 optimizer hint in the query
sp_configure and set "max degree of parallelism" to 1, will affect all queri
es
The "cost threshold for parallelism" affects the threshold for when parallel
plans are considered
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Rahul" <reach_aggarwal@.hotmail.com> wrote in message news:e0QcAwyOHHA.1248@.TK2MSFTNGP02.phx
.gbl...
> Hi,
> We have a stored procedure that runs slow when the execution plan uses par
allelism vs. if does
> not.
> My Question is when is it helpful to have parallelism and when not. Also i
s it advisable to
> configure the sql server to not use parallelism at all.
> Thanks
> Rahul
>|||On Thu, 18 Jan 2007 19:18:26 +0100, "Tibor Karaszi"
<tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote:
>Sometimes SQL Server just creates parallel plans which do not perform well,
although this seems to
>be less and less of an issue with each release (and service pack). You can
disable parallelism by:
>MAXDOP 1 optimizer hint in the query
>sp_configure and set "max degree of parallelism" to 1, will affect all quer
ies
>The "cost threshold for parallelism" affects the threshold for when parallel plans
are considered
Hey Tibor, I had 21 copies of my SPID yesterday on a select query, on
a box with four processors.
I think that set a new personal best for me!
J.|||Sounds like a query that needs optimization
Andrew J. Kelly SQL MVP
"JXStern" <JXSternChangeX2R@.gte.net> wrote in message
news:ovi0r2tt33p1do0ialubbtbn5ujlfua75a@.
4ax.com...
> On Thu, 18 Jan 2007 19:18:26 +0100, "Tibor Karaszi"
> <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote:
>
> Hey Tibor, I had 21 copies of my SPID yesterday on a select query, on
> a box with four processors.
> I think that set a new personal best for me!
> J.
>|||On Fri, 19 Jan 2007 09:50:24 -0500, "Andrew J. Kelly"
<sqlmvpnooospam@.shadhawk.com> wrote:
>Sounds like a query that needs optimization
There must have been at least 21 rows to check!
J.
Parallelism - Standard vs Enterprise Edition
available only in the Enterprise Edition of SQL 2005. Can anyone confirm den
y
that and support with documentation?
Standard fits our needs all other features, but I don't want to lose
Intraquery Parallelism.
TerryIntraquery parallelism is available in all editions which supports > 1 proce
ssor. There are only
certain type of operations going over several processors that only EE can do
. See
http://www.microsoft.com/sql/prodin...e-features.mspx
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Terry" <Terry@.discussions.microsoft.com> wrote in message
news:0081E754-B590-43F2-B571-06526EF3C270@.microsoft.com...
> We were told by a Microsoft representative that Intraquery Parallelism is
> available only in the Enterprise Edition of SQL 2005. Can anyone confirm d
eny
> that and support with documentation?
> Standard fits our needs all other features, but I don't want to lose
> Intraquery Parallelism.
> Terry
Parallelism - Standard vs Enterprise Edition
available only in the Enterprise Edition of SQL 2005. Can anyone confirm deny
that and support with documentation?
Standard fits our needs all other features, but I don't want to lose
Intraquery Parallelism.
TerryIntraquery parallelism is available in all editions which supports > 1 processor. There are only
certain type of operations going over several processors that only EE can do. See
http://www.microsoft.com/sql/prodinfo/features/compare-features.mspx
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Terry" <Terry@.discussions.microsoft.com> wrote in message
news:0081E754-B590-43F2-B571-06526EF3C270@.microsoft.com...
> We were told by a Microsoft representative that Intraquery Parallelism is
> available only in the Enterprise Edition of SQL 2005. Can anyone confirm deny
> that and support with documentation?
> Standard fits our needs all other features, but I don't want to lose
> Intraquery Parallelism.
> Terry
Parallel Processing of Partition
Guys,
I would like to thanks Elizabeth for a great document. Appreciate it.
Under " Maximize parallelism during processing", I see the following bench mark.
# of Processors
# of Partitions to be processed in parallel
4
2 – 4
8
4 – 8
16
6 – 16
In our scenario, we have a huge dataset which means processing about 20 partitions in parallel. The box we have is a beefy box DL 585 4dual core CPU with 32 GB memory and we are using the 64 bit architecture.
However when monitoring the trace I see the following:-
Based on the above the thread for processing the fact kicks off at 8:05am. However the actual sql to the underlying database does not get kicked off until 9:38am.
Does this mean the same thing that it is waiting for CPUs? However when I look at the perfMon stats on the Server side, the CPU usage is pretty vanilla and I do not understand how to correlate this.
Any suggestions is much appreciated.
Rgds
Hari
Running processing of 20 partitions in parallel on 4 processor box is bit of the overkill. The fact you have lots of data to process doesnt mean you should start processing many partitions in parallel.
As Perf Guide indicates, number of processors should determine number of parallel operations. If you try to start too many processing operations, you will get into behavior you observe. Say you told Analysis Server to process 20 partitions in parallel but there not enought resources. In this case operations running in parallel are going to start fighting for resoures and some of the become blocked. Analysis Server also starts many operations within sigle partition processing job in parallel. what you see is that Execute SQL and Read data started in parallel, but Write data didnt start till some data became avaliable.
You should also take a look at optimizing your SQL server database for the type of queries Analysis Server sends to speed up sending data to it.
Edward.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
|||
Ahh..thanks Edward.
Regarding this "The fact you have lots of data to process doesnt mean you should start processing many partitions in parallel."
At this point, we are doing a full process on the database though it is partitioned.So by default, it first starts the threads for the cubes in parallel and then spawns new threads for measuregroups and finally partitions in parallels and this is done by default. Any ways I can control this.
We are using the biggest possible box that is available now.
Quadra-core CPUs do not come out until June of this year.
Like you say, we are also working with the DB2 team to optimize the SQL by building indexes on the partition columns.
Just
|||Hi Edward,
I am the Windows Server SA who supports Hari's machine. We had a similar issue on a 32-bit Windows 2003 OLAP machine that was acting the same way when building cubes. Analysis Services was running out of memory but we weren't seeing any memory or processor spikes. I opened a case and the engineer explained this was due to the fact that there was a 2 GB limitation, regardless of how much RAM the server has. We tried adding the /3GB and /USERVA switches. Neither worked and the solution to get past this was to upgrade to 64-bit.
How much memory is allocated to an application in the 64-bit version of Windows 2003? Is there a way to tell how much memory it's utilizing?
In addition the OS is seeing all 32 GB of RAM, but I can't tell if it's utilizing all 32 GB. Are the /PAE, /USERVA, and/or /AWE switches relevant to Win2K3 64-bit? Do I need to add anything to the boot.ini to ensure applications are able to use all available RAM? Do you have any suggestions for optimizing performance in SQL and or Analysis Services?
Thanks - Gib
|||On 64bit machine there is no worry about single process being able to access as much memory as your machine can give to it. No modifying flags or setting special options for have to access more memory.
The amount of memory your Analysis Server will use during processing is depenedent on the size of the objects you will be processing and fact whether you will be processing them in parallel.
I'd say if you moved to 64bit machine with 32Gb of Ram, you should be able to handle quite a few things in parallel, so just go ahead an run your processing and see how high memory utilization goes.
Edward.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
Thanks Edward. I'm going to shift my question to Hari's problem. Specifically in relation to your teply yesterday.
"Running processing of 20 partitions in parallel on 4 processor box is bit of the overkill. The fact you have lots of data to process doesnt mean you should start processing many partitions in parallel.
As Perf Guide indicates, number of processors should determine number of parallel operations. If you try to start too many processing operations, you will get into behavior you observe. Say you told Analysis Server to process 20 partitions in parallel but there not enought resources. In this case operations running in parallel are going to start fighting for resoures and some of the become blocked. Analysis Server also starts many operations within sigle partition processing job in parallel. what you see is that Execute SQL and Read data started in parallel, but Write data didnt start till some data became avaliable.
You should also take a look at optimizing your SQL server database for the type of queries Analysis Server sends to speed up sending data to it."
Hari added a chart that has a Processor to Parallel Partition correlation.
# of Processors
# of Partitions to be processed in parallel
4
2 – 4
8
4 – 8
16
6 – 16
We are running on an HP DL585 it has 4 Dual Core AMD Processors. That having been said can OLAP utilize them as 8 Processors or will it only see them as 4?
The other thing you had mentioned is 20 partitions is overkill. Does that mean this type of lag is to be expected? Is there any kind of tweaking that can be done either on the OS or in SQL to improve performance?
As it stands now, Hari isn't seeing any CPU or Memory spikes when the delay is occurring. If operations are blocked and fighting for resources will we see 100 % Memory and CPU utilization?
Thanks - Gib
|||Yes, you should count a single core as a processor for the purpose of the chart you mention. DL 585 is great macine and you should count as you have 8 processors.
Therefore the per guide recommends you process 4 to 8 partitions in parallel.
The bottleneck might not be CPU or memory. It is also your relational database. You should take a look at your relational database and see how hard it is working to deliver data to Analysis Server. You might want to run database tuninig advisor to build more indexes supporting queries sent to it.
Edward.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
Edward, Do you know if tuning the relational database will enable Hari to process 20 partitions at the same time? Do you know of anyone who is doing this on a Quad Dual Core server?
According to the chart it doesn't look like this possible, even with 16 processors. I'm wondering if there is any kind of tweaking that can be done so that it's possible.
Thanks - Gib
|||That is not going to help. Number of partitions you process in parallel depends on how many operations in parallel your hardware can perform. If you tune your system, optimize your relational database, and you still not satisfied with processing performance, you might start looking at getting newer machines with higher number of processors.
Edward.
--
This posting is provided "AS IS" with no warranties, and confers no rights.