Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: btc_enigma on December 20, 2015, 05:49:12 AM



Title: Storing unconfirmed tx on disk
Post by: btc_enigma on December 20, 2015, 05:49:12 AM
I was thinking about why a non miner node would  keep unconfirmed tx in mempool.

Had a look at this https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2015-July/009482.html  and http://bitcoin.stackexchange.com/questions/41536/why-does-bitcoin-keep-transactions-in-a-memory-pool.

While I understand the need to relay tx as fast as possible. How is having a mempool mitigating DOS attack. Can someone give me example on this?





Title: Re: Storing unconfirmed tx on disk
Post by: Quickseller on December 20, 2015, 03:30:42 PM
If you do not store unconfirmed transactions in the mempool then when your node receives a transaction that relies on an unconfirmed transaction it will reject such transaction even though it is valid.

I believe the person answering the stackexchange answer was referring specifically to storing the mempool in memory as opposed to disk. Someone could send a large number of transactions that would cause bitcoind to be consistently writing data on your hard drive (when it receives a new transaction) and reading data on your hard drive (when it needs to make sure a transaction that relies on an unconfirmed transaction is valid) which contributes to wear and tear to your hard drive.