Ethereum Tutorials - Herong's Tutorial Examples - v1.06, by Herong Yang
Verify Pending Transactions
This section describes how to verify pending transactions.
After running my private Ethereum network for some time, I submitted more transactions and try to watch the transaction pending queue:
1. Change the transfer amount to be smaller:
> sender "0x05d4e1a499775ce9d681abd50bda655c7b5ccb90" > receiver "0x485410d2e7b8bfb6f78e5e5acf7d1057cb853fce" > amount "500000000000000000" > amount = "1000000000000000" "1000000000000000"
2. Stop the miner and submit the transaction:
> miner.stop()
true
> personal.unlockAccount(sender)
Unlock account 0x05d4e1a499775ce9d681abd50bda655c7b5ccb90
Passphrase:
true
> eth.sendTransaction({from:sender, to:receiver, value:amount})
"0xab1ec6d670091e181c364decffb77a4e2f47b321050a82463dacd52b6c54ca4f"
3. Check the pending transaction queue:
> eth.pendingTransactions
[{
blockHash: null,
blockNumber: null,
from: "0x05d4e1a499775ce9d681abd50bda655c7b5ccb90",
gas: 90000,
gasPrice: 18000000000,
hash:
"0xab1ec6d670091e181c364decffb77a4e2f47b321050a82463dacd52b6c54ca4f",
input: "0x",
nonce: 1,
r:
"0x852f0dba98847977d4729c56f456a1032a208e9f0329761b2f718db73df29163",
s:
"0x23448e3473d572bee268640a66dfcbb6a7e53c042e949e12ac2883cd59a688b6",
to: "0x485410d2e7b8bfb6f78e5e5acf7d1057cb853fce",
transactionIndex: 0,
v: "0x297",
value: 1000000000000000
}]
4. Submit another transaction and check the pending transaction queue again:
> eth.sendTransaction({from:sender, to:receiver, value:amount})
"0x41b890871732ade78aab27d6cfd126ed7357c2282337a40cb3920c6b80ac0a13"
> eth.pendingTransactions.length
2
> eth.pendingTransactions[0].hash
"0xab1ec6d670091e181c364decffb77a4e2f47b321050a82463dacd52b6c54ca4f"
> eth.pendingTransactions[1].hash
"0x41b890871732ade78aab27d6cfd126ed7357c2282337a40cb3920c6b80ac0a13"
5. Check the pending block to if my transactions are included or not:
> eth.getBlock("pending").transactions
["0xab1ec6d670091e181c364decffb77a4e2f47b321050a82463dacd52b6c54ca4f",
"0x41b890871732ade78aab27d6cfd126ed7357c2282337a40cb3920c6b80ac0a13"]
6. Run the "miner" to seal (or mine) the pending block:
> miner.start(1)
null
> eth.getBlock("pending").number
80
> eth.blockNumber
79
...
> eth.blockNumber
80
7. Check account balances:
> web3.fromWei(eth.getBalance(eth.accounts[0]),"ether") 10000399.498 > web3.fromWei(eth.getBalance(eth.accounts[1]),"ether") 0.502
Nice. Both transactions are processed. 0.002 Ether were transferred my first account to my second account.
If you give me your account address (the public key), I can send you Ether money on my private network now!
Table of Contents
Deprecated: Testnet - Ropsten Network
64-Bit "geth" for Private Ethereum Network
Private Network with Custom Genesis Block
►Transferring Funds between Ether Accounts
Send Ether from One Account to Another
MetaMask - Browser Based Ethereum Wallet
Getting Free Ether on Test Networks