WalletWasabi / WalletWasabi

Open-source, non-custodial, privacy preserving Bitcoin wallet for Windows, Linux, and Mac.
https://wasabiwallet.io
MIT License
2.13k stars 497 forks source link

Wasabi wallet not loading - P2pBlockProvider (290) #3668

Closed satyruszeno closed 4 years ago

satyruszeno commented 4 years ago

General Description

After performing some coinjoins and closing Wasabi, i can't open my wallet anymore.

I've restore this wallet, but the restored wallet still with the same problem.

Other wallets opens fine.

How To Reproduce?

  1. Start ./wassabee with default configuration
  2. Try to open my Wallet

Screenshots

image

Operating System

Manjaro 20.0

Logs

2020-05-16 08:00:46 INFO Program (43) Wasabi GUI started (47e541y7-72bc-4b3f-97ec-34345a4c718x).

2020-05-16 08:00:53 INFO Global (396) AddressManager did not exist at /home/zeno/.walletwasabi/client/AddressManager/AddressManagerMain.dat. Initializing new one.

2020-05-16 08:00:53 INFO TransactionStore (29) MempoolStore.InitializeAsync finished in 174 milliseconds.

2020-05-16 08:00:53 INFO TransactionStore (29) ConfirmedStore.InitializeAsync finished in 147 milliseconds.

2020-05-16 08:00:53 INFO TorProcessManager (251) Starting Tor monitor...

2020-05-16 08:00:53 INFO Global (168) TorProcessManager is initialized.

2020-05-16 08:00:53 INFO AllTransactionStore (28) InitializeAsync finished in 236 milliseconds.

2020-05-16 08:00:53 INFO TorProcessManager (75) Tor is already running.

2020-05-16 08:01:18 INFO IndexStore (45) InitializeAsync finished in 25 seconds.

2020-05-16 08:01:18 INFO BitcoinStore (39) InitializeAsync finished in 25 seconds.

2020-05-16 08:01:18 INFO HostedServices (51) Started Software Update Checker.

2020-05-16 08:01:19 INFO Global (290) Start connecting to nodes...

2020-05-16 08:01:19 INFO Global (314) Start synchronizing filters...

2020-05-16 08:01:39 INFO ClientState (470) Round (21239) added.

2020-05-16 08:01:39 INFO ClientState (470) Round (21240) added.

2020-05-16 08:01:39 INFO WalletManager (192) Starting Wallet...

2020-05-16 08:01:39 INFO CoinJoinClient (133) CoinJoinClient is successfully initialized.

2020-05-16 08:01:47 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:e47:27c5:3f4x:87d2:f6b4, because block download failed: Not loaded! Use LoadAsync() first!.

2020-05-16 08:01:55 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:790a:dcc9:73:5a5x:11d1, because block download failed: Not loaded! Use LoadAsync() first!.

2020-05-16 08:02:06 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:9d2c:9fa6:9c9x:bbbe:75e6, because block download failed: Not loaded! Use LoadAsync() first!.

2020-05-16 08:02:10 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:9d2c:9fa6:9c9x:bbbe:75e6, because block download failed: Not loaded! Use LoadAsync() first!.

2020-05-16 08:02:13 WARNING Global (145) Process was signaled for killing.

Wasabi Version

2020-05-17 09:07:05 INFO WalletManager (30) .ctor finished in 1 seconds. 2020-05-17 09:07:05 INFO Global (79) .ctor finished in 3 seconds. Wasabi Client Version: 1.1.11.1 Compatible Coordinator Version: 3 Compatible Bitcoin Core and Bitcoin Knots Versions: 0.19.1 Compatible Hardware Wallet Interface Version: 1.1.0

MaxHillebrand commented 4 years ago

You are not connecting to Bitcoin peers / nodes, and thus cannot download the blocks.

Are you connected to your own full node?

satyruszeno commented 4 years ago

You are not connecting to Bitcoin peers / nodes, and thus cannot download the blocks.

Are you connected to your own full node?

Hi MaxHillebrand,

Thank you for your reply.

No. I'm using all Wasabi default configuration. I've just downloaded, extracted the folder, and ran it.

yahiheb commented 4 years ago

Have you tried to turn off Tor in the settings and see if you can connect to peers?

satyruszeno commented 4 years ago

Have you tried to turn off Tor in the settings and see if you can connect to peers?

Hi yahiheb,

Thank you for your reply.

Yes, I've tried it early. Problem persists.

Looking at TorLogs.txt, I see a warning, could be it?:

May 17 06:53:58.000 [warn] Bad element "$22404A3E87F2D7FE2FC6359F@last-listed" while parsing a node family. May 17 06:53:58.000 [warn] Bad element "2020-05-16" while parsing a node family. May 17 06:53:58.000 [warn] Bad element "20:44:14" while parsing a node family. May 17 06:53:58.000 [notice] Starting with guard context "default" May 17 06:54:00.000 [notice] Bootstrapped 5% (conn): Connecting to a relay May 17 06:54:00.000 [notice] Bootstrapped 10% (conn_done): Connected to a relay May 17 06:54:00.000 [notice] Bootstrapped 14% (handshake): Handshaking with a relay May 17 06:54:01.000 [notice] Bootstrapped 15% (handshake_done): Handshake with a relay done May 17 06:54:01.000 [notice] Bootstrapped 75% (enough_dirinfo): Loaded enough directory info to build circuits May 17 06:54:01.000 [notice] Bootstrapped 90% (ap_handshake_done): Handshake finished with a relay to build circuits May 17 06:54:01.000 [notice] Bootstrapped 95% (circuit_create): Establishing a Tor circuit May 17 06:54:03.000 [notice] Bootstrapped 100% (done): Done May 17 06:55:22.000 [notice] Interrupt: exiting cleanly.

satyruszeno commented 4 years ago

Have you tried to turn off Tor in the settings and see if you can connect to peers?

To be more clear, when I start Wasabi, all connects perfectly.

image

When I try to access this specific wallet, it do not connect to Peers.

image

image

And the log reports the P2pBlockProvider (290) error:

2020-05-17 10:55:46 INFO WalletManager (192) Starting Wallet... 2020-05-17 10:55:47 INFO CoinJoinClient (133) CoinJoinClient is successfully initialized. 2020-05-17 10:55:56 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:ace2:74ca:6411:e035:667d, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:55:56 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:3aa0:7a1f:ce5f:e8ff:b841, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:55:56 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:e431:da4b:7a9d:ee2:e2c0, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:55:56 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:990:9f7b:dca6:f20:a54f, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:55:56 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:7dea:a4bf:d228:745f:95c4, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:55:58 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:c444:43a:1184:4767:2a13, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:56:03 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:e431:da4b:7a9d:ee2:e2c0, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:56:09 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:3396:4ad7:c0:e43a:52da, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 10:56:13 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:3aa0:7a1f:ce5f:e8ff:b841, because block download failed: Not loaded! Use LoadAsync() first!.

MaxHillebrand commented 4 years ago

This is odd... in https://github.com/zkSNACKs/WalletWasabi/pull/3573, @lontivero implemented that there are a minimum of two peers left, and that these two are not disconnected even if block download fails. AFAIK, this made it in the v1.1.11.1 release which you are running...

And since tor is running / the error persists when tor is turned off, then this is no tor issue neither...

Could you please try to build the source code and see if it is fixed?

yahiheb commented 4 years ago

When I try to access this specific wallet, it do not connect to Peers.

You mean when you load that specific wallet the number of peers drops to 0? If you are using v1.1.11.1 this shouldn't happen.

satyruszeno commented 4 years ago

This is odd... in #3573, @lontivero implemented that there are a minimum of two peers left, and that these two are not disconnected even if block download fails. AFAIK, this made it in the v1.1.11.1 release which you are running...

And since tor is running / the error persists when tor is turned off, then this is no tor issue neither...

Could you please try to build the source code and see if it is fixed?

I'll try it now. I've got some questions:

I need to delete any folder before build the source code or it will overwrite the files? I need to save any file before it?

satyruszeno commented 4 years ago

When I try to access this specific wallet, it do not connect to Peers.

You mean when you load that specific wallet the number of peers drops to 0? If you are using v1.1.11.1 this shouldn't happen.

Exactly. I've tried to restore this specific wallet, making (wallet 02), but the problem persists.

Wallet 1 opens normal though (it's empty).

yahiheb commented 4 years ago

I am not sure if you are doing this but you can try:

satyruszeno commented 4 years ago

I am not sure if you are doing this but you can try:

* Open Wasabi and keep it running for a while (until you get some peers like 8 or more)

* Load your wallet and see if it peers drop to 0.

I've waited till 12, but after selecting my wallet, it dropped to 0:

Before: image

After: image

MaxHillebrand commented 4 years ago

you download the source code, and then execute the command from the wallet GUI folder. It doesn't mess with the already existing install of the tar file.

~/WalletWasabi/WalletWasabi.Gui$ dotnet run

satyruszeno commented 4 years ago

you download the source code, and then execute the command from the wallet GUI folder. It doesn't mess with the already existing install of the tar file.

~/WalletWasabi/WalletWasabi.Gui$ dotnet run

Did it. Same error, new messages:

2020-05-17 12:53:59 DEBUG P2pBlockProvider (128) System.InvalidOperationException: Not loaded! Use LoadAsync() first! at WalletWasabi.Helpers.RuntimeParams.get_Instance() in /home/zeno/WalletWasabi/WalletWasabi/Helpers/RuntimeParams.cs:line 35 at WalletWasabi.Wallets.P2pBlockProvider.GetBlockAsync(uint256 hash, CancellationToken cancellationToken) in /home/zeno/WalletWasabi/WalletWasabi/Wallets/P2pBlockProvider.cs:line 102 2020-05-17 12:53:59 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:4607:2b33:74cc:e037:be2f, because block download failed: Not loaded! Use LoadAsync() first!. 2020-05-17 12:54:25 WARNING Program (80) System.AggregateException: A Task's exception(s) were not observed either by Waiting on the Task or accessing its Exception property. As a result, the unobserved exception was rethrown by the finalizer thread. (The peer has been disconnected) ---> System.OperationCanceledException: The peer has been disconnected --- End of inner exception stack trace ---


RuntimeParams.cs: line 35 from error:

image

P2pBlockProvider.cs: line 102 from error:

image

satyruszeno commented 4 years ago

Reading the Wasabi documentation, I've found something interesting.

Before my wallet stopped working there were a spent coin status. After closing the wallet i've got this issue. According to Wasabi "The spent coin status is a symptom of corrupted wallet state. [...] It ultimately got fixed in v1.1.10 by introducing an upgraded version of BIP 158 block filters and changing the wallet cache architecture."

https://docs.wasabiwallet.io/FAQ/FAQ-UseWasabi.html#what-does-spent-coin-status-mean

lontivero commented 4 years ago

This following error message suggests that your ~/.walletwasabi/client/RuntimeParams.json is corrupted.

2020-05-16 08:01:47 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:e47:27c5:3f4x:87d2:f6b4, because block download failed: Not loaded! Use LoadAsync() first!.

Please delete the file and try again.

satyruszeno commented 4 years ago

This following error message suggests that your ~/.walletwasabi/client/RuntimeParams.json is corrupted.

2020-05-16 08:01:47 INFO P2pBlockProvider (290) Disconnected node: fd87:d87e:eb43:e47:27c5:3f4x:87d2:f6b4, because block download failed: Not loaded! Use LoadAsync() first!.

Please delete the file and try again.

Nailed it! Problem solved!

Thank you so much @lontivero, @MaxHillebrand and @yahiheb!