rzmahmood / ethereum-pos-testnet Goto Github PK
View Code? Open in Web Editor NEW๐ปโ๏ธ A Quick and Easy Way to Bootstrap your own Local Ethereum PoS Testnet. Great for testing consensus โ๏ธ๐ป
License: MIT License
๐ปโ๏ธ A Quick and Easy Way to Bootstrap your own Local Ethereum PoS Testnet. Great for testing consensus โ๏ธ๐ป
License: MIT License
Any help is greatly appreciated !
I am running geth with lighthouse and will appreciate your guidance!
Hi @rzmahmood !
Hope you are doing well,
I split the 'testnet. sh' files into separate files to monitor two nodes in different terminals. However, when I ran these nodes in separate terminals, they both created two blockchains with the same chain ID. When I tried transferring the native balance, I noticed that the balances were displaying different values on two different RPC URLs, even though they shared the same chain ID. How to check nodes are connected with each other?
Hi @SyedMuhamadYasir , @rzmahmood !
Hope you both are doing well.
Machine 1: I am running the bootnode
Machine 2: Node-1) Running the geth node with machine 1 bootnode and beacon node without bootstrap node
Node-2) Running 2nd geth node with machine 1 bootnode and beacon node with first beacon bootstrap node.
Machine 3: Node-3) Running 3rd geth node with machine 1 bootnode and beacon node with first beacon bootstrap node.
Here I'm running 2 nodes from machine2 and 1 node from machine3 and machine2 2 nodes are creating separate blockchains and the machine3 node is not connecting with the other 2 nodes, showing looking per peers.
Here i am using the same genesis files and i am creating the new accounts per each node and adding in genesis file extract data to become a validator.
2_beacon_node.txt
1_beacon_node.txt
2_geth_node.txt
1_geth_node.txt
Originally posted by @Gopal-Gurram in #14 (comment)
i am also facing the same issue
./prysmctl testnet generate-genesis --fork=capella --num-validators=2 --chain-config-file=./config.yml --geth-genesis-json-in=./genesis.json --output-ssz=./genesis.ssz --geth-genesis-json-out=./genesiss.json
INFO[0000] Specified a chain config file: ./config.yml prefix=genesis
INFO[0000] No genesis time specified, defaulting to now() prefix=genesis
INFO[0000] Delaying genesis 1696420459 by 0 seconds prefix=genesis
INFO[0000] Genesis is now 1696420459 prefix=genesis
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x1702abf]
goroutine 1 [running]:
github.com/prysmaticlabs/prysm/v4/cmd/prysmctl/testnet.generateGenesis({0x242da70, 0xc000056120})
/home/art/dev/eth-custom/devnet/prysm/cmd/prysmctl/testnet/generate_genesis.go:279 +0x6ff
github.com/prysmaticlabs/prysm/v4/cmd/prysmctl/testnet.cliActionGenerateGenesisState(0xc00031fd40)
/home/art/dev/eth-custom/devnet/prysm/cmd/prysmctl/testnet/generate_genesis.go:179 +0x1c9
github.com/prysmaticlabs/prysm/v4/cmd/prysmctl/testnet.glob..func1(0x32161a0?)
/home/art/dev/eth-custom/devnet/prysm/cmd/prysmctl/testnet/generate_genesis.go:70 +0x2e
github.com/urfave/cli/v2.(*Command).Run(0x32161a0, 0xc00031fd40, {0xc000b00850, 0x7, 0x7})
/home/art/go/pkg/mod/github.com/urfave/cli/[email protected]/command.go:274 +0x9eb
github.com/urfave/cli/v2.(*Command).Run(0x3216040, 0xc00031fc40, {0xc000572380, 0x8, 0x8})
/home/art/go/pkg/mod/github.com/urfave/cli/[email protected]/command.go:267 +0xc4d
github.com/urfave/cli/v2.(*Command).Run(0xc000b0e000, 0xc00031fb00, {0xc000052090, 0x9, 0x9})
/home/art/go/pkg/mod/github.com/urfave/cli/[email protected]/command.go:267 +0xc4d
github.com/urfave/cli/v2.(*App).RunContext(0xc0002665a0, {0x242da70?, 0xc000056120}, {0xc000052090, 0x9, 0x9})
/home/art/go/pkg/mod/github.com/urfave/cli/[email protected]/app.go:332 +0x616
github.com/urfave/cli/v2.(*App).Run(...)
/home/art/go/pkg/mod/github.com/urfave/cli/[email protected]/app.go:309
main.main()
/home/art/dev/eth-custom/devnet/prysm/cmd/prysmctl/main.go:23 +0x8e
Currently, the validators created in Genesis are baked in to Prysm. Ideally we can generate the validators separately, and assign them to different nodes
Hi @rzmahmood
Hope you are doing well,
After starting the blockchain some time below error is coming and transactions are going to pending and new block number is not generating.
I just want to make my own testnet which is available to connect with other peers
You mention that jq and go are prerequisites, but bazel is also required:
Error: bazel is not installed. Please install bazel first. See https://docs.prylabs.network/docs/install/install-with-bazel#install-bazel-using-bazelisk
I dind't find the instructions at the referenced page particularly clear, and used this on Ubuntu 22.04:
Download bazelisk-linux-amd64 from https://github.com/bazelbuild/bazelisk/releases/download/v1.19.0/bazelisk-linux-amd64
Rename it bazel: mv bazelisk-linux-amd64 bazel
Make it executable: chmod +x bazel
Sudo move it to /usr/local/bin: sudo mv bazel /usr/local/bin
Hi @rzmahmood
thank you for sharing your knowledge. This was extremely helpful!
But what if I want to deploy a private network with persisted state between the sessions (i.e. without clearing ./network folder)?
I try to use prysmctl with deposit-json-file, but process crashed. May be somebody knows how to this this issue ?
+ ./dependencies/prysm/out/prysmctl testnet generate-genesis --fork=capella --num-validators=2 --deposit-json-file=./staking_deposit-cli/validator_keys/deposit_data-1697028676.json --chain-config-file=./config.yml --geth-genesis-json-in=./genesis.json --output-ssz=./network/genesis.ssz --geth-genesis-json-out=./network/genesis.json
INFO[0000] Specified a chain config file: ./config.yml prefix=genesis
INFO[0000] No genesis time specified, defaulting to now() prefix=genesis
INFO[0000] reading deposits from JSON at /home/art/dev/go_workspace/ethereum-pos-testnet/staking_deposit-cli/validator_keys/deposit_data-1697028676.json prefix=genesis
INFO[0000] setting fork geth times prefix=genesis shanghai=0xc000835be8
panic: runtime error: integer divide by zero
goroutine 1 [running]:
github.com/prysmaticlabs/prysm/v4/consensus-types/primitives.ValidatorIndex.Mod(...)
/home/art/dev/eth-custom/testnet/ethereum-pos-testnet/dependencies/prysm/consensus-types/primitives/validator.go:39
github.com/prysmaticlabs/prysm/v4/beacon-chain/core/altair.NextSyncCommitteeIndices({0x21bdd70, 0xc0000560e0}, {0x21e64b8?, 0xc0008b58c0})
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.