Skip to content

Instantly share code, notes, and snippets.

@ilap
ilap / setup_shelley_monitoring.sh
Last active January 12, 2023 14:03
Shelley monitoring
#!/bin/bash
#---------------------------------------------------------------------
# File: setup_shelley_monitoring.sh
# Created: 2019/10/17
# Creator: ilap
#=====================================================================
# DESCRIPTION:
#
# This script downloads and configures the required files
# for monitoring a Shelley node by using grafana/prometheus.
@michaeljfazio
michaeljfazio / jormon.sh
Last active February 23, 2020 20:52
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
@michaeljfazio
michaeljfazio / generate-peers.sh
Created February 5, 2020 18:03
Generate Peers List
#!/bin/bash
function extract()
{
while read line
do
arr=( $(echo $line | tr ';' ' ') )
addr=${arr[15]::-1}
ip=$(echo $addr | cut -d: -f1)
port=$(echo $addr | cut -d: -f2)