Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: dwdoc on January 14, 2015, 04:28:07 AM



Title: Will block creation stall if too many miners suspend operation?
Post by: dwdoc on January 14, 2015, 04:28:07 AM
How long will it take for 2016 blocks to be mined before the next difficulty adjustment if BTC price continues to drop and more and more miners cease operation?

https://twitter.com/aantonop/status/555204849361362944


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: DeathAndTaxes on January 14, 2015, 05:12:40 AM
I don't really see it being that big of a problem. Miners aren't a single unified entity.   They all have different costs and they have differing amounts of pain they are willing to tolerate.  It is still winter in the northern hemisphere and residential miners produce "free" heat even if operating at break even electrical cost.

If 50% of the miners quit in a two week period the system would still adjust relatively quickly.  To stall the system would require a massive unprecedented simultaneous shutoff. Even if the hashrate declines 90% I would expect that to occur gradually and not a single unified event.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: dwdoc on January 14, 2015, 05:33:07 AM
Is it a direct proportion? In other words if 50% of miners dropped off at the beginning of a block would it take an average of 20 min to create each block and take 4 weeks until the next difficulty adjustment?


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: DannyHamilton on January 14, 2015, 05:53:54 AM
Is it a direct proportion? In other words if 50% of miners dropped off at the beginning of a block would it take an average of 20 min to create each block and take 4 weeks until the next difficulty adjustment?

Correct.

If 50% of the hash power was all simultaneously shut off immediately after a difficulty adjsutment, then it would take an average of 20 minutes per block and approximately 4 weeks until the next adjustment.

However, it is the most inefficient mining equipment that is most likely to be shut off first.  This means that shutting off 50% of the hash power would require shutting off significantly more than 50% of the miners.

Additionally, as DeathAndTaxes pointed out, it is extremely unlikely that such a large percentage of the hash power would be simultaneously shut off immediately after a difficulty adjustment.  It is FAR more likely that hash power would be shut off over a period of several weeks, meaning that immediately after the difficulty adjustment, blocks will continue to arrive at an average of 10 minutes per block.  As the days and weeks continue, the average time between blocks would slowly increase until the next adjustment.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: stdset on January 14, 2015, 07:26:15 PM
I know this was discussed many times before, and Bitcoin experienced price drops comparable and even exceeding what is happening now. But at least one thing is very different this time: much higher tps. To be frank, I'm scared. In the case of significant part of hashing power switches off, confirmation time for most transactions might increase to unacceptable levels, what could activate vicious cycle, the lower goes the price, the less miners mine, the longer it takes for a transaction to be confirmed, the more people quit Bitcoin, selling at any price, the lower goes the price, eventually Bitcoin dies. Isn't it appropriate time now to at least increase maximum blocksize, better still - improve difficulty adjustment algorithm to be more flexible?


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: kokojie on January 14, 2015, 07:50:54 PM
I know this was discussed many times before, and Bitcoin experienced price drops comparable and even exceeding what is happening now. But at least one thing is very different this time: much higher tps. To be frank, I'm scared. In the case of significant part of hashing power switches off, confirmation time for most transactions might increase to unacceptable levels, what could activate vicious cycle, the lower goes the price, the less miners mine, the longer it takes for a transaction to be confirmed, the more people quit Bitcoin, selling at any price, the lower goes the price, eventually Bitcoin dies. Isn't it appropriate time now to at least increase maximum blocksize, better still - improve difficulty adjustment algorithm to be more flexible?

Or just switch to a Proof of Stake system, where no such non-sense exists.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: DannyHamilton on January 15, 2015, 12:39:23 AM
I know this was discussed many times before, and Bitcoin experienced price drops comparable and even exceeding what is happening now. But at least one thing is very different this time: much higher tps. To be frank, I'm scared. In the case of significant part of hashing power switches off, confirmation time for most transactions might increase to unacceptable levels, what could activate vicious cycle, the lower goes the price, the less miners mine, the longer it takes for a transaction to be confirmed, the more people quit Bitcoin, selling at any price, the lower goes the price, eventually Bitcoin dies. Isn't it appropriate time now to at least increase maximum blocksize, better still - improve difficulty adjustment algorithm to be more flexible?

We can't even have this discussion until you define how much the average confirmation time has to grow before this "vicious cycle" is triggered.

We've already had a few drops in hashing power (and therefore in difficulty) in the past few months, and shortly after that the hash power (and difficulty) increased again.

Note that it is the most inefficient mining equipment that is most likely to be shut off first. This means that the percentage of hash power lost is less than the percentage of hardware shut off.

As hash power is shut off, the remaining miners become more profitable.

The variance in block times is so large that most people wouldn't even notice if the average time between blocks were to double to 20 minutes.  Do you really think that more than 50% of the entire global hash power might all simultaneously shut off simultaneously immediately after a difficulty adjustment?  It is far more likely that the process you describe drags out over a few months.  In that case, the difficulty will continue to adjust every 2016 blocks so that the average time between blocks never reaches "unacceptable levels".


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: dwdoc on January 15, 2015, 01:35:40 AM
So far hashrate looks like it's holding fairly steady despite the steep price drop so perhaps (like a 51% attack) a "stalled block chain" is more of a theoretical problem than a real one. Was just trying to imagine worse case scenario...


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: thompete on January 15, 2015, 08:35:44 AM
Is it a direct proportion? In other words if 50% of miners dropped off at the beginning of a block would it take an average of 20 min to create each block and take 4 weeks until the next difficulty adjustment?

Is there a way to figure out, how many miners have given up on mining?


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: DannyHamilton on January 15, 2015, 09:12:27 AM
Is it a direct proportion? In other words if 50% of miners dropped off at the beginning of a block would it take an average of 20 min to create each block and take 4 weeks until the next difficulty adjustment?

Is there a way to figure out, how many miners have given up on mining?

Not easily.

You could fund an international survey and ask hundreds of thousands of people if they have ever done any bitcoin mining, if they stopped, and when and why they stopped.  Then from those results, you might be able to extrapolate and estimate how many people recently stopped.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: stdset on January 15, 2015, 11:43:01 AM
We can't even have this discussion until you define how much the average confirmation time has to grow before this "vicious cycle" is triggered.

We've already had a few drops in hashing power (and therefore in difficulty) in the past few months, and shortly after that the hash power (and difficulty) increased again.

Note that it is the most inefficient mining equipment that is most likely to be shut off first. This means that the percentage of hash power lost is less than the percentage of hardware shut off.

As hash power is shut off, the remaining miners become more profitable.

The variance in block times is so large that most people wouldn't even notice if the average time between blocks were to double to 20 minutes.  Do you really think that more than 50% of the entire global hash power might all simultaneously shut off simultaneously immediately after a difficulty adjustment?  It is far more likely that the process you describe drags out over a few months.  In that case, the difficulty will continue to adjust every 2016 blocks so that the average time between blocks never reaches "unacceptable levels".
We've seen a very sharp price drop recently (from ~$270/BTC to ~$150/BTC in less than 48 hours). Who knows, maybe in a week or so price will reach $50/BTC, and will stay there for long enough time, in which case I doubt many miners would continue minig. The mere fact that such a scenario could kill Bitcoin scares people out of it. On the other hand, if Bitcoin is prepared for such extreme scenarios, people would get more confidence in Bitcoin.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: TimS on January 15, 2015, 02:39:13 PM
Is it a direct proportion? In other words if 50% of miners dropped off at the beginning of a block would it take an average of 20 min to create each block and take 4 weeks until the next difficulty adjustment?

Is there a way to figure out, how many miners have given up on mining?

Not easily.

You could fund an international survey and ask hundreds of thousands of people if they have ever done any bitcoin mining, if they stopped, and when and why they stopped.  Then from those results, you might be able to extrapolate and estimate how many people recently stopped.
It's difficult to say how many human miners have given up. But if what you're really asking is how much hash power has dropped off (which is the most relevant thing here: is the block chain stalled, or is it progressing like usual?), that's an easy question to (approximately) answer. Just look at the chart at https://bitcoinwisdom.com/bitcoin/difficulty. While it's lower than it was recently, the hash power is still enough that the seconds per block is about 640 (target is 600), not stalled at all.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: Kazimir on January 15, 2015, 11:32:27 PM
confirmation time for most transactions might increase to unacceptable levels, what could activate vicious cycle, the lower goes the price, the less miners mine, the longer it takes for a transaction to be confirmed, the more people quit Bitcoin,
Exactly what is the problem with longer confirmation times?

Notice that in most situations (I'd say the vast majority), it doesn't matter at all if a particular transaction confirms in 5, 10, 20 or 60 minutes.

Remember, you can still send money to each other instantly. Or pay your cup of coffee, or send money to some relative in Asia, or whatever it is you use Bitcoin for.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: dwdoc on January 16, 2015, 03:30:43 AM
For a cup of coffee a merchant probably doesn't need to wait for a confirmation but a retailer selling a TV or PC or car, or a person or ATM exchanging fiat will probably want to wait for a confirmation or two.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: stdset on January 16, 2015, 09:14:49 AM
Exactly what is the problem with longer confirmation times?

Notice that in most situations (I'd say the vast majority), it doesn't matter at all if a particular transaction confirms in 5, 10, 20 or 60 minutes.

Remember, you can still send money to each other instantly. Or pay your cup of coffee, or send money to some relative in Asia, or whatever it is you use Bitcoin for.
Current difficulty adjustment algorithm makes possible a situation when a legit transaction won't be confirmed for a very long time (months). Imagine we have tps rate about half of our tps capacity, although that doesn't matter much. Now a very sharp and severe price decline occurs, in the context of our current conditions, let's say price drops from ~$200/BTC to $50/BTC in very short time, let's say in a week. Miners now mostly aren't enthusiasts, they are businessmen (remember recent cex.io shutdown). Such price decline forces majority of our immediate-profit-driven miners to shutdown, let's say 90% of hashing power switches off. Average blocktime increases to 100 minutes, next difficulty adjustment is about 2 months away. But most importantly, transactions accumulate much faster than they could be confirmed. Unconfirmed transactions pool only grows. Under such circumstances is Bitcoin more alive than dead or more dead than alive?


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: TimS on January 16, 2015, 12:50:35 PM
But most importantly, transactions accumulate much faster than they could be confirmed. Unconfirmed transactions pool only grows. Under such circumstances is Bitcoin more alive than dead or more dead than alive?
This is part of why increasing the maximum block size is a very good thing, IMHO. Let's say blocks were averaging 500 KB before the dropoff. If we're limited to 1MB, your scenario will play out: unconfirmed transaction pool grows and grows, people have to pay higher and higher fees to be put at the front of the list (this would incentivize more miners to join, but it would take a lot of fees to even be noticeable compared to the block reward), etc. until the difficulty can adjust two times. If the limit were already sitting at a max above 5 MB, then confirmation times go up, but transactions still make it into blocks in a timely fashion.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: DeathAndTaxes on January 16, 2015, 11:50:24 PM
But most importantly, transactions accumulate much faster than they could be confirmed. Unconfirmed transactions pool only grows. Under such circumstances is Bitcoin more alive than dead or more dead than alive?
This is part of why increasing the maximum block size is a very good thing, IMHO. Let's say blocks were averaging 500 KB before the dropoff. If we're limited to 1MB, your scenario will play out: unconfirmed transaction pool grows and grows, people have to pay higher and higher fees to be put at the front of the list (this would incentivize more miners to join, but it would take a lot of fees to even be noticeable compared to the block reward), etc. until the difficulty can adjust two times. If the limit were already sitting at a max above 5 MB, then confirmation times go up, but transactions still make it into blocks in a timely fashion.

Block size does need to increase.  One reason it needs to increase is because hard forks require consensus (or a super majority), testing, and a phased in deployment.  It is a 6 month process easy. 

That being said overall blocks are roughly 1/3rd full.  Sure a few blocks by a few miners are large (some even just short of 1MB) but overall the network is running at roughly 1/3rd of the limit.   Even if half the hashrate dropped out, block time would be 20 minutes, adjustment would be in 2-4 weeks, and in the interim blocks would be ~2/3rds full.  For the record we aren't going to see a 50% hashrate decline in a single adjustment period but even that would be survivable.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: dwdoc on January 17, 2015, 03:11:39 AM
I know this was discussed many times before, and Bitcoin experienced price drops comparable and even exceeding what is happening now. But at least one thing is very different this time: much higher tps. To be frank, I'm scared. In the case of significant part of hashing power switches off, confirmation time for most transactions might increase to unacceptable levels, what could activate vicious cycle, the lower goes the price, the less miners mine, the longer it takes for a transaction to be confirmed, the more people quit Bitcoin, selling at any price, the lower goes the price, eventually Bitcoin dies. Isn't it appropriate time now to at least increase maximum blocksize, better still - improve difficulty adjustment algorithm to be more flexible?

That is the vulnerability that needs to be addressed by changing the difficulty re-targeting algorithm.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: stdset on January 18, 2015, 08:06:36 AM
For the record we aren't going to see a 50% hashrate decline in a single adjustment period but even that would be survivable.
For any part of total hashing power, exists low enough exchange rate, to switch that hashing power off. What if US Marshalls tomorrow decide to dump the rest of their confiscated coins on popular exchanges? Or mtGox thief or another whale goes mad, or whatever?


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: waaat? on January 19, 2015, 09:30:42 PM
what is the problem with longer confirmation times?



It causes problems during panicdumps - and people hate to sit in limbo during a crash ...


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: coinableS on January 19, 2015, 09:45:39 PM
For a cup of coffee a merchant probably doesn't need to wait for a confirmation but a retailer selling a TV or PC or car, or a person or ATM exchanging fiat will probably want to wait for a confirmation or two.

Why? Do you know many people that are able to execute raw transactions and double spends on their phone?  If they are at a retailer they will likely only have their phone or a paper wallet on hand as a method of paying.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: stdset on January 20, 2015, 12:06:26 AM
For a cup of coffee a merchant probably doesn't need to wait for a confirmation but a retailer selling a TV or PC or car, or a person or ATM exchanging fiat will probably want to wait for a confirmation or two.

Why? Do you know many people that are able to execute raw transactions and double spends on their phone?  If they are at a retailer they will likely only have their phone or a paper wallet on hand as a method of paying.
If a Bitcoin knowing criminal finds such a retailer, who sells something expensive and doesn't wait for a single confirmation, the criminal doesn't need to send a doublespend from his phone. For example his accomplice could do that, from e.g. a PC. It's better to make the first transaction as low-priority as possible, and include considerable fee into the second. The criminal could also arrange a deal with a thievish pool operator: establish a direct connection from the PC to the pool, so that the second transaction is guaranteed to be received. The pool ignores the first transaction, confirms the second. In the case of success the criminal shares profit with the pool owner. The first transaction is unlikely to be included in several next blocks, so the criminal has enough time to finish paperwork with the retailer and drive away, he could even delay the second transaction release until he leaves.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: dwdoc on January 20, 2015, 12:13:30 AM
Per above it would probably be a good idea to educate merchants that they should require high end transaction fees for zero confirmation sales.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: DannyHamilton on January 20, 2015, 12:59:13 AM
For a cup of coffee a merchant probably doesn't need to wait for a confirmation but a retailer selling a TV or PC or car, or a person or ATM exchanging fiat will probably want to wait for a confirmation or two.
If a Bitcoin knowing criminal finds such a retailer, who sells something expensive and doesn't wait for a single confirmation, the criminal doesn't need to send a doublespend from his phone. For example his accomplice could do that, from e.g. a PC. It's better to make the first transaction as low-priority as possible, and include considerable fee into the second. The criminal could also arrange a deal with a thievish pool operator: establish a direct connection from the PC to the pool, so that the second transaction is guaranteed to be received. The pool ignores the first transaction, confirms the second. In the case of success the criminal shares profit with the pool owner. The first transaction is unlikely to be included in several next blocks, so the criminal has enough time to finish paperwork with the retailer and drive away, he could even delay the second transaction release until he leaves.

Why would a thief go to all that trouble?  Wouldn't it be easier to just pick up the box and walk out of the store? Or in the case of a car, just take it out for a test drive and don't come back.

There is no benefit to going through all these 0-confirmation false transaction efforts.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: stdset on January 20, 2015, 01:16:06 AM
Why would a thief go to all that trouble?  Wouldn't it be easier to just pick up the box and walk out of the store? Or in the case of a car, just take it out for a test drive and don't come back.

There is no benefit to going through all these 0-confirmation false transaction efforts.
Looks like you prefer good and old physical violence? Sure, if you have enough firepower, you don't need all that complicated modern IT stuff.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: hhanh00 on January 20, 2015, 04:24:45 AM
Do miners replace a transaction with one that has a greater fee? I think they don't. In which case, a merchant just has to wait until his transaction reaches enough pools to ensure inclusion in the next block.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: dwdoc on January 20, 2015, 04:43:13 AM
Miners are more likely to include a transaction with a higher fee. Therefore if a customer transacts with a merchant using a small transaction fee and broadcasts this to one set of nodes and then immediately pays himself the same bitcoins with a higher transaction fee which he broadcasts to a different set of nodes, the merchant may end up with nothing. 


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: DeathAndTaxes on January 20, 2015, 05:00:35 AM
Miners are more likely to include a transaction with a higher fee. Therefore if a customer transacts with a merchant using a small transaction fee and broadcasts this to one set of nodes and then immediately pays himself the same bitcoins with a higher transaction fee which he broadcasts to a different set of nodes, the merchant may end up with nothing. 

Any merchant accepting zero confirm txns would be smart to have a large number of listening nodes which detect the second txn and then halt the purchase.   


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: hhanh00 on January 20, 2015, 05:11:50 AM
Miners are more likely to include a transaction with a higher fee. Therefore if a customer transacts with a merchant using a small transaction fee and broadcasts this to one set of nodes and then immediately pays himself the same bitcoins with a higher transaction fee which he broadcasts to a different set of nodes, the merchant may end up with nothing. 
Of course, but you are not answering my question.


Title: Re: Will block creation stall if too many miners suspend operation?
Post by: stdset on January 20, 2015, 06:54:02 AM
Do miners replace a transaction with one that has a greater fee? I think they don't. In which case, a merchant just has to wait until his transaction reaches enough pools to ensure inclusion in the next block.
Normally they don't, they shouldn't even relay a doublespend. But modified, 'greedy' miners could do that. Also, nothing prevents a corrupted miner from colluding with a criminal to accept and confirm a particular doublespend while rejecting all other doublespends like honest miners do.