Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: ChiBitCTy on March 30, 2024, 01:05:47 AM



Title: Bitcoin Testnet and it's Functionality
Post by: ChiBitCTy on March 30, 2024, 01:05:47 AM
I recently acquired some bitcoin testnet coins thanks to Cyrus (as seen in photo below).  I have always been fascinated by the Testnet but have never really gotten a good explanation of what it can and cannot do.

I've heard some say the testnet is just like using the real things.  However if that were the case, wouldn't the debate for larger blocks and what to change or implement, not really be a debate since you'd be able to test everything out to find out for sure?  Would lead me to believe that it's helpful but not really just like the actual blockchain.

I know this is rudimentary for a lot of you, but it's something I've really wanted to gain a little more insight in to, and as mentioned, I just get conflicting info whenever I ask people about it.  

(Not sure if this is the correct board or not, if not my apologies mods)

https://i.ibb.co/LpbrWQJ/image.png (https://ibb.co/cTMwHbC)


Title: Re: Bitcoin Testnet and it's Functionality
Post by: achow101 on March 30, 2024, 04:17:26 AM
Testnet functions is almost the same as mainnet when it comes to the consensus rules. This lets people write software and test it in a no stakes environment but is very close to the real production environment. However, that means that the behavior of the people using testnet is vastly different from people using mainnet. This makes things that are dependent on people's behavior, such as fee behavior, game theory things, etc. cannot be tested.

Ultimately, bigger blocks (or whatever) is not particularly technically hard to execute, so whether it can actually be done is not a question that needs to be answered. What needs to be answered is how people may transact differently, whether they choose to run a node, whether they prune their node, etc. These all depend on the exact conditions of mainnet, and the fact that real money is on the line, so cannot be accurately tested on testnet.


Title: Re: Bitcoin Testnet and it's Functionality
Post by: ChiBitCTy on April 01, 2024, 03:58:48 AM
Testnet functions is almost the same as mainnet when it comes to the consensus rules. This lets people write software and test it in a no stakes environment but is very close to the real production environment. However, that means that the behavior of the people using testnet is vastly different from people using mainnet. This makes things that are dependent on people's behavior, such as fee behavior, game theory things, etc. cannot be tested.

Ultimately, bigger blocks (or whatever) is not particularly technically hard to execute, so whether it can actually be done is not a question that needs to be answered. What needs to be answered is how people may transact differently, whether they choose to run a node, whether they prune their node, etc. These all depend on the exact conditions of mainnet, and the fact that real money is on the line, so cannot be accurately tested on testnet.

Thanks for the info, much appreciated!


Title: Re: Bitcoin Testnet and it's Functionality
Post by: seoincorporation on April 01, 2024, 06:56:17 PM
Hey ChiBitCTy, i would like to use your thread for a couple of questions that i have on the same topic.

1.- How are testnet bitcoin generated, are they mined just like the main-net bitcoin?
2.- To use a testnet node i have to sync the full bitcoin blockchain?

I feel like it isn't worth creating a new topic for these questions, that's why I'm posting them here.

And about the functionality, is a cheap way to test software that will use bitcoin in the future, make test on the main net isn't cheap at all.


Title: Re: Bitcoin Testnet and it's Functionality
Post by: achow101 on April 01, 2024, 10:25:16 PM
1.- How are testnet bitcoin generated, are they mined just like the main-net bitcoin?
Yes. As with mainnet, anyone can mine on testnet, and therefore earn block rewards. This is often done by altruistic miners who also operate testnet faucets.

There are a few different rules when it comes to the difficulty retargeting on testnet so that the chain doesn't stall with the difficulty being too high for a long time.

2.- To use a testnet node i have to sync the full bitcoin blockchain?
You sync the testnet blockchain.


Title: Re: Bitcoin Testnet and it's Functionality
Post by: tranthidung on April 03, 2024, 03:09:08 PM
1.- How are testnet bitcoin generated, are they mined just like the main-net bitcoin?
You can mine Testnet Bitcoin.

On Testnet, difficulty will be adjusted (reset) to 1 after 20 minutes without a new found block since a last found block. It's big difference of difficulty re-target algorithm on Testnet in comparison to Difficulty Re-target algorithm on Main net.

Testnet's unique rule (https://blog.lopp.net/the-block-storms-of-bitcoins-testnet/)
https://github.com/bitcoin/bitcoin/blob/v0.19.0/src/pow.cpp?ref=blog.lopp.net#L23


Title: Re: Bitcoin Testnet and it's Functionality
Post by: Wind_FURY on April 04, 2024, 02:56:00 PM

I've heard some say the testnet is just like using the real things.  However if that were the case, wouldn't the debate for larger blocks and what to change or implement, not really be a debate since you'd be able to test everything out to find out for sure?  Would lead me to believe that it's helpful but not really just like the actual blockchain.


Ser, we already have a few forked Bitcoin shitcoins that literally have bigger blocks running now. I believe that's a better "test" in practice because it's in a live situation. But how much of each of Bitcoin Cash's blocks have truly been filled to its full capacity? Probably almost none? Have they not considered that the underserved that truly need Bitcoin are currently not that many?


Title: Re: Bitcoin Testnet and it's Functionality
Post by: ABCbits on April 05, 2024, 09:37:53 AM

I've heard some say the testnet is just like using the real things.  However if that were the case, wouldn't the debate for larger blocks and what to change or implement, not really be a debate since you'd be able to test everything out to find out for sure?  Would lead me to believe that it's helpful but not really just like the actual blockchain.


Ser, we already have a few forked Bitcoin shitcoins that literally have bigger blocks running now. I believe that's a better "test" in practice because it's in a live situation. But how much of each of Bitcoin Cash's blocks have truly been filled to its full capacity? Probably almost none? Have they not considered that the underserved that truly need Bitcoin are currently not that many?

Looking at https://blockchair.com/bitcoin-cash/charts/average-block-size (https://blockchair.com/bitcoin-cash/charts/average-block-size), it's true block size usually below 1MB. But don't forget BCH community did stress test in past, which can be used as reference.


Title: Re: Bitcoin Testnet and it's Functionality
Post by: Wind_FURY on April 06, 2024, 07:25:23 AM

I've heard some say the testnet is just like using the real things.  However if that were the case, wouldn't the debate for larger blocks and what to change or implement, not really be a debate since you'd be able to test everything out to find out for sure?  Would lead me to believe that it's helpful but not really just like the actual blockchain.


Ser, we already have a few forked Bitcoin shitcoins that literally have bigger blocks running now. I believe that's a better "test" in practice because it's in a live situation. But how much of each of Bitcoin Cash's blocks have truly been filled to its full capacity? Probably almost none? Have they not considered that the underserved that truly need Bitcoin are currently not that many?


Looking at https://blockchair.com/bitcoin-cash/charts/average-block-size (https://blockchair.com/bitcoin-cash/charts/average-block-size), it's true block size usually below 1MB. But don't forget BCH community did stress test in past, which can be used as reference.


I believe not. A stress test is artificial, and we can't truly measure practically how much a network will centralize in a mere stress test. Do you want to observe an actual stress test? Look no further than Ethereum. They said that their network is "fast" therefore fees will always be "low". The current state of their network proved that there is ALWAYS a point of saturation.

If you want to look further, I DYOR, and observed a fast blockchain called "Solana". Their core developers designed the network to always have low fees, with no fee market, and with high transaction throughput. Currently their network is VERY congested, and there's a high failure rate for transactions because they're being dropped. Plus it's very cheap for spammers to sustain those actions.


Title: Re: Bitcoin Testnet and it's Functionality
Post by: ABCbits on April 06, 2024, 09:12:41 AM
Looking at https://blockchair.com/bitcoin-cash/charts/average-block-size (https://blockchair.com/bitcoin-cash/charts/average-block-size), it's true block size usually below 1MB. But don't forget BCH community did stress test in past, which can be used as reference.
I believe not. A stress test is artificial, and we can't truly measure practically how much a network will centralize in a mere stress test. Do you want to observe an actual stress test? Look no further than Ethereum. They said that their network is "fast" therefore fees will always be "low". The current state of their network proved that there is ALWAYS a point of saturation.

If you want to look further, I DYOR, and observed a fast blockchain called "Solana". Their core developers designed the network to always have low fees, with no fee market, and with high transaction throughput. Currently their network is VERY congested, and there's a high failure rate for transactions because they're being dropped. Plus it's very cheap for spammers to sustain those actions.

Ethereum and Solana would be poor reference since it's node need to execute and verify smart contract usage while they also use account-based rather than UTXO-based. I still think BCH stress test as better refernces since some people report how much the node affect their hardware.


Title: Re: Bitcoin Testnet and it's Functionality
Post by: Wind_FURY on April 11, 2024, 09:34:00 AM

Looking at https://blockchair.com/bitcoin-cash/charts/average-block-size (https://blockchair.com/bitcoin-cash/charts/average-block-size), it's true block size usually below 1MB. But don't forget BCH community did stress test in past, which can be used as reference.


I believe not. A stress test is artificial, and we can't truly measure practically how much a network will centralize in a mere stress test. Do you want to observe an actual stress test? Look no further than Ethereum. They said that their network is "fast" therefore fees will always be "low". The current state of their network proved that there is ALWAYS a point of saturation.

If you want to look further, I DYOR, and observed a fast blockchain called "Solana". Their core developers designed the network to always have low fees, with no fee market, and with high transaction throughput. Currently their network is VERY congested, and there's a high failure rate for transactions because they're being dropped. Plus it's very cheap for spammers to sustain those actions.


Ethereum and Solana would be poor reference since it's node need to execute and verify smart contract usage while they also use account-based rather than UTXO-based. I still think BCH stress test as better refernces since some people report how much the node affect their hardware.


It might be for a closer technical comparison, but how long did the stress test last in Bitcoin Cash? The real stress test that will actually give the developers useful data would be once Bitcoin Cash gets the same amount of daily transaction volume as Ethereum or Solana. UTXO-based or not UTXO-based, I believe we will learn something there.

Did you change your username? What was it before the change?