Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--dev mode restart error with --datadir #29955

Closed
HowHsu opened this issue Jun 8, 2024 · 1 comment · Fixed by #29963
Closed

--dev mode restart error with --datadir #29955

HowHsu opened this issue Jun 8, 2024 · 1 comment · Fixed by #29963
Labels

Comments

@HowHsu
Copy link

HowHsu commented Jun 8, 2024

System information

Geth version: geth version
CL client & version: e.g. lighthouse/nimbus/prysm@v1.0.0
OS & Version: Linux
Commit hash : 68c0ec0

Expected behaviour

geth successfully starts

Actual behaviour

geth canot start, error: Fatal: Could not read genesis from database: could not unmarshal genesis state json: missing required field 'balance' for Account

Steps to reproduce the behaviour

./build/bin/geth --dev --datadir ./data --http --http.api personal,eth,net,web3,debug --allow-insecure-unlock

run this command, ctrl+c to quit it, then run this command again, the error occurs.

Backtrace

INFO [06-07|16:24:29.422] Starting Geth in ephemeral dev mode...
WARN [06-07|16:24:29.422] You are running Geth in --dev mode. Please note the following:

  1. This mode is only intended for fast, iterative development without assumptions on
     security or persistence.
  2. The database is created in memory unless specified otherwise. Therefore, shutting down
     your computer or losing power will wipe your entire block data and chain state for
     your dev environment.
  3. A random, pre-allocated developer account will be available and unlocked as
     eth.coinbase, which can be used for testing. The random dev account is temporary,
     stored on a ramdisk, and will be lost if your machine is restarted.
  4. Mining is enabled by default. However, the client will only seal blocks if transactions
     are pending in the mempool. The miner's minimum accepted gas price is 1.
  5. Networking is disabled; there is no listen-address, the maximum number of peers is set
     to 0, and discovery is disabled.

INFO [06-07|16:24:29.424] Maximum peer count                       ETH=50 total=50
INFO [06-07|16:24:29.425] Smartcard socket not found, disabling    err="stat /run/pcscd/pcscd.comm: no such file or directory"
INFO [06-07|16:24:29.428] Set global gas cap                       cap=50,000,000
INFO [06-07|16:24:29.494] Using developer account                  address=0x958dd2c08650fF154d0030923790250eFd06EffB
INFO [06-07|16:24:29.495] Using pebble as the backing database
INFO [06-07|16:24:29.495] Allocated cache and file handles         database=/home/tmp/geth_node/data/geth/chaindata cache=512.00MiB handles=524,288
INFO [06-07|16:24:29.496] Opened ancient database                  database=/home/tmp/geth_node/data/geth/chaindata/ancient/chain readonly=true
Fatal: Could not read genesis from database: could not unmarshal genesis state json: missing required field 'balance' for Account

When submitting logs: please submit them as text and not screenshots.

@HowHsu HowHsu added the type:bug label Jun 8, 2024
@jwasinger
Copy link
Contributor

Confirming I can reproduce this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants