From eea088d87fa3c01a5fed15ee439df6ff2fa53bca Mon Sep 17 00:00:00 2001 From: Aliaksandr Valialkin Date: Thu, 6 Jul 2023 17:05:59 -0700 Subject: [PATCH] docs/CHANGELOG.md: clarify description for https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4336 bugfix This is a follow-up for 5eb5df96e26bae3fbf771afbe9eee313c45ad25d --- docs/CHANGELOG.md | 2 +- lib/mergeset/table.go | 4 +++- lib/storage/partition.go | 4 +++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index d2d4e0b33..e2af91c60 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -61,7 +61,7 @@ Released at 2023-06-30 * BUGFIX: [vmalert](https://docs.victoriametrics.com/vmalert.html): properly interrupt retry attempts on vmalert shutdown. Before, vmalert could have waited for all retries to finish for shutdown. * BUGFIX: [vmbackupmanager](https://docs.victoriametrics.com/vmbackupmanager.html): fix an issue with `vmbackupmanager` not being able to restore data from a backup stored in GCS. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4420) for details. * BUGFIX: [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html): properly return error from [/api/v1/query](https://docs.victoriametrics.com/keyConcepts.html#instant-query) and [/api/v1/query_range](https://docs.victoriametrics.com/keyConcepts.html#range-query) at `vmselect` when the `-search.maxSamplesPerQuery` or `-search.maxSamplesPerSeries` [limit](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html#resource-usage-limits) is exceeded. Previously incomplete response could be returned without the error if `vmselect` runs with `-replicationFactor` greater than 1. See [this pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/4472). -* BUGFIX: [storage](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html): Properly creates `parts.json` after migration from versions below `v1.90.0. It must fix errors on start-up after unclean shutdown. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4336) for details. +* BUGFIX: [storage](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html): prevent from possible crashloop after the migration from versions below `v1.90.0` to newer versions. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4336) for details. * BUGFIX: [vmui](https://docs.victoriametrics.com/#vmui): fix a memory leak issue associated with chart updates. See [this pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/4455). * BUGFIX: [vmbackupmanager](https://docs.victoriametrics.com/vmbackupmanager.html): fix removing storage data dir before restoring from backup. diff --git a/lib/mergeset/table.go b/lib/mergeset/table.go index 2d9a2640f..1a72f1e2b 100644 --- a/lib/mergeset/table.go +++ b/lib/mergeset/table.go @@ -1378,7 +1378,9 @@ func mustOpenParts(path string) []*partWrapper { } partNamesPath := filepath.Join(path, partsFilename) if !fs.IsPathExist(partNamesPath) { - // create parts.json file on migration from previous versions before v1.90.0 + // Create parts.json file if it doesn't exist yet. + // This should protect from possible carshloops just after the migration from versions below v1.90.0 + // See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4336 mustWritePartNames(pws, path) } diff --git a/lib/storage/partition.go b/lib/storage/partition.go index 779c2cb21..3f48ae224 100644 --- a/lib/storage/partition.go +++ b/lib/storage/partition.go @@ -269,7 +269,9 @@ func mustOpenPartition(smallPartsPath, bigPartsPath string, s *Storage) *partiti partNamesPath := filepath.Join(smallPartsPath, partsFilename) if !fs.IsPathExist(partNamesPath) { - // create parts.json file on migration from previous versions before v1.90.0 + // Create parts.json file if it doesn't exist yet. + // This should protect from possible carshloops just after the migration from versions below v1.90.0 + // See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4336 mustWritePartNames(smallParts, bigParts, smallPartsPath) }