On 22.10.2013 23:50, sparikh wrote: > Sorry, it was typo from my side. I meant strace only. OK. > > I will try to request both perf and strace to be installed. But I am > not quite sure as the VMs are managed by third party. Will keep you > posted... What do you mean by VM? Is this a virtualized environment or bare hardware? > > The main thing puzzling to me is Explain Plan with Analyze takes > couple of secs to execute the operation but in reality it runs for > more than 20 mins. So, now I'm getting confused. Can you please provide timings for each case. I.e. how long it takes to execute 1) plain query 2) explain query 3) explain analyze query Execute each of those a couple of times, and let us know about significant variations. It should always be EXPLAIN ANALYZE >= query >= EXPLAIN If you're reporting you see "EXPLAIN ANALYZE < query" then I find that really strange. Tomas -- Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-performance