Re: BUG #8697: checkpoint cann't flush unlogged table's dirty page to disk.
От | Andres Freund |
---|---|
Тема | Re: BUG #8697: checkpoint cann't flush unlogged table's dirty page to disk. |
Дата | |
Msg-id | 20131224121135.GE26564@alap2.anarazel.de обсуждение исходный текст |
Ответ на | BUG #8697: checkpoint cann't flush unlogged table's dirty page to disk. (digoal@126.com) |
Список | pgsql-bugs |
Hi, On 2013-12-23 09:41:07 +0000, digoal@126.com wrote: > checkpoint cann't flush unlogged table's dirty page to disk. > digoal=# create table u(id int); > digoal=# update pg_class set relpersistence ='u' where relname='u'; > digoal=# insert into u select generate_series(1,100000); > digoal=# checkpoint; > digoal=# select * from pg_stat_file(pg_relation_filepath('u')), > pg_relation_filepath('u'); > size | access | modification | change > | creation | isdir | pg_relation_filepath > ---------+------------------------+------------------------+------------------------+----------+-------+---------------------- > 3629056 | 2013-12-23 17:36:54+08 | 2013-12-23 17:37:02+08 | 2013-12-23 > 17:37:02+08 | | f | base/16399/122891 > (1 row) > -- then change table u to normal table > digoal=# update pg_class set relpersistence ='p' where relname='u'; > digoal=# insert into u select generate_series(1,100000); > digoal=# checkpoint; > digoal=# select * from pg_stat_file(pg_relation_filepath('u')), > pg_relation_filepath('u'); > size | access | modification | change > | creation | isdir | pg_relation_filepath > ---------+------------------------+------------------------+------------------------+----------+-------+---------------------- > 7249920 | 2013-12-23 17:36:54+08 | 2013-12-23 17:37:29+08 | 2013-12-23 > 17:37:29+08 | | f | base/16399/122891 > (1 row) I am confused. It certainly isn't allowed to simply update random pg_catalog.* tables - it will frequently break stuff. Why are you expecting that to work? Or are you simply trying to prove some other point? Greetings, Andres Freund -- Andres Freund http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services
В списке pgsql-bugs по дате отправления: