Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

geth fast sync restarts at end of blockchain #2639

Closed
adsmaniotto opened this issue May 30, 2016 · 8 comments
Closed

geth fast sync restarts at end of blockchain #2639

adsmaniotto opened this issue May 30, 2016 · 8 comments

Comments

@adsmaniotto
Copy link

System information

I'm running Mist version 0.7.4 on Windows 10.

Expected behaviour

I have been trying for over a week to sync the blockchain using fast sync but have been running into an issue where the sync appears to restart itself when there's only a few thousand blocks left to go. It appears to roll back a couple thousands headers around Block 1606908, and then starts the sync again with a new peer (albiet at a much slower speed).

geth fast sync cmd

The issue seems related to Issue #2469. Is there any available workaround? The fast sync command below took 8 hours to get near the end before the restart.

Backtrace

geth --fast --cache=1024 --jitvm
@karalabe
Copy link
Member

karalabe commented May 30, 2016

Try latest develop, or if your adventurous try #2630. I can fast sync in 25-30 mins flat (albeit on a 200mbit link). The PR I mentioned could especially help on poorer connections.

@karalabe
Copy link
Member

karalabe commented Jun 7, 2016

This sync issue should be solved by our 1.4.6 release. Please check with that and report if it's still broken for you.

@karalabe karalabe closed this as completed Jun 7, 2016
@ghost
Copy link

ghost commented Jun 21, 2016

I hope it's appropriate for me to re-open this.

I'm on 1.4.6 on Ubuntu 16.04

When I delete ~/.ethereum/chaindata/*

And re-start geth:

geth --fast console

Days pass...

Everything fine...

Then I Ctrl+D in geth.

A few moments later I restart:

geth --fast console

fast sync disabled! I have to delete everything in chaindata and restart...

I0621 23:19:28.560522 core/blockchain.go:208] Fast block: #1747043 [bd2635c4…] TD=29636013546513671717
I0621 23:19:28.578204 eth/handler.go:110] blockchain not empty, fast sync disabled
I0621 23:19:28.581229 p2p/server.go:313] Starting Server

@fjl
Copy link
Contributor

fjl commented Jun 21, 2016

That's intended. Fast sync runs only once for security reasons.

@fjl
Copy link
Contributor

fjl commented Jun 21, 2016

This issue was specifically about a bug where fast sync would restart a normal sync from block zero just after completing.

@ghost
Copy link

ghost commented Jun 21, 2016

Apologies for confusing the issue. Thanks for explaining about the one-time fast sync'ing for security reasons. Very helpful information.

@ModGrip
Copy link

ModGrip commented Mar 12, 2017

How do I know when fast sync has completed? Appears to still be running at higher than the current block number. "Processed 3660436" currently and rising.

@Arthur111
Copy link

Arthur111 commented Jun 24, 2017

That's intended. Fast sync runs only once for security reasons.

fast sync must be disabled when the first time its sync.
Until its not sync the first time --fast must stay enabled.
Like this you can restart as you want or after a crash (bug) until its sync for the first time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants