mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
lib/storage: save storage ID after init
This helps to avoid re-creating a storage ID in case of unclean shutdown. Signed-off-by: Zakhar Bessarab <z.bessarab@victoriametrics.com>
This commit is contained in:
parent
71e729f3f8
commit
5ac1e77520
1 changed files with 1 additions and 0 deletions
|
@ -264,6 +264,7 @@ func MustOpenStorage(path string, retention time.Duration, maxHourlySeries, maxD
|
|||
} else {
|
||||
nodeID := rand.Uint64()
|
||||
s.nodeID = nodeID
|
||||
s.mustSaveNodeID()
|
||||
}
|
||||
|
||||
// Load indexdb
|
||||
|
|
Loading…
Reference in a new issue