Bug 249205 - databases/clickhouse: apply patch from #13859: MemoryTracking support
Summary: databases/clickhouse: apply patch from #13859: MemoryTracking support
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Ruslan Makhmatkhanov
URL:
Keywords: buildisok
Depends on:
Blocks:
 
Reported: 2020-09-09 08:03 UTC by Oleg Ginzburg
Modified: 2020-09-10 15:23 UTC (History)
2 users (show)

See Also:


Attachments
databases/clickhouse: apply patch from #13859: MemoryTracking support (7.63 KB, text/plain)
2020-09-09 08:03 UTC, Oleg Ginzburg
olevole: maintainer-approval+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oleg Ginzburg 2020-09-09 08:03:02 UTC
Created attachment 217832 [details]
databases/clickhouse: apply patch from #13859: MemoryTracking support

Clickhouse for FreeBSD updating no memory usage stats. In the case build without NDEBUG, allocator use 4KB chunk, those dont account when freeing and MemoryTracking metric grow up to ~6TB, after this clickhouse stop query processing with error "Memory limit (total) exceeded: would use 6.24 TiB" due skipping calc allocation < 4MB

Patch still not upstreamed, obtained from:

https://github.com/ClickHouse/ClickHouse/issues/13859 +
https://github.com/ClickHouse/ClickHouse/pull/13869

reported and tested by: Vyacheslav (via Clickhouse telegram)
Comment 1 Automation User 2020-09-09 19:26:02 UTC
Build info is available at https://gitlab.com/swills/freebsd-ports/pipelines/187728010
Comment 2 commit-hook freebsd_committer freebsd_triage 2020-09-10 15:21:55 UTC
A commit references this bug:

Author: rm
Date: Thu Sep 10 15:21:28 UTC 2020
New revision: 548207
URL: https://svnweb.freebsd.org/changeset/ports/548207

Log:
  databases/clickhouse: apply patch from #13859: MemoryTracking support

  Clickhouse for FreeBSD updating no memory usage stats. In the case build without NDEBUG,
  allocator use 4KB chunk, those dont account when freeing and MemoryTracking metric grow
  up to ~6TB, after this clickhouse stop query processing with error "Memory limit (total)
  exceeded: would use 6.24 TiB" due skipping calc allocation < 4MB

  Patch still not upstreamed, obtained from:
  https://github.com/ClickHouse/ClickHouse/issues/13859 +
  https://github.com/ClickHouse/ClickHouse/pull/13869

  reported and tested by: Vyacheslav (via Clickhouse telegram)

  PR:		249205
  Submitted by:	olevole@olevole.ru (maintainer)
  Obtained from:  clickhouse repository

Changes:
  head/databases/clickhouse/Makefile
  head/databases/clickhouse/files/patch-cmake_freebsd_default__libs.cmake
  head/databases/clickhouse/files/patch-src_Common_MemoryStatisticsOS.cpp
  head/databases/clickhouse/files/patch-src_Common_MemoryStatisticsOS.h
  head/databases/clickhouse/files/patch-src_Interpreters_AsynchronousMetrics.cpp
  head/databases/clickhouse/files/patch-src_Interpreters_AsynchronousMetrics.h
Comment 3 Ruslan Makhmatkhanov freebsd_committer freebsd_triage 2020-09-10 15:23:33 UTC
Committed, thank you!