# How to Run a Validator From Zero on Resource-Constrained and Low Powered Devices by Diego Losada

- Speakers: [Diego Losada](https://streameth.org/speakers/diego-losada)
- Channel: [Devcon](https://streameth.org/devcon)
- Date: 2023-10-07
- Duration: 45:43
- Watch: https://streameth.org/watch/yt-lPjsXJX6skI
- YouTube: https://www.youtube.com/watch?v=lPjsXJX6skI

## Description

Visit the https://archive.devcon.org/ to gain access to the entire library of Devcon talks with the ease of filtering, playlists, personalized suggestions, decentralized access on Swarm, IPFS and more.
https://archive.devcon.org/archive/watch/6/how-to-run-a-validator-from-zero-on-resource-constrained-and-low-powered-devices/

Our main goal is to contribute to the network decentralization by making it easier and affordable for regular users to run nodes (and staking) on resource-constrained devices as well as helping to test the next major Ethereum upgrade (The Merge).

In this workshop we will show from scratch how to install and set up an Ethereum validator node, from running the Execution Layer + Consensus Layer combo to creating the keys and setup for the validator in order to get it up and running.

Speaker(s): Diego Losada
Track: Staking & Validator Experience
Keywords: node,decentralization,arm boards,raspberry pi,staking,validators,stake at home

Follow us: https://twitter.com/efdevcon, https://twitter.com/ethereum
Learn more about devcon: https://www.devcon.org/
Learn more about ethereum: https://ethereum.org/ 

Devcon is the Ethereum conference for developers, researchers, thinkers, and makers. 
Devcon 6 was held in Bogotá, Colombia on Oct 11 - 14, 2022.
Devcon is organized and presented by the Ethereum Foundation, with the support of our sponsors. To find out more, please visit https://ethereum.foundation/

## Transcript

foreign [Music] good morning we are ethereum and arm first of all thank you all for being here early morning and um uh well we are running about later from zero we are either on arm from Spain um I hope you find this Workshop very useful for you all and we have a little surprise in the end so I truly recommend you and deeply recommend you to stay till the end so Mr Diego and my colleague Fernando they will run this Workshop so let's go for it and work a little bit thanks hello thank you thanks for attending uh before getting started with the with the workshop a little link of of what we do um yeah this is why we are here I mean uh we want people to run notes at home to run to stake at home where it is by running an ethereal and Armin match or or by running an app node or by running a client by yourselves uh whatever it's very very important for for the decentralization of the of the network so this is key and and that's it if I ask uh if I may ask how many of you uh run a uh I know at home well not bad validator great and with these kinds of devices with low power and and result conscious devices is uh very good very good so what we provide we provide a plug and play image so it is very easy to start it just you just need to flash a Micro SD and and start the device and pretty much it configures everything and you have a valuable all the ethereum clients for start and you can run on a full node in in a few commands we will see this later okay as I was saying uh this is what the the image does so uh it's quite quite easy Uh current available for Raspberry Pi and Rock 5. um rock 5 is not yet available okay it's been released this month I think um why run and if you know on these devices well it's affordable I mean it's cheaper than other other Solutions uh expense little power there are performant these devices are powerful particularly now the the rock 5 is is about super powerful device they are focusing on one task I mean uh no graphical environments no web browsing nothing just it's focused on running on home so you have all the resources available for that uh it's small you can put it in any corner of your of your house next to the router or whatever and uh it's based on on the ERM so it's good for uh from a security perspective uh running several architectures so it's good uh this is what the image does uh again automatic installation includes only your clients the client runs uh through systemd devices so we are pretty much easy to to uh to manage and we include monitoring dashboards based on rafana yeah uh Hardware requirements got a little higher uh so we are getting some issues with the with the Raspberry Pi 4 actually uh we just uh being able to to sync a node with get unstable and nimbus I think this will get better off I mean about several weeks because uh client teams are working on on improving the performance and and doing some optimizations we'll see uh the rock 5 is running great I'll show you later uh our validator at home it's running a best way in techu and it's doing great so this device can run pretty much every client everything in client it's it's super powerful yeah uh this is what I was saying uh get unstable plus demos this is the only combo that that actually works and uh drop five see that uh it's powerful 16 gigabytes of RAM nbme it course pretty much amazing so uh I'm thinking over now to Fernando before starting the uh the the note set up because uh we get a lot a question that is important for us why should I trust your image it's an image they are boundaries so foreign [Music] [Music] how we package uh all clients how we make the the image so okay let's go I think the first question is and the short answer is no you shouldn't this should interest us we are going to provide you uh all the different clients in a way of Debian packets and you could ask okay why I should should you should try to how do I know that you are not changing anything in the code or you are not changing anything in the package Northern trying to tell me something or doing anything back but the sure answer is you could do it at home using learning this repository in a very easy way that's our main goal she could do all the same that we do and create your own image we can without need anything from us only ruining these this rubber sorry we will document this okay it's I had it's in our to-do list to uh open a develop section for you to to follow the follower right and and make all of them okay assistant we're trying to do all in a very automatic way very easy and we provide a background image I don't know if you know background background things are approach from fuzzy Corp open source product who tries to to create a developer environment in a very easy way in a very programmatic way I can show you our here this stuff not here yeah it is [Music] okay there we go can you do you see anything okay oh that's that's the way you can find that we can file the only thing that's still is prepare an environment in order to create all the packages okay it's a very easy and pragmatic way to to do so uh do you ask to background to create a Ubuntu machine and install all the software that you need to create the image all the packages are basis on the work of this guy from Jordan Caesar I don't know I promise okay his surname but this guy creates a very nice way to create to automate the creation of a Debian package or RPM packages or whatever you know so using his work is for us is very very easy to create any any package so if you clone this our repository I mean do some a very simple command background app to create a bigger machine with all the code inside for example you will have to enter in this directory FFM package Builder and inside you will be a folder for any client that we support for example if you see they get a folder here it's [Music] um pretty small and simple make file and with this Mac file you will create the same package that we are providing you in our Repository there is a simplest idea is go to GitHub and from the people from go ethereum obtain the version obtain the this version that the package has and Creator RPM the only thing that you are going to do is download the latest binary enlisted binary for the RM for for our arm with this binary and this further structure you will create a Debian package the only app or from site is this small system the unit in order to to be more easy to to use the software you could do system start system stop or system start for the software all the configuration also is included it's a basic configuration [Music] expensive because we use later Prometheus and grafana in order to show you the your ticket statistics you could see later in our garfana environment it's also included in the image so you could simply go to a rebel and and the simple a simple get if GitHub is not probably the speed of the Wi-Fi is not fast enough to see it but the only thing that is gonna be is open or download the latest binary and create a Debian package these event packages we will provide you in uh in front of our Italian repository but do if you don't understand you could do it yourself or you could check if the um if the m6 md5 sun is the same from our repository and your your packets and we'll see we're going you know we will not change anything in the in the official binary okay let's start I don't know if it's only 40 seconds you know the the skip will do all for you it will create your typing packets and you could use it offline and not trust our Repository it's it's Imperial uh uh official binary with a systemd file assisting the unit also we provide the same for the for the SD image we want to wait these three seconds okay and the end you will be that we are raised on it before train but here you will have your Debian packets for the guest it's very simple it's pretty easy it's not anything strange here it's only uh our Debian package in order to create it more easily and for the for the uh for the Ubuntu image that we're using for all of three devices it's almost the same thing a small make packet make file story that here we will download the latest Ubuntu available for for arm and and keep it as one here we'll disable the automatic categories because if we don't do this the first room is very very slow because Montage will try to grade in the first round and probably if the matches are a bit old we will last for very very minutes or even hours and the only art that we do is add this small RC logo in this RC local resolve damage because here uh is all the logic we will create a partition for you we will create all the new users and permissions in order to this package room with the configuration that we made um in I think in a very simple way you could do it at home do not need ask for anything you could create your own image you could add your own server if you want you could create your own package if you don't trust uh Repository um that's the thing that okay Judas shouldn't trust us but you can see if we are doing anything wrong or we are cheating doing it at home in a very easy way okay okay thanks Fernando Let's uh fire up a node uh we will follow the official our official recommendation as you can see it's a pretty straightforward uh process after you will need to download our image we already did because you know it's here we unzip it uh all instructions are here uh you see unzip we will flash I have a here a microSD so uh what's the what's the flash process end you just need to make sure that uh you uh attach an ethernet cable the the SSD in in the port in the blue part the blue board and uh you put them acros D in in the slot and just that uh Power device and the on the first boat our uh Auto speed will reconfigure everything and install all the all the software necessary to run a node and creating the keys for the validator uh so once you uh after maybe 10 minutes the the device will restart and you will be a on a recent uh um online machine that is a pretty much configured for for running a an equivalent mode okay so uh let's wait for uh for for it to finish so I may be I don't know how much can take this okay so uh we will be connecting to uh an a WS machine because uh we need to to connect remotely and it's not comfortable because it is uh it's more um it's more it's it's quicker sorry it's faster and but it's unbased it's exactly the same that you will uh get with this uh with a Raspberry Pi or or a rock type okay we also provide a AWS image if you want to try uh or imagine in in your account is uh one click away from it's just launching a command I will show you um the config file so you can see all flags that it's needed to run a client again the token and the two points in I was saying is this URL so let's launch the service and let's see what happens so it's going to start you see that uh already a loaded a block and state from the checkpoint it says that yes there's an execution endpoint but it's not single it's not synced so uh it's gonna start telling uh the execution line what to do okay and that's it for fire up a note you have an execution layer a consensus layer you start the both services and without limit it's pretty much what you need to do to to launch a note okay is that easy uh again like I said uh in the intro and Raspberry Pi now just things with um get unstable and like if sorry and Nimbus because yeah post marriage uh Hardware requirements went went a little higher so uh we need to wait I think a little uh optimizations to come from from from crime teams and I think I it will be able again to think with our clients but we'll see we are not sure of that uh the rock 5 is running fine I mean pause merge premiered it's a very very powerful device and it is a drawing great so um let's go to the validator um as you can see you just need to create the keys and and running a command to to import the the evaluator keys in the in the in in the consensus layer so we can go to the second path from the ATM Foundation you can see here all the steps that you need to follow and pretty much everything that it's here it's already done I mean an execution client is configure you can choose from from all these four again you're good you can choose uh from any any client a as well again you are done uh validators let's try about one by later again this um you now need a a tool for creating the device or Keys it's already installed and actually um is this one pause it so we can launch this command straight forward as ethereum account receivable user okay uh that's a English English password this is a password for uh your key store okay yeah this is these are your keys please don't lose this okay write them down and keep them because without this you will not be able to withdraw and that would be a problem yeah but this is [Music] okay let's confirm okay these are as you can see it's probably now you can you have uh Keys here the deposit data that you will upload in the 32 is uh deposit any Keystone where your keys are okay so let's import them anything in laptops account all right so we have the validator keys arrays tab so we just need to start the service um oh suggested let's see okay okay we need to add here a an address I have one here it's one it's ours start again [Music] okay here it is and uh one validator variable so you just have to go here and know what you're doing upload here this um this file deposit okay it's this one it's explained here I mean uh it's much you know you have two options or I can maybe copy and paste here okay for you to see foreign okay it's fine and now the more fun process that it's sending 32 with and pray for to the regards that uh it's gonna be fine because it's a it's a lot of cash I mean and that's all I mean uh it's uh as you as you can see it's it's a simple process if you have some line of skills is fine I mean but you can do it without technical excuse as well if you follow the recommendation and I think uh we are done with this let's see for processor running let's go find so um The Rock five yes let's connect five yes we are going to show our validator running uh I think three radiator right now with a rock five and with four five right now is cheaper than the Raspberry Pi 4 even and probably twice or three times powerful so yeah right now is going to for uh Rock five whenever it's available again you can see here in the motherboard it's running a rock tip again and you can see here um processes that are based on Techo so let's see this is our evaluator you see that it's actually publishing at the stations it's running right now it's running fine and uh the rock 5 is is running both uh both clients in in uh at the same time and and with no problem at all I mean this is a super powerful device uh you can we can see a big base as well now you see it's in sync it's working perfectly and again this device is not yet available but I think uh we have contact with the manufacturer I actually uh this is a prototype from March I think on March April I don't know and they are already releasing a batch we have five uh on its way I mean I think that it will be available pretty soon and super powerful device super uh a useful device for for running an ethereum node and Hope they've released it this month okay so uh what's left the last thing okay now I will uh post a tweet yeah okay um as I told you at the beginning of this Workshop um there is a raffle right now so if you want to participate uh Diego is going to post uh in Twitter are you ready then okay thanks uh if you follow us in art ethereal and arm um you just need to post something like no there we go okay you have to post I attend to the workshop and I want to win something okay that something is a raspberry uh P4 okay and um from now on put the counter in three minutes uh uh we're going to stop five five minutes really okay five minutes we're gonna stop and somebody wins something today yes I mean it's it's he told me five minutes we just did it so just saw me three yeah five okay confirm five okay uh yeah I was going to Salvia uh does anybody here I'm pretty sure that uh anyone here has any question or yeah okay what were the rock 5 sell for how much would it be uh 189 dollars but you need an nbme disk so it will be a little higher and you need a power device and the MicroSD I think it should be between 1 750 over 400 I mean because total cost of no uh well I have four questions so yeah probably quick uh do you recommend using a WS instance against running your no okay no no not at all no this this was for for the workshop [Music] we don't we don't uh want uh people running out some AWS because that that's not a decentralized way of of doing this so no no okay and what advantages do you see in running around Valley lasers instead of delegating the staking well because it's very important for the network actually uh uh is there's a problem with centralization in these large pools I mean it's very important that people stick at home because if one pool or several pools want to take over the network there is uh this uh other Army of nodes that is from the people I mean and it's very very important to fight against this kind of attacks to to stay at home okay and what measures do you take at home to ensure uptime to cheer up time well we have uh s-i-s-a-i I mean one thing that I uh I want to say is that it's okay being offline because the protocol is very generous I mean the the penalties for being online offline sorry are very low so there's no problem for being offline uh you can be uh online 95 for 99 a whole year and you have and you are good so don't do don't Overkill I mean don't do which I don't don't automate things because you can business so it's okay being offline no no problems no problem thanks sorry uh one thing that I do that I find is quite good is uh do this come with grafana yeah enabled yeah so in grafana you can add the telegram group as a um as a notification point and you can set up an alert on like critical log so it sends you a telegram message I find that's like a really really easy way to just to know when things are up Paul from from Lighthouse thank you thanks for your help okay next one I'm just curious what your experience is if you have uh like run on specifically a bit more constrained devices like the Raspberry Pi like which of the implementations are the most efficient in those circumstances on arm devices on there but sorry um like which of the node softwares do you find run the most efficiently yeah uh give a spell performance but it's very optimized and regarding courses layer uh I would say Nimbus because Nimbus uses a very low from memory it's amazing and but anyway a pretty much a besides uh everyone that you know that executes pretty much all the blockchain all blocks uh and basically when they're good at uh our Java based and they are they are a little heavier uh the other client person Lighthouse numbers get another man we're running fine I mean yeah I uh thank you very much love the talk love the work um do you have any plans for saying like nvv boost or anything like that for integration we are we are uh we already package made boots but um we are a little concerned because uh they are not every relays but they are already censored in some transactions and uh we prefer to wait and it it works I mean it works fine and you can even have a raspberry P3 maybe or or this kind of of devices because it's very light but we are a little concerned about centralization and sensory you know and transaction censorship thank you hey uh are you cross-compiling when using the background no official binaries um the only accession is everyone because they don't provide the banners yeah and sorry one more or less question so I noticed that you're using swap how is that impacting the io on the on the boards you know um the swap for the raspberry piece uh necessary because you know eight gigabytes are very tight and it's created on the on the USB SSD so yeah it's not the the is not the better solution but it's needed so uh yeah it's something that uh we need to to do more questions right there okay there you go on a device like the Rocks 5 do you have any recommendations about the number of validators that it should should have is there a recommended limit before you see a CPU binding I have to say uh we are running three but I think that uh it will be able to run a lot I don't have a figure to to give you but I think that uh a lot I mean yeah hi thanks for presentation I came a little late so I'm not sure if that was discussed um do you know if somebody working on an incentive program or protocol similar to helium where um individuals takers that can you know prove that they're running in a location that doesn't have high density gets a little bit of incentive no I'm sorry no okay because that would be helpful for the centralization yes I guess so yes but I not have an opinion about us because I don't I don't know what's up you know sometimes you you cannot answer or but always the point to learn is there any other question yeah right there so for the Raspberry Pi 4 you said you use SATA if I'm not mistaken with the compute module you use like SATA over use over USB right that's your setup um excuse me industry USB yeah yeah but for the compute module with the i o Port you can actually connect it connect you can use nvme as well I don't know if you've tried it out you can yeah you can do you can do does that help with any of the performance issues it's very similar I mean it doesn't make a difference I think well if the if some of the performance issues are because of i o stuff then it might help yeah but you are um you know they they use B3 is the butternut here so no but so the compute module has supports nvme sorry sorry sorry I misunderstood and we we didn't try uh the computer model no we didn't try it uh but uh I guess it will be will be better yes yes thank you one more there there running out of time maybe one or two questions just really quick I'll follow up on the USB 3 thing but you have documented which USB adapters works and also which USB 3 as the modules uh um the best option from our experience is uh anesthetic Bridge uh which is a little advice that connects this is a SATA to to USB 3 that works very well uh you can use uh use portable USBS such as uh crucial or or Samsung T5 t67 t7 you know has a little uses but uh yeah you you can I you can actually um the use a lot of a lot of options so it's difficult for us to to test everything but recommendation our recommendation is the static Bridge yes it works right right uh what's your opinion on shared pools taking uh we are very we are big fans of rockpool uh actually uh we are in contact with uh Joe clappies they are running uh rocket pool in the rock 5 as well and yeah this is uh this is a way of lowering the 32 barrier uh in a decentralized way yes it's very nice I am we are big fans of of Rocket pool so yeah we recommend that we have time for one or maybe two questions uh anyone nobody everything is clear sure uh no it's not in the no it's not confused I was asking if you have the graphene nope [Music] it's uh because the part of you know you have to connect to the 3000 port and weekend okay okay um okay so as I told you before um we're given a gift this ruffle so someone in here is going with something pretty interesting because the raspberry P4 for free of course so the winner is and just flash prepare for I just love to prepare something sorry we are going to we can see we are running a a random number don't be tricky we can see it in the screen there are nine participants should all happen and number two participating number two please after he's gone maybe dude is not here okay he went away for so the next one is number eight is fingers crossed that he's here Alex Alex Smith whoa winners pass for him so far it's gonna explain you yeah yeah okay congrats so um uh thank you for and and Diego it's been a pleasure to share this uh their knowledge and and all of you this morning I just want to remind you that we'll be uh tomorrow downstairs at the booth uh with our well you'll see perfectly ethereum on arm okay and we're gonna be there if you I don't know if this tonight comes up any further question will be there uh the whole day right yeah so thank you all and I don't know if you want to add some words thank you okay thanks guys thanks a lot thank you
