Clickhouse backups #1226
-
|
Hi! I set up Plausible but I am having trouble backing up the Clickhouse database. I'm using https://github.com/AlexAkulov/clickhouse-backup for this since I couldn't find a better tool. So the question is.... how can I back up and restore the Clickhouse database used by Plausible? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 22 replies
-
|
Good question. Currently I still use full OS image based backups so it's not really an issue for me. I don't see a quick and easy way to solve this. Maybe switching from TinyLog to MergeTree would work even though TinyLog is a much more appropriate table engine for migrations. This would require some work on the clickhouse_ecto library and changing existing schema_migrations tables. |
Beta Was this translation helpful? Give feedback.
-
|
@ukutaht I appreciate your input on this and understand that Q4 2021 is the infrastructure quarter. I really like your idea of using DO's Managed POSTGRES solution. And a clickhouse backup option to object storage makes perfect sense. We are using that same strategy on another project (we send the objects to Amazon S3 rather than DO Spaces). When we established this system, DO Spaces was very new and limited. In the future, it might be helpful for others to share some metrics on production database sizes (POSTGRES, Clickhouse) for a given number of recorded events (assuming that is the right proxy for size). Currently we have only a dev Plausible server (and yes, all on one droplet), but with the upcoming release of city level geo tracking, we will spin up a self-hosted production server as well. |
Beta Was this translation helpful? Give feedback.
-
|
Hi all, has anything changed / become easier since I started this discussion a while ago? Is there an easy way to properly back up the data now? Thanks @ukutaht |
Beta Was this translation helpful? Give feedback.
Good question. Currently I still use full OS image based backups so it's not really an issue for me.
I don't see a quick and easy way to solve this. Maybe switching from TinyLog to MergeTree would work even though TinyLog is a much more appropriate table engine for migrations. This would require some work on the clickhouse_ecto library and changing existing schema_migrations tables.