
10 May
2009
10 May
'09
4:17 p.m.
On 10-05-2009 10:12:19 -0400, Mag Gam wrote:
I am running a query, similar to this:
SELECT distinct extract(day from time), extract (month from time) from T;
The query takes a long time because the table T has over 280 Million records. However I was curious to run an strace on the mserver5 process and I notced "nanosleep".
Is the process sleeping or waiting?
strace -p 25984 Process 25984 attached - interrupt to quit restart_syscall(<... resuming interrupted call ...>) = 0 nanosleep({5, 0}, {5, 0}) = 0 nanosleep({5, 0}, {5, 0}) = 0 nanosleep({5, 0}, {5, 0}) = 0
Those are various threads that just wait for a while before they look if they have to do something again.