Redrock Postgres Documentation
Home Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage
Edit page

Does creating a database trigger checkpoints?

Description

When we create a database, will checkpoints be triggered to flush dirty data from buffers to storage devices?

Answer

Creating a database does not trigger checkpoints.

When creating a database, Redrock Postgres accesses the data page of the template database through shared buffer and copies the data to the data page of the new database. WAL logs are recorded for each data page. Therefore, during creating a database, a checkpoint does not need to be triggered to flush dirty data in the buffer to the storage device.