# Adding Ephemery to Lodestar: running with Geth **tldr;** This time when Lodestar launches on ephemery and looks for the EL client, I want it to find Geth. pk910's initial Lodestar configuration essentially downloads the latest ephemery settings based on whatever is saved at https://ephemery.dev/latest/genesis.ssz and https://ephemery.dev/latest/bootstrap_nodes.txt. ``` export const depositContractDeployBlock = 0; export const genesisFileUrl = "https://ephemery.dev/latest/genesis.ssz"; export const bootnodesFileUrl = "https://ephemery.dev/latest/bootstrap_nodes.txt"; ``` First up, I want to check I can use this approach to sync with Geth. Then, when I am sure that my Lodestar launch command correctly gathers the latest ephemery settings, my plan is to replace the ephemery downloads with the genesis included inside the Lodestar executable. **Syncing with Geth** * Get the latest ephemery version https://github.com/ephemery-testnet/ephemery-genesis/releases * Delete geth datadir and make sure that Geth is initialized with the latest ephemery version `./geth --datadir ../gethData init ../ephemery/genesis.json` * Launch Geth `./geth --datadir ../gethData --port 30303 --http --http.addr 0.0.0.0 --http.port 8545 --http.api eth,net,personal,web3 --ws --ws.addr 0.0.0.0 --ws.port 8546 --ws.api eth,net,personal,web3 --authrpc.jwtsecret=/tmp/jwtsecret --syncmode=full --bootnodes "enode://0f2c301a9a3f9fa2ccfa362b79552c052905d8c2982f707f46cd29ece5a9e1c14ecd06f4ac951b228f059a43c6284a1a14fce709e8976cac93b50345218bf2e9@135.181.140.168:30343" --networkid 39438090` * Launch Lodestar `./lodestar beacon --network ephemery` **Troubleshooting Lodestar error** `ECONNREFUSED ::1:8551` Lodestar won't connect to port 8551, whether Geth is running or not. Checking the logs, the Lodestar root isn't the latest genesis state root that I can see in the ephemery settings. The datadir path can be seen in the logs `Connected to LevelDB database path=/Users/hollyatkinson/.local/share/lodestar/ephemery/chain-db` - [x] Deleted datadir and tried again. Lodestar logs: `stateRoot=0xc37ddf2675dc311def8a4011fb1e066b11960c99b2b5a64cc5826730764b9e91` State root is still incorrect; - [x] Check link refers to latest genesis ssz (server run by pk910, he is pushing the latest files there automatically with a script) - [x] Check jwt path **Solution**: currently still need to pass Lodestar the jwt flag: `./lodestar beacon --network ephemery --jwt-secret=/tmp/jwtsecret` **Creating ephemery package in Lodestar** - [x] Added ephemery package **Additional reading** - [ ] https://ethereum.org/en/developers/docs/data-structures-and-encoding/ssz/ - [x] https://github.com/ChainSafe/ssz/tree/master/packages/ssz - [x] https://www.ssz.dev/overview - [ ] https://eth2book.info/capella/part2/building_blocks/ssz/