Ludwig,
> Anybody has a idea why it took that long to commit?
> My setup is a Pentium 4 with RAID 5. My version of
> postgresql is 7.2.2
Disk contention is also a very possible issue. I'd suggest trying the
same test when you are certain that no other disk activity is
happening. I've seen appalling wait times for random writes on some
RAID5 controllers.
Also, how about publishing the text of the function?
What controller are you using? How many dirves, of what type?
-Josh Berkus