Bitcoin Forum
May 10, 2024, 08:40:42 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: How come transactions are not lost in the Blockchain network -semi newbie inside  (Read 142 times)
babbuz (OP)
Newbie
*
Offline Offline

Activity: 2
Merit: 0


View Profile
December 26, 2017, 05:18:41 PM
 #1

Hi everyone, I am pretty new to the Bitcoin & Blockchain world. I am currently reading Mastering Bitcoin, but I have a doubt I can't solve.

Let me use an easy example:

Let's say there are only 2 mining nodes (A and B), which are both mining the block 5 to to add it to the chain.

Now, from what I have understood, the transactions the 2 nodes have in their block 5 can differ. E.g. the transaction "Alice buys a coffee for 5 BTC" can be in the block 5 that the node A is mining, but not in the block 5 that the node B is mining (e.g. because this transaction arrived later to the node B compared to the node A).

Now, if the winning node for this block is the node B, the transaction "Alice...." won't be stamped in the ledger.

When the competition for the block 5 is over, are the "loosing" nodes (in this case the node A) giving up all the transactions in the block they were working on? and take new transaction from the memory pool?

In this case, if the nodes start again mining for the block 6, the transaction "Alice...." will be in the block 6 for node B, but not in the block 6 for node A (node A has given up the transaction from the block 5)

What if node A wins the mining? Won't the transaction "Alice...." be lost forever?

Please correct me

Cheers
1715330442
Hero Member
*
Offline Offline

Posts: 1715330442

View Profile Personal Message (Offline)

Ignore
1715330442
Reply with quote  #2

1715330442
Report to moderator
Transactions must be included in a block to be properly completed. When you send a transaction, it is broadcast to miners. Miners can then optionally include it in their next blocks. Miners will be more inclined to include your transaction if it has a higher transaction fee.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
AdolfinWolf
Legendary
*
Offline Offline

Activity: 1946
Merit: 1427


View Profile
December 26, 2017, 07:16:55 PM
Last edit: December 26, 2017, 07:33:07 PM by AdolfinWolf
 #2

Hi everyone, I am pretty new to the Bitcoin & Blockchain world. I am currently reading Mastering Bitcoin, but I have a doubt I can't solve.

Let me use an easy example:

Let's say there are only 2 mining nodes (A and B), which are both mining the block 5 to to add it to the chain.

Now, from what I have understood, the transactions the 2 nodes have in their block 5 can differ. E.g. the transaction "Alice buys a coffee for 5 BTC" can be in the block 5 that the node A is mining, but not in the block 5 that the node B is mining (e.g. because this transaction arrived later to the node B compared to the node A).

Now, if the winning node for this block is the node B, the transaction "Alice...." won't be stamped in the ledger.

When the competition for the block 5 is over, are the "loosing" nodes (in this case the node A) giving up all the transactions in the block they were working on? and take new transactions from the memory pool?

In this case, if the nodes start again mining for the block 6, the transaction "Alice...." will be in the block 6 for node B, but not in the block 6 for node A (node A has given up the transaction from the block 5)

What if node A wins the mining? Won't the transaction "Alice...." be lost forever?

Please correct me

Cheers

It's not the nodes that do the mining process right now, it's the pools of miners.

Furthermore, (transactions *basically* have nothing to do with the mining process). Mining is simply discovering a hash that is valid. Then they'll ( most likely) choose the transaction with the highest fees until the block is filled up.

If miner B is ( significantly) faster then miner A, all the transactions from miner b will be added to the blockchain, and as you said, none from miner A .

So, if Alice wasn't chosen by miner B to be in the block, she will still be in the mempool. If miner A mines block 6, and Alice her transaction fee is high enough, there's a good chance miner A takes and puts her transaction in block 6.

Quote
(node A has given up the transaction from the block 5)

Miner A has given up looking for said hash, but the transaction still remains valid to be added in future blocks.

It seems to me that you interpret it as if the transactions itself are "mined", or need significant work to be added into the blockckhain, however this isn't the case.

cyber_smiley
Jr. Member
*
Offline Offline

Activity: 52
Merit: 3


View Profile
December 26, 2017, 07:32:15 PM
 #3

In beginning you would have had a node and mined  "through" your node as exit point so to say. But because of more people  can't compete with each other you have mining pools by joining the pool you can nowadays simply mine without having to be a node - because mining pool have central node so to say to which miners connect and submit their findings.
babbuz (OP)
Newbie
*
Offline Offline

Activity: 2
Merit: 0


View Profile
December 27, 2017, 10:15:46 AM
 #4

Hi everyone, I am pretty new to the Bitcoin & Blockchain world. I am currently reading Mastering Bitcoin, but I have a doubt I can't solve.

Let me use an easy example:

Let's say there are only 2 mining nodes (A and B), which are both mining the block 5 to to add it to the chain.

Now, from what I have understood, the transactions the 2 nodes have in their block 5 can differ. E.g. the transaction "Alice buys a coffee for 5 BTC" can be in the block 5 that the node A is mining, but not in the block 5 that the node B is mining (e.g. because this transaction arrived later to the node B compared to the node A).

Now, if the winning node for this block is the node B, the transaction "Alice...." won't be stamped in the ledger.

When the competition for the block 5 is over, are the "loosing" nodes (in this case the node A) giving up all the transactions in the block they were working on? and take new transactions from the memory pool?

In this case, if the nodes start again mining for the block 6, the transaction "Alice...." will be in the block 6 for node B, but not in the block 6 for node A (node A has given up the transaction from the block 5)

What if node A wins the mining? Won't the transaction "Alice...." be lost forever?

Please correct me

Cheers

It's not the nodes that do the mining process right now, it's the pools of miners.

Furthermore, (transactions *basically* have nothing to do with the mining process). Mining is simply discovering a hash that is valid. Then they'll ( most likely) choose the transaction with the highest fees until the block is filled up.

If miner B is ( significantly) faster then miner A, all the transactions from miner b will be added to the blockchain, and as you said, none from miner A .

So, if Alice wasn't chosen by miner B to be in the block, she will still be in the mempool. If miner A mines block 6, and Alice her transaction fee is high enough, there's a good chance miner A takes and puts her transaction in block 6.

Quote
(node A has given up the transaction from the block 5)

Miner A has given up looking for said hash, but the transaction still remains valid to be added in future blocks.

It seems to me that you interpret it as if the transactions itself are "mined", or need significant work to be added into the blockckhain, however this isn't the case.


Thanks.

Yes, I used the wrong terms, but I have clear in my mind the difference between mining and transactions.

So let me try to ask you this question: is it correct to assume that in the first place the mining pools look for the hash (mining activity) and when they eventually find the hash they complete the block with transaction from the memory pool?

What I am trying to understand is if the 2 activities happen one after the other. In this case if mining pool A doesn't win the first round Alice's transaction would stay in its pool because it is not included in the block the mining pool B has just added to the chain.
AdolfinWolf
Legendary
*
Offline Offline

Activity: 1946
Merit: 1427


View Profile
December 27, 2017, 11:47:45 AM
 #5

Hi everyone, I am pretty new to the Bitcoin & Blockchain world. I am currently reading Mastering Bitcoin, but I have a doubt I can't solve.

Let me use an easy example:

Let's say there are only 2 mining nodes (A and B), which are both mining the block 5 to to add it to the chain.

Now, from what I have understood, the transactions the 2 nodes have in their block 5 can differ. E.g. the transaction "Alice buys a coffee for 5 BTC" can be in the block 5 that the node A is mining, but not in the block 5 that the node B is mining (e.g. because this transaction arrived later to the node B compared to the node A).

Now, if the winning node for this block is the node B, the transaction "Alice...." won't be stamped in the ledger.

When the competition for the block 5 is over, are the "loosing" nodes (in this case the node A) giving up all the transactions in the block they were working on? and take new transactions from the memory pool?

In this case, if the nodes start again mining for the block 6, the transaction "Alice...." will be in the block 6 for node B, but not in the block 6 for node A (node A has given up the transaction from the block 5)

What if node A wins the mining? Won't the transaction "Alice...." be lost forever?

Please correct me

Cheers

It's not the nodes that do the mining process right now, it's the pools of miners.

Furthermore, (transactions *basically* have nothing to do with the mining process). Mining is simply discovering a hash that is valid. Then they'll ( most likely) choose the transaction with the highest fees until the block is filled up.

If miner B is ( significantly) faster then miner A, all the transactions from miner b will be added to the blockchain, and as you said, none from miner A .

So, if Alice wasn't chosen by miner B to be in the block, she will still be in the mempool. If miner A mines block 6, and Alice her transaction fee is high enough, there's a good chance miner A takes and puts her transaction in block 6.

Quote
(node A has given up the transaction from the block 5)

Miner A has given up looking for said hash, but the transaction still remains valid to be added in future blocks.

It seems to me that you interpret it as if the transactions itself are "mined", or need significant work to be added into the blockckhain, however this isn't the case.


Thanks.

Yes, I used the wrong terms, but I have clear in my mind the difference between mining and transactions.

So let me try to ask you this question: is it correct to assume that in the first place the mining pools look for the hash (mining activity) and when they eventually find the hash they complete the block with transaction from the memory pool?

What I am trying to understand is if the 2 activities happen one after the other. In this case if mining pool A doesn't win the first round Alice's transaction would stay in its pool because it is not included in the block the mining pool B has just added to the chain.

A bit of a misunderstanding on my part, transaction are actually chosen BEFORE mining a block. I thought that that didn't really matter, but apparently it does.

See this answer, https://bitcoin.stackexchange.com/questions/7330/whats-the-process-of-creating-a-block-on-the-blockchain

cyber_smiley
Jr. Member
*
Offline Offline

Activity: 52
Merit: 3


View Profile
December 30, 2017, 01:39:15 PM
 #6


A bit of a misunderstanding on my part, transaction are actually chosen BEFORE mining a block. I thought that that didn't really matter, but apparently it does.

See this answer, https://bitcoin.stackexchange.com/questions/7330/whats-the-process-of-creating-a-block-on-the-blockchain

Yes they choose transactions, this is how some bitcoin accelerators work that some pool offers in order for you to get your transactions confirmed faster/included into blocks. Such as free one from viabtc
dothebeats
Legendary
*
Offline Offline

Activity: 3640
Merit: 1352


Cashback 15%


View Profile
December 30, 2017, 02:02:53 PM
 #7

A losing block may include Alice's transaction but not appear on the winning block simply because Bob didn't opt to include that certain transaction. That doesn't mean that the tx is lost in limbo since other miners can still include it up in their block in the next rounds. The winning block is the one that builds up the end of the chain until the other block is solved. No transaction is lost in bitcoin's protocol, just a matter of when would these transactions get confirmed.

.
.HUGE.
▄██████████▄▄
▄█████████████████▄
▄█████████████████████▄
▄███████████████████████▄
▄█████████████████████████▄
███████▌██▌▐██▐██▐████▄███
████▐██▐████▌██▌██▌██▌██
█████▀███▀███▀▐██▐██▐█████

▀█████████████████████████▀

▀███████████████████████▀

▀█████████████████████▀

▀█████████████████▀

▀██████████▀▀
█▀▀▀▀











█▄▄▄▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
.
CASINSPORTSBOOK
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀▀█











▄▄▄▄█
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!