Re: bgwriter and checkpoints
От | Cédric Villemain |
---|---|
Тема | Re: bgwriter and checkpoints |
Дата | |
Msg-id | CAF6yO=3Fvx2ZQP6+69zqv9VRLRDTW63bkFRAm5wRSVw2ikdmsQ@mail.gmail.com обсуждение исходный текст |
Ответ на | bgwriter and checkpoints (Simon Riggs <simon@2ndQuadrant.com>) |
Список | pgsql-hackers |
2011/8/12 Simon Riggs <simon@2ndquadrant.com>: > The bgwriter has been responsible for two main activities: incremental > page cleaning and checkpointing. > > We've worked out the code to smooth checkpointing, but that now means > we have periods where we do both page cleaning and checkpointing, and > other times when we do just page cleaning. That means the processing > loops are complex and that makes latch based processing more difficult > to introduce. > > Moreover, when we perform fsyncs at the end of checkpoint we stop > doing pagecleaning. > > I propose to introduce a new process dedicated to checkpointing, > leaving the bgwriter process to perform pagecleaning, if that is > requested. Note that on smaller systems the bgwriter process would not > even be required to exist, if page cleaning was not used. > > This will simplify the code, so that checkpoint happens fairly cleanly > - and can then be extended in other ways. The checkpointer would be > the important process from a shutdown perspective. > > It will also simplify the bgwriter, potentially allowing us to > consider that it performs other tasks, such as HOT vacuuming or hint > bit setting. Nothing added in first version, but this clears the way > to allow these things to be considered and prototyped. > > So the likelihood is this change will improve performance of itself in > large systems, but the main benefit is code simplicity which is > required for a range of potential futures. > > Are there objections to this work beginning? No objections. (+100 for doing that) -- Cédric Villemain +33 (0)6 20 30 22 52 http://2ndQuadrant.fr/ PostgreSQL: Support 24x7 - Développement, Expertise et Formation
В списке pgsql-hackers по дате отправления: