People who were running an outdated version of Geth or were reliant on a vendor (Infura in this case) experienced a forked Ethereum (similar to a server going offline) Nov. 11, 2020, see the post mortem.
No need to fear, having a properly updated Ethereum node is a lot easier than people think using "the cloud".
Kubernetes is a "container orchestration platform", that's a fancy word for keeping docker containers running - and despite whatever complaints you've heard, it makes running and upgrading software like Ethereum painless. Just update version in the yaml file and apply it.
You'll just need a big enough machine to run the Geth client, currently ~650GB of disk (and growing, so at least 1TB), and I'd recommend at least 8GB of RAM. You can get this from Digital Ocean for $80/mo - memory optimized 16GB instance. Then another $100/mo for the 1TB of disk. AWS and GCP might be slightly more expensive (they charge for the Kubernetes cluster). You can expect Geth to finish an initial quick sync in a few hours, then the rest of the data will be backfilled over days/weeks.
If you don't have a Kubernetes cluster/instance/whatever, setting one up is usually "one-click" from Digital Ocean, AWS, or GCP, but it may take a few minutes before the system comes online. On your local machine (e.g. laptop) you'll install the kubectl command-line tool, and then authenticate with the cluster. Most tutorials look daunting but it really is this easy.
you'll be running this command any time after updating geth.yaml (Kubernetes keeps state on the server so it knows, based on the type and name whether this "object" needs to be created or updated after running the apply command):
kubectl apply -f geth.yaml
where the contents of geth.yaml (it should be human-readable) are:
apiVersion: apps/v1kind: StatefulSetmetadata:name: geth-mainnet-fullspec:serviceName: geth-mainnet-fullreplicas: 1selector:matchLabels:app: geth-mainnet-fulltemplate:metadata:labels:app: geth-mainnet-fullspec:containers:- name: geth-mainnet-fullimage: ethereum/client-go:v1.9.23args:["--http","--http.addr=0.0.0.0","--http.vhosts=geth-mainnet-full","--http.api=eth,net,web3,txpool","--ws","--ws.addr=0.0.0.0","--datadir=/data",]env:ports:- containerPort: 8545name: gethrpc- containerPort: 30303name: gethdiscoveryvolumeMounts:- name: datamountPath: "/data"resources:limits:memory: 12000Mirequests:memory: 10000MivolumeClaimTemplates:- metadata:name: dataspec:accessModes: ["ReadWriteOnce"]storageClassName: do-block-storageresources:requests:storage: 1000Gi
kubectl get pods
to see it running, get the name of the pod from the first column and paste it into the following command (remove the variable)
kubectl logs $NAME_OF_POD
Simply edit (using your favorite text editor) the image field where it says 1.9.23 to whatever version you need. Then run:
kubectl apply -f geth.yaml
or edit it live on Kubernetes:
EDITOR=vim kubectl edit statefulset geth-mainnet-full
(applying a file or editing live updates the "state" and will trigger a reboot)
(if for whatever reason the instance is unresponsive)
kubectl rollout restart statefulset geth-mainnet-full
kubectl exec -it geth-mainnet-full-0 -- sh
kubectl port-forward statefulset/geth-mainnet-full 8545:8545
If you prefer a GUI to monitor your Kubernetes cluster status and tail logs, see https://infra.app/.
If you’re a software engineer interested in helping us contextualize and categorize the world’s crypto data, we’re hiring. Check out our open engineering positions to find out more.