Bitcoin Forum
May 10, 2024, 06:05:58 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Why is Bitcoin wallet client peer sync so slow  (Read 33495 times)
Devious (OP)
Newbie
*
Offline Offline

Activity: 40
Merit: 0



View Profile
October 26, 2012, 07:18:00 PM
 #1

I'm sure this is a beat the dead horse subject, but I can't find a good answer.

Why does a new client take hours (even days) to process, and "catch up"?  I guess I would think after a transaction has been verified x times it wouldn't need to be verified by EVERY other client.  I'm sure I'm just not understanding something...

Thanks!
1715364358
Hero Member
*
Offline Offline

Posts: 1715364358

View Profile Personal Message (Offline)

Ignore
1715364358
Reply with quote  #2

1715364358
Report to moderator
1715364358
Hero Member
*
Offline Offline

Posts: 1715364358

View Profile Personal Message (Offline)

Ignore
1715364358
Reply with quote  #2

1715364358
Report to moderator
I HATE TABLES I HATE TABLES I HA(╯°□°)╯︵ ┻━┻ TABLES I HATE TABLES I HATE TABLES
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715364358
Hero Member
*
Offline Offline

Posts: 1715364358

View Profile Personal Message (Offline)

Ignore
1715364358
Reply with quote  #2

1715364358
Report to moderator
AmDD
Legendary
*
Offline Offline

Activity: 1027
Merit: 1005



View Profile
October 26, 2012, 07:29:06 PM
 #2

I asked the same thing awhile back and the answer I got was way over my head. The best thing to do is to let it download and then save the files somewhere (spare flash drive/external hard drive/etc) and just copy it over if you ever need to reinstall the client. You will still have to update from that point forward but everything from then back will be there and wont need downloading.

BTC tip jar: 18EKpbrcXxbpzAZv3T58ccGcVis7W7JR9w
LTC tip jar: Lgp8ERykAgx6Q8NdMqpi5vnVoUMD2hYn2a
Jimmy Diamond
Newbie
*
Offline Offline

Activity: 6
Merit: 0



View Profile
October 26, 2012, 07:34:04 PM
 #3

It is in the interests of security.  If you want speed use a credit card.
Akka
Legendary
*
Offline Offline

Activity: 1232
Merit: 1001



View Profile
October 26, 2012, 07:36:30 PM
 #4

I guess I would think after a transaction has been verified x times it wouldn't need to be verified by EVERY other client.  I'm sure I'm just not understanding something...

Clients don't verify transactions, Miners include them in a block.

Basically you transaction gets only confirmed 1 Time. After that it counts only the numbers of blocks over the block that confirmed your transaction.

The reason for this is, that the client counts always the longest string of blocks in existence as valid, so which each block more it becomes harder to override your transaction.

This was the easiest way I could explain it.

Edit: That should explain it:


All previous versions of currency will no longer be supported as of this update
Gabi
Legendary
*
Offline Offline

Activity: 1148
Merit: 1008


If you want to walk on water, get out of the boat


View Profile
October 26, 2012, 07:37:10 PM
 #5

Because the database system that is used by the client sucks. Future clients will have another system much much faster.

The client must download every block, the "sync" means it download all the blocks. 1 block is created after average 10 minutes. Now, to verify that each block is indeed ok and the header of it is ok with the previous one, it keep reading the blocks and checking things. If you notice your hard disk happily work when the client is syncing. Future clients will make this verify much much faster by optimizing how the client do this.

Anyway, yes, verifying the blocks is required to make sure the blockchain is the right one. Bitcoin is a p2p network after all, and it cannot trust anyone. It must be sure that the blockchain it download makes sense  Cheesy But yes, making the process faster is a good idea.

Anyway there are lightweight clients who do not download the blockchain and simply use one on a server. This of course doesn't mean they can steal your bitcoin!

Stephen Gornick
Legendary
*
Offline Offline

Activity: 2506
Merit: 1010


View Profile
October 26, 2012, 10:14:47 PM
 #6

Future clients will have another system much much faster.

Not just "sometime in the future" but ... available today (if you are willing to use code stil undergoing development)

Ultraprune merged in mainline
 - http://bitcointalk.org/index.php?topic=119525.0


So, relief is coming.

Unichange.me

            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █


ibno
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile
October 26, 2012, 10:18:20 PM
 #7

You can always download the blockchain via torrent (check out the bitcoin torrent project), and then import it via the -loadblock option.
Foxpup
Legendary
*
Offline Offline

Activity: 4354
Merit: 3044


Vile Vixen and Miss Bitcointalk 2021-2023


View Profile
October 26, 2012, 11:00:22 PM
 #8

In order to verify a transaction, you need to know that all of the transactions that came before it were also valid. Suppose Bob gives you some bitcoins. In order to verify that transaction, you need to know that Bob obtained that money from a valid transaction. Let's say he got the money from Alice. Now you need to know where Alice got the money. And so on, all the way back to the miner who first produced the coins. And that's just for one transaction. In order to verify all transactions sent to you, you need to be able to verify every single transaction that has ever taken place in the history of Bitcoin, and this is exactly what the client is doing when it is synchronising with the network. When doing this for the first time, the client has to not only download the entire transaction record (which is currently nearly 4GB in size), but also verify every single transaction. This can take a while. However, once it has synchronised the first time, the client only needs to download and verify transactions that have taken place since then, so it is much faster.

Will pretend to do unspeakable things (while actually eating a taco) for bitcoins: 1K6d1EviQKX3SVKjPYmJGyWBb1avbmCFM4
I am not on the scammers' paradise known as Telegram! Do not believe anyone claiming to be me off-forum without a signed message from the above address! Accept no excuses and make no exceptions!
Devious (OP)
Newbie
*
Offline Offline

Activity: 40
Merit: 0



View Profile
October 27, 2012, 12:52:25 AM
 #9

Thanks!  That's a great way of explaining it.


I guess I would think after a transaction has been verified x times it wouldn't need to be verified by EVERY other client.  I'm sure I'm just not understanding something...

Clients don't verify transactions, Miners include them in a block.

Basically you transaction gets only confirmed 1 Time. After that it counts only the numbers of blocks over the block that confirmed your transaction.

The reason for this is, that the client counts always the longest string of blocks in existence as valid, so which each block more it becomes harder to override your transaction.

This was the easiest way I could explain it.

Edit: That should explain it:

http://spectrum.ieee.org/img/06Bitcoin-1338412974774.jpg
Nothing4You
Newbie
*
Offline Offline

Activity: 2
Merit: 0



View Profile WWW
October 27, 2012, 04:57:37 PM
 #10

You can get the first 193,000 blocks via torrent way faster:

magnet:?xt=urn:btih:0bb0521942f586ed96203c6f4d136324756f8a9a&dn=bootstrap.dat&tr=udp://tracker.openbittorrent.com:80&tr=udp://tracker.publicbt.com:80&tr=udp://tracker.ccc.de:80&tr=udp://tracker.istole.it:80
Cablez
Legendary
*
Offline Offline

Activity: 1400
Merit: 1000


I owe my soul to the Bitcoin code...


View Profile
November 19, 2012, 03:04:04 PM
 #11

I am a little confused as to why a p2p distributed system has such a hard time transferring ~5Gb of data around.

Is it the way the blocks are broadcast across the network? Such as the most recent blocks get highest priority for verification purposes and the rest whenever a node is able?

It just seems strange that in the torrent world multiple gig files are passed around and verified easily.

Tired of substandard power distribution in your ASIC setup???   Chris' Custom Cablez will get you sorted out right!  No job too hard so PM me for a quote
Check my products or ask a question here: https://bitcointalk.org/index.php?topic=74397.0
Gabi
Legendary
*
Offline Offline

Activity: 1148
Merit: 1008


If you want to walk on water, get out of the boat


View Profile
November 19, 2012, 03:07:05 PM
 #12

I am a little confused as to why a p2p distributed system has such a hard time transferring ~5Gb of data around.

Is it the way the blocks are broadcast across the network? Such as the most recent blocks get highest priority for verification purposes and the rest whenever a node is able?

It just seems strange that in the torrent world multiple gig files are passed around and verified easily.
Because the database system that is used by the client sucks. If you notice your hard disk happily work when the client is syncing.

Cablez
Legendary
*
Offline Offline

Activity: 1400
Merit: 1000


I owe my soul to the Bitcoin code...


View Profile
November 19, 2012, 03:16:05 PM
 #13

It is definitely chugging along.

Tired of substandard power distribution in your ASIC setup???   Chris' Custom Cablez will get you sorted out right!  No job too hard so PM me for a quote
Check my products or ask a question here: https://bitcointalk.org/index.php?topic=74397.0
Ploni
Newbie
*
Offline Offline

Activity: 56
Merit: 0


View Profile
November 19, 2012, 06:24:46 PM
 #14

In order to verify a transaction, you need to know that all of the transactions that came before it were also valid. Suppose Bob gives you some bitcoins. In order to verify that transaction, you need to know that Bob obtained that money from a valid transaction. Let's say he got the money from Alice. Now you need to know where Alice got the money. And so on, all the way back to the miner who first produced the coins. And that's just for one transaction. In order to verify all transactions sent to you, you need to be able to verify every single transaction that has ever taken place in the history of Bitcoin, and this is exactly what the client is doing when it is synchronising with the network. When doing this for the first time, the client has to not only download the entire transaction record (which is currently nearly 4GB in size), but also verify every single transaction. This can take a while. However, once it has synchronised the first time, the client only needs to download and verify transactions that have taken place since then, so it is much faster.

Thank you for this very clear explanation. Smiley
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!