From 0ec71442cdb6a79a48dad52503fc2143ddcf4682 Mon Sep 17 00:00:00 2001 From: Brian Brazil Date: Sun, 16 Aug 2015 10:42:31 +0100 Subject: [PATCH] Storage: Tell users how to avoid crash recovery. If users see the crash recovery error, the chances are they aren't shutting down Prometheus correctly. Telling them how to do so will help them debug and fix the problem. --- storage/local/crashrecovery.go | 1 + 1 file changed, 1 insertion(+) diff --git a/storage/local/crashrecovery.go b/storage/local/crashrecovery.go index 4cccdbfbc..18dc6ec70 100644 --- a/storage/local/crashrecovery.go +++ b/storage/local/crashrecovery.go @@ -37,6 +37,7 @@ import ( func (p *persistence) recoverFromCrash(fingerprintToSeries map[clientmodel.Fingerprint]*memorySeries) error { // TODO(beorn): We need proper tests for the crash recovery. log.Warn("Starting crash recovery. Prometheus is inoperational until complete.") + log.Warn("To avoid crash recovery in future, shutdown Prometheus with SIGTERM or a HTTP POST to /-/quit.") fpsSeen := map[clientmodel.Fingerprint]struct{}{} count := 0