GithubHelp home page GithubHelp logo

hedius / clickhouse-backup Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 259 KB

A simple python wrapper around clickhouse to use the BACKUP command for creating backups of your database.

License: GNU General Public License v3.0

Python 98.11% Makefile 1.89%

clickhouse-backup's Introduction

Hi there πŸ‘‹

Metrics


clickhouse-backup's People

Contributors

hedius avatar

Stargazers

 avatar  avatar

Watchers

 avatar

clickhouse-backup's Issues

Notes

Backup jobs return the ID:

BACKUP TABLE default.test TO Disk('backups', '2.zip')

Query id: 35f1e28b-1d8c-4498-aba3-ff7e59771ad3

β”Œβ”€id───────────────────────────────────┬─status─────────┐
β”‚ 17a599e3-45d0-45c2-b6b6-f4e4cb8ae8d7 β”‚ BACKUP_CREATED β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Daraus folgt: SELECT * FROM system.backups WHERE id = '17a599e3-45d0-45c2-b6b6-f4e4cb8ae8d7';

id name status error start_time end_time num_files total_size num_entries uncompressed_size compressed_size files_read bytes_read ProfileEvents
17a599e3-45d0-45c2-b6b6-f4e4cb8ae8d7 Disk('backups', '2.zip') BACKUP_CREATED 2023-12-27 22:05:27 2023-12-27 22:05:27 6 333 4 1141 1554 0 0 {'Query': '1', 'QueriesWithSubqueries': '1', 'FileOpen': '6', 'ReadBufferFromFileDescriptorRead': '4', 'ReadBufferFromFileDescriptorReadBytes': '402', 'WriteBufferFromFileDescriptorWrite': '2', 'WriteBufferFromFileDescriptorWriteBytes': '1590', 'OpenedFileCacheMisses': '4', 'IOBufferAllocs': '13', 'IOBufferAllocBytes': '7406531', 'CreatedReadBufferOrdinary': '4', 'DiskReadElapsedMicroseconds': '8', 'DiskWriteElapsedMicroseconds': '15', 'ContextLock': '16', 'RWLockAcquiredReadLocks': '2', 'ThreadPoolReaderPageCacheHit': '4', 'ThreadPoolReaderPageCacheHitBytes': '144', 'ThreadPoolReaderPageCacheHitElapsedMicroseconds': '7', 'SynchronousReadWaitMicroseconds': '10', 'BackupsOpenedForWrite': '1', 'BackupWriteMetadataMicroseconds': '55', 'BackupEntriesCollectorMicroseconds': '346', 'BackupEntriesCollectorForTablesDataMicroseconds': '188', 'BackupEntriesCollectorRunPostTasksMicroseconds': '5', 'LogTrace': '23', 'LogDebug': '1', 'LogInfo': '3'}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.