Fenn Bailey <fenn.bailey@gmail.com> writes:
> I'm experiencing an issue where certain queries appear to
> non-deterministically "hang", with a CPU pinned at 100%.
> I say "hang", where really I've given up after ~12 hours execution. The
> exact same query can then be terminated and run in <90 seconds, with none
> of the underlying data changing.
But does the plan change?
> If anyone could explain this behaviour, or even how I might go about
> diagnosing, that would be wonderful.
"perf" or "oprofile" or local equivalent would help identify where the
looping is happening.
regards, tom lane