How VictoriaLogs Stores Your Logs in a Columnar Layout

(victoriametrics.com)

28 points | by eatonphil 4 days ago ago

6 comments

  • a012 4 days ago

    So it’s the same spirit of Clickhouse, how does VictoriaLogs scale?

    • dengolius a day ago

      The answer to your question was deleted, so I'll post it again:

      Vertically on a single machine, the two are quite similar, both fan work out across all CPU cores. The different is on scaling out.

      ClickHouse scales by making you describe the cluster yourself. You decide how many shards to split the data into, how many copies (replicas) each shard keeps, which row goes to which shard. The copies are kept in sync by a consensus system ClickHouse Keeper. This is flexible but also more works on operators.

      VictoriaLogs takes the opposite bet. When logs come in, the inserter just spreads them across all storage nodes on its own, so there is no sharding key for you to design. When a query runs, the selector asks every storage node in parallel and merges the results. There is no consensus system at all. If you want high availability, you run 2 independent clusters and send your logs to both, rather than having the database copy data internally. So this is simpler and less learning curve. See more here https://victoriametrics.com/blog/victorialogs-architecture-b...

      • cassianoleal 25 minutes ago

        Sounds like the same architecture used by Victoria Metrics storage. I ran it for years on a previous platform and it was so incredibly easy to operate and troubleshoot, and the performance is unreal!

      • winrid 2 hours ago

        So basically if you have queries that are hard on the query planner, that constant fan out has higher CPU cost than the alternatives.

        • AlotOfReading an hour ago

          Taking a look at their LogQL language, I don't see anything that would be particularly hard on the planner. You can't get the fan-out that makes fully relational query planning so difficult with the kind of boolean filters they seem to use. Planning should mostly be a matter of sorting by column cardinality and query optimization so you aren't doing unnecessary operations.

    • func25 4 days ago

      Vertically on a single machine, the two are quite similar, both fan work out across all CPU cores.

      The different is on scaling out.

      ClickHouse scales by making you describe the cluster yourself. You decide how many shards to split the data into, how many copies (replicas) each shard keeps, which row goes to which shard. The copies are kept in sync by a consensus system ClickHouse Keeper. This is flexible but also more works on operators.

      VictoriaLogs takes the opposite bet. When logs come in, the inserter just spreads them across all storage nodes on its own, so there is no sharding key for you to design. When a query runs, the selector asks every storage node in parallel and merges the results. There is no consensus system at all. If you want high availability, you run 2 independent clusters and send your logs to both, rather than having the database copy data internally. So this is simpler and less learning curve. See more here https://victoriametrics.com/blog/victorialogs-architecture-b...