I'm trying to run the following command:
geth --datadir mychaindata --nodiscover --unlock 0 --mine 1
and getting the above error.
When I enter geth account list
, I see two accounts.
What gives?
The option --datadir
declare where are your data would be placed, the whole data includes keystores, database and so on. When you're invoking the command geth account list
it's uses the default datadir (~/.ethereum
). Looks like that directory doesn't contains any accounts. In order to force address you can use the --etherbase
option:
geth --datadir mychaindata --nodiscover --unlock 0 --mine --etherbase YOUR_ADDRESS_GOES_HERE
geth ---datadir mychaindata account new
one.
Commented
Jan 31, 2018 at 14:34
geth --datadir mychaindata account list
?