Skip to content

Instantly share code, notes, and snippets.

SELECT validator,
-- Calculate the score for inclusion distance in isolation
COALESCE(SUM(0.875 / optimal_inclusion_distance) FILTER (WHERE optimal_inclusion_distance IS NOT NULL), 0) / (COUNT(*) * 0.00875) AS inclusion_distance_score,
-- Calculate score for correct source in isolation
(COALESCE(SUM(1) FILTER (WHERE correct_source), 0) -
COALESCE(SUM(1) FILTER (WHERE NOT correct_source), 0)) / (COUNT(*) * 0.01) AS source_score,
-- Calculate score for correct target in isolation
######################################
# Teku Application Alert Rules
######################################
groups:
- name: Teku-Slot-Metrics
rules:
- alert: 'Teku Beacon Slot Increase'
expr: sum (irate(beacon_slot{job="prod-teku-node"}[40s])) by (instance) == 0
for: 1m
#!/bin/bash
set -euo pipefail
DIR=${1?Must specify host dir}
mkdir "$DIR/teku"
mkdir "$DIR/teku/keys"
mkdir "$DIR/teku/secrets"
for FILE in $DIR/keys/*
do
PUBKEY=`basename $FILE`
# data
data-path="/data"
logging="INFO"
network="goerli"
min-gas-price=1000
sync-mode="FAST"
host-whitelist=["*"]
We couldn’t find that file to show.
@ajsutton
ajsutton / bad-deposits.yaml
Created August 5, 2020 22:33
Medalla Deposits
This file has been truncated, but you can view the full file.
---
- block: 3086571
timestamp: 1595354906
hash: "0xe0c9089e6c33e4ad896ecae6c4e028366a4c48672818456fb8e287f0a295c75c"
deposits:
- index: 0
publicKey: "0xae9e6a550ac71490cdf134533b1688fcbdb16f113d7190eacf4f2e9ca6e013d5bd08c37cb2bde9bbdec8ffb8edbd495b"
amount: 32000000000
withdrawalCredentials: "0x0062a90ebe71c4c01c4e057d7d13b944d9705f524ebfa24290c22477ab0517e4"
signature: "0xa87a4874d276982c471e981a113f8af74a31ffa7d18898a02df2419de2a7f02084065784aa2f743d9ddf80952986ea0b012190cd866f1f2d9c633a7a33c2725d0b181906d413c82e2c18323154a2f7c7ae6f72686782ed9e423070daa00db05b"
<?xml version="1.0" encoding="UTF-8"?>
<Configuration status="INFO" monitorInterval="5">
<Appenders>
<Console name="console" target="SYSTEM_OUT">
<PatternLayout
pattern="%white{%d{yyyy-MM-dd HH:mm:ss.SSS}} | %-25.25t | %-5level | %-30.30c{1} | %msg%n"/>
</Console>
</Appenders>
<Loggers>
<Logger name="org.quartz" level="INFO"/>
cargo install --path lighthouse --force --locked
Installing lighthouse v0.1.2 (/Users/aj/Documents/code/eth2-clients/lighthouse/lighthouse)
Updating crates.io index
Updating git repository `https://github.com/sigp/rust-libp2p`
warning: package `smallvec v1.4.0` in Cargo.lock is yanked in registry `crates.io`, consider running without --locked
Downloaded aes-ctr v0.4.0
Downloaded hmac v0.8.1
Downloaded serde v1.0.114
Downloaded num-iter v0.1.41
Downloaded serde_repr v0.1.6
"0x2ca3b1"
"0x2ca3b8"
"0x2ca3dd"
"0x2ca3dd"
"0x2ca3de"
"0x2ca3de"
"0x2ca3e1"
"0x2ca3e1"
"0x2ca3e1"
"0x2ca3e1"
I ran lighthouse compiled from latest master (or back a couple of commits for OS X) with:
RUST_LOG=multistream_select=trace lighthouse --debug-level trace bn --http --port 9001 --maxpeers 0
Then grabbed it's multiaddr from log output when it starts up. Configured Teku with:
network: "witti"
p2p-enabled: true
p2p-discovery-enabled: false
# Make this the multiaddr from your Lighthouse
p2p-static-peers: ["/ip4/127.0.0.1/tcp/9001/p2p/16Uiu2HAmEh2HHJSBdsP5hs3wkcquzR6vMGyq4gdTWz2pUJ81KgHn"]
eth1-enabled: false