]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
ceph-crash: ping cluster with key on startup
authorSage Weil <sage@newdream.net>
Tue, 2 Nov 2021 14:26:49 +0000 (10:26 -0400)
committerRadoslaw Zarzynski <rzarzyns@redhat.com>
Mon, 12 Sep 2022 17:03:32 +0000 (17:03 +0000)
This is mostly pointless, *except* that after a key rotation it ensures
that the new key is used immediately (and the pending_key is committed by
the mon).

Signed-off-by: Sage Weil <sage@newdream.net>
src/ceph-crash.in

index ae0e4f516464fd4d63a96d497cfe3d7545f89eda..08284fc9ebc7790e9c2e582d88143671af763e5d 100755 (executable)
@@ -101,6 +101,10 @@ def main():
         log.error("directory %s does not exist; please create" % postdir)
         time.sleep(30)
 
+    log.info("pinging cluster to exercise our key")
+    pr = subprocess.Popen(args=['timeout', '30', 'ceph', '-s'])
+    pr.wait()
+
     log.info("monitoring path %s, delay %ds" % (args.path, args.delay * 60.0))
     while True:
         scrape_path(args.path)