+
Skip to content
This repository was archived by the owner on Jun 4, 2025. It is now read-only.
This repository was archived by the owner on Jun 4, 2025. It is now read-only.

Pools sometimes reporting unexpected state #534

@kbs1

Description

@kbs1

When there are fewer and fewer nodes in the network (as is happening now), the pools often like to report their state as "Trying to connect to the main network". When in reality, they are synced.

Main blocks match, difficulty also matches, and is the same on other nodes that report "normal operation" at that time.

On xdag.org, we have implemented a debug feature called "difficulties sync", which overrides reported pool state to normal operation if:

  1. the pool is NOT loading blocks from local storage
  2. simulate desync (another debug feature of ours) is disabled
  3. the difficulties match
  4. number of main blocks match

The problem is I had to replicate these changes in XDAG explorer (only quick patch on node - not in github code), as it reports it's "synchronizing" any time the node enters the "Trying to connect to to the main network" state.

This state tends to last for about 3 minutes. Then the node switches to "synchronizing", followed by "normal operation". Then the cycle may trigger again without any apparent reason.

The whole time this is happening, the node

  1. is synchronized
  2. the CPU or disk is not very much utilized
  3. difficulties match with other nodes reporting as synchronized
  4. number of main blocks match
  5. there are active nodes in "net conn" output, and the packets / bytes counters are increasing all the time, and dropped packets stay constant (almost always 0)

I would like to not keep the "difficulties sync" override of pool state in XDAG explorer for very long. The check isn't the cleanest, and doesn't really protect in cases where the node would really get disconnected from the main network.

In that case, the difficulties would also still match, main blocks would also match, as it would be the only node in the network. And since the block explorer must be correct, this "override" is not very suitable for the project.

Without the override, we had frequent "block explorer is currently synchronizing" error pages as the node reported an unexpected daemon state.

Thank you! :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载