Collecting statistics

Moderator: NorbertKrupa

Post Reply
Timbo
Intermediate
Intermediate
Posts: 53
Joined: Thu Jun 21, 2012 11:05 am
Location: London, UK

Collecting statistics

Post by Timbo » Mon Jun 25, 2012 9:19 am

Hi, A couple of questions around running the analyze_statistics command.
1. Can mulitiple analyze_statistics commands be run in parallel?
2. How much of an impact does this cause, is the table still usable for queries?

I know this is very dependant on the hardware, but just an idea of "best practice" would be good.

Thanks
Tim

User avatar
JimKnicely
Site Admin
Site Admin
Posts: 1825
Joined: Sat Jan 21, 2012 4:58 am
Contact:

Re: Collecting statistics

Post by JimKnicely » Mon Jun 25, 2012 4:51 pm

Hi Timbo,
1. Can mulitiple analyze_statistics commands be run in parallel?
On the same table? This can be done, but I don't think it speeds up the process. If you call analyze_statistics on the same table from multiple sessions or from different nodes I think that each execution will compute a complete set of statistics. The call that finishes last will update the statistics_updated_timestamp column in the projection_columns table. This seems to be the case from my testing.

You can certainly run analysis on different tables at the same time. You can run these commands from different nodes or on the same node from multiple sessions.
2. How much of an impact does this cause, is the table still usable for queries?
On page 282 of the Vertica Version 6 Admin. Guide there is a section called "Best Practices for Statistics Collection". Have you checked it out? It talks about the performance impact and when statistics should be taken.

If you have really HUGE tables you can always just run stats on individual columns (i.e. on the ones in your query predicates).

BTW, we do not see any major impact of performance when we run the analyze_statistics command on our larger tables.
Jim Knicely

Image

Note: I work for Vertica. My views, opinions, and thoughts expressed here do not represent those of my employer.

Post Reply

Return to “Vertica Performance Tuning”