Skip to content

Instantly share code, notes, and snippets.

View Chris-Graffagnino's full-sized avatar

Chris Graffagnino Chris-Graffagnino

View GitHub Profile
@Chris-Graffagnino
Chris-Graffagnino / jormon.sh
Created December 27, 2019 14:03 — forked from michaeljfazio/jormon.sh
Jormungandr Node Monitor
#!/bin/bash
#
# Author: Michael Fazio (sandstone.io)
#
# This script monitors a Jormungandr node for "liveness" and executes a shutdown if the node is determined
# to be "stuck". A node is "stuck" if the time elapsed since last block exceeds the sync tolerance
# threshold. The script does NOT perform a restart on the Jormungandr node. Instead we rely on process
# managers such as systemd to perform restarts.
POLLING_INTERVAL_SECONDS=30