> Filtering out with the pid showed that it was the file
> pgdata/global/pgstat.tmp
>> Filtering out with the pid showed that it was the file
>> pgdata/global/pgstat.tmp
>
> That's the statistics collector -- which makes sense, depending
> on your settings, it has to write stats for every operation done in the
> database.
>
This smells of anti-virus software to me (usually the cause of
problems with Postgres on windows).
Are you running any?
I had almost exactly the same problem on xp and 8.3 with pctools
antivirus. This was causing the statistics collector to use 100% of a
cpu core. You won't look back moving to Ubuntu - I haven't :-).
Best regards, Will T