Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Syncing block that is already imported #9343

Closed
phahulin opened this issue Aug 13, 2018 · 10 comments
Closed

Syncing block that is already imported #9343

phahulin opened this issue Aug 13, 2018 · 10 comments
Labels
M4-core ⛓ Core client code / Rust. Z1-question 🙋‍♀️ Issue is a question. Closer should answer. Z3-stale 🍃 Issue is in principle valid, but it is not relevant anymore or can not reproduced.
Milestone

Comments

@phahulin
Copy link
Contributor

I'm running:

  • Which Parity version?: 1.11.8
  • Which operating system?: Linux
  • How installed?: via binaries
  • Are you fully synchronized?: yes
  • Which network are you connected to?: core
  • Did you try to restart the node?: yes

Parity would sometime sync blocks that it has already imported (e.g. 4142114)

2018-08-13 03:39:20 UTC Imported #4142113 0xfa38…3c97 (1 txs, 0.02 Mgas, 0 ms, 0.67 KiB)
2018-08-13 03:39:25 UTC Imported #4142114 0x810f…a43e (1 txs, 0.02 Mgas, 0 ms, 0.67 KiB)
2018-08-13 03:39:30 UTC Syncing #4142114 0x810f…a43e     0 blk/s    0 tx/s   0 Mgas/s      0+    0 Qed  #4142084   39/50 peers      3 MiB chain   88 MiB db  0 bytes queu
e    2 MiB sync  RPC:  0 conn, 51 req/s, 140 µs
2018-08-13 03:39:30 UTC Imported #4142115 0xb566…7098 (0 txs, 0.00 Mgas, 0 ms, 0.57 KiB)

We noticed that by increased number of alerts from our monitoring system, since transition to Syncing... results in /api/health endpoint going HTTP 412 Precondition failed.

@Tbaut
Copy link
Contributor

Tbaut commented Aug 13, 2018

Do I understand well that /api/health answers HTTP 412 Precondition failed every time the node is syncing?

@Tbaut Tbaut added Z1-question 🙋‍♀️ Issue is a question. Closer should answer. M6-rpcapi 📣 RPC API. labels Aug 13, 2018
@Tbaut Tbaut added this to the 2.1 milestone Aug 13, 2018
@phahulin
Copy link
Contributor Author

I guess that it reports HTTP 412 every time api health is not OK, including syncing
https://github.com/paritytech/parity-ethereum/blob/v1.11.8/dapps/src/api/api.rs#L85

What I'm seeing directly is that since upgrade to 1.11.8 from 1.10.6 we have a lot of alerts that node health is not ok. The first thing I see in logs is that nodes periodically go into syncing, esp. strange is when they try to sync a block they've already imported

@phahulin
Copy link
Contributor Author

Fresh example:

10:26:41 UTC

HTTP/1.1 412 Precondition Failed
{"Ok":{"peers":{"status":"ok","message":"","details":[45,50]},"sync":{"status":"needsAttention","message":"Your node is still syncing, the values you see might be outdated. Wait until it's fully synced.","details":true},"time":{"status":"ok","message":"","details":192}}}

From logs (server is in EDT):

2018-08-13 06:26:40  Imported #4146873 0xa515…3e01 (0 txs, 0.00 Mgas, 0 ms, 0.57 KiB)
2018-08-13 06:26:44  Syncing #4146873 0xa515…3e01     0 blk/s    0 tx/s   0 Mgas/s      0+    0 Qed  #4143623   45/50 peers      6 MiB chain   88 MiB db  0 bytes queue    2 MiB sync  RPC:  0 conn,  1 req/s,  75 µs

@phahulin
Copy link
Contributor Author

phahulin commented Aug 14, 2018

We downgraded nodes from one of public rpc pools to 1.10.6 and both the Syncing message in logs and alerts stopped there. Nodes from another pool running on 1.11.8 still have it.

@phahulin
Copy link
Contributor Author

Can this be upgraded to something other than "Z1-question"? I opened a few issues in the past week because we actually started to experience problems after transition 1.10.6 -> 1.11.8

@Tbaut
Copy link
Contributor

Tbaut commented Aug 14, 2018

Not entirely sure if this is a bug. We would need to know why the node is syncing. It could be due to a reorg.

@Tbaut Tbaut added M4-core ⛓ Core client code / Rust. and removed M6-rpcapi 📣 RPC API. labels Aug 14, 2018
@phahulin
Copy link
Contributor Author

How do I check for that? Reorg is usually accompanied by a corresponding message in logs:

2018-08-14 09:00:20 UTC Reorg to #4162684 0xd13d…0f56 (0x6f12…c0cc #4162683 0xa6ba…3577 )

And I see those messages still happen occasionally on 1.10.6, but I don't see Syncing messages anymore.

@andresilva
Copy link
Contributor

I think this is a duplicate of #9428 (or the other way around since this one is older). I'm looking into it.

@5chdn 5chdn modified the milestones: 2.1, 2.2 Sep 11, 2018
@andresilva
Copy link
Contributor

@phahulin This should be mostly fixed by #9552. It may still happen when ancient block import is running, since it may stall new block import and temporarily cause the node to go into syncing mode.

@5chdn 5chdn modified the milestones: 2.2, 2.3 Oct 29, 2018
@5chdn 5chdn modified the milestones: 2.3, 2.4 Jan 10, 2019
@jam10o-new
Copy link
Contributor

closing as stale and probably already fixed, @phahulin please let us know if that isn't the case

@jam10o-new jam10o-new added the Z3-stale 🍃 Issue is in principle valid, but it is not relevant anymore or can not reproduced. label Jan 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
M4-core ⛓ Core client code / Rust. Z1-question 🙋‍♀️ Issue is a question. Closer should answer. Z3-stale 🍃 Issue is in principle valid, but it is not relevant anymore or can not reproduced.
Projects
None yet
Development

No branches or pull requests

5 participants