github Altinity/clickhouse-backup v0.6.2

latest releases: v2.6.3, v2.6.2, v2.6.1...
3 years ago

IMPROVEMENTS
Added integration with clickhouse cli. Now backups can be managed via clickhouse-client
How it works:

  1. Run clickhouse-backup api
clickhouse-backup server
  1. Create backup_actions and backup_list tables
CREATE TABLE system.backup_actions (command String, start DateTime, finish DateTime, status String, error String) ENGINE=URL('http://127.0.0.1:7171/backup/actions', JSONEachRow)
CREATE TABLE system.backup_list (name String, created DateTime, size Int64, location String) ENGINE=URL('http://127.0.0.1:7171/backup/list', JSONEachRow)
  1. Manage backup via clickhouse queries
INSERT INTO system.backup_actions (command) VALUES ('create backup1')
INSERT INTO system.backup_actions (command) VALUES ('upload backup1')
SELECT * FROM system.backup_list
┌─name───────────┬─────────────created─┬──size─┬─location─┐
│ backup1        │ 2020-12-01 08:43:47 │     0 │ local    │
│ backup1.tar.gz │ 2020-12-01 08:43:54 │ 74249 │ remote   │
└────────────────┴─────────────────────┴───────┴──────────┘
SELECT * FROM system.backup_actions
┌─command────────┬───────────────start─┬──────────────finish─┬─status──┬─error─┐
│ create backup1 │ 2020-12-01 09:01:02 │ 2020-12-01 09:01:02 │ success │       │
│ upload backup1 │ 2020-12-01 09:01:05 │ 2020-12-01 09:01:05 │ success │       │
└────────────────┴─────────────────────┴─────────────────────┴─────────┴───────┘

Don't miss a new clickhouse-backup release

NewReleases is sending notifications on new releases.