От: Juraj Porada
Тема: slower with the time
Дата: ,
Msg-id: 3F013C85.2060202@pe-muc.de
(см: обсуждение, исходный текст)
Ответы: Re: slower with the time  (Shridhar Daithankar)
Список: pgsql-performance

Скрыть дерево обсуждения

slower with the time  (Juraj Porada, )
 Re: slower with the time  (Shridhar Daithankar, )
 Re: slower with the time  (Juraj Porada, )
  Re: slower with the time  (Shridhar Daithankar, )

I insert data every second in my table. Every minute I delete from the
table some row to keep max 10000 rows in the table.
At the beginning deletes consume about 20% CPU time. After 24 houts
every delete needs up tu 100% CPU time (updates too).
Vacuuming doesn't help.
After I restart postmaster, it works again very quick.
Any ideas?

Thanks,
Juraj

Delete query:

 DELETE FROM tbl
WHERE time_stamp >= 0.0 AND
 time_stamp < (SELECT max(time_stamp)
                         FROM (SELECT time_stamp
                                        FROM tbl ORDER BY time_stamp,
id_event_archive ASC LIMIT 222) AS t)

PK: id_event_archive
Index: time_stamp

Postgres version: 7.3.3.
OS: Solaris 2.8




В списке pgsql-performance по дате сообщения:

От: Tom Lane
Дата:
Сообщение: Re: excessive disk access during query
От: "Michael Mattox"
Дата:
Сообщение: Re: Version 7 question