Giter Site home page Giter Site logo

clickhouse's Introduction

clickhouse-helmchart

this is a clickhouse helm chart configured in such a way that when there is only 20 percent free space remaining in the hot disc the data will move to cold disc

Steps for testing

  1. cd to the clickhouse-chart directory
  2. run the command helm install clickhouse-release .
  3. then we need to exec into the container you can also do it using the service defined with the helm chart but for the time being we can directly exec into the container using the command kubectl exec -it <Pod name> clickhouse-client
  4. Once you are into the container we need to make a table dz_test by following method : CREATE TABLE dz_test ( B Int64, T String, D Date ) ENGINE = MergeTree PARTITION BY D ORDER BY B SETTINGS storage_policy = 'hot_cold_policy'
  5. once the table is created we need to insert a large amount od data into it for that run the command : INSERT INTO dz_test SELECT number, number, '2023-01-01' FROM numbers(1000000000.) this will insert 1 billion rows in the table
  6. to check for the disc which is being used run SELECT disk_name, formatReadableSize(sum(bytes_on_disk)) AS total_size FROM system.parts WHERE table = 'dz_test' GROUP BY disk_name initially you will see only hot is being used but when you will run the query again after sometime you will notice that data is moved to the cold storage .

clickhouse's People

Contributors

swastik959 avatar

Watchers

 avatar

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.