Not by genesis file to be clear
when we create new account through geth console it should create new account with some pre-defined balance
2 Answers
If your requirements are as stated, that is:
- creating an account through geth console should create an account with a balance, and
- you cannot alter the genesis file
then your only option is to alter the source code of the Ethereum client you're using and ensure all nodes have matching consensus rules (probably by deploying your altered client code).
Changing the genesis file would allow you to pre-create accounts with balances, but this would violate your requirement #2.
Mining after chain creation would allow you to populate accounts with mining proceeds, but this would violate your requirement #1.
(If this is just for testing purposes, consider using one of the test setups like Ganache.)
You can't do pre-allocate ether. Because,
Create new address before validation by the network, it is off-chain process and this address checks by the network whether the address is valid or not and if valid then set nonce to 1 and you know that this is now ready for transaction.
You have to transfer ether explicitly from another externally owned account or contract account.
- EoA -> CA -> EoA
- EoA -> EoA
x
instead of 0.