Space Pool and my Chia Wallet

Not sure at what point this has happened but my Space Pool Total paid XCH is currently standing at 7.987211. I have a current total of 5 blocks found. So by my reckoning my Chis wallet should have a total of 7.987211 + (5 x 0.25) = 9.237211 XCH.
However in the Chia GIU if I look in the Farm page I have Block Rewards of 1.25 but in the Wallets page I have a Spendable Balance of 8.311767 XCH.
So as far as I can see I am short by 0.925 XCH in the Wallet.
So am I missing something somewhere.
I’m sure this calculation used to be correct.
I have just upgraded from V1.2.11 to V1.3.1. That seemed to go OK but did have to upgrade the Wallet before I could get it to sync.
Any clues to whether or not I am just going mad much appreciated.

Your Farm / Block Rewards represent luck you have and have nothing to do with any pool (including Space).

On the other hand, your Wallet / Spendable represent a sum of both your “luck” part and your daily farming (that depends on how big is your farm but the luck part is minimized by pool combined size).

Only, if you farm solo, the luck part is the same for both the .25XCH you see on the farm side and your 1.75XCH gained through farming / drawing a ticket with each submitted proof.

1 Like

All my plots are in the pool. I understand how the pool works and the pool tells me I have accumulated 7.98 XCH as my share of the blocks found by everyone else in the pool. I have won 5 blocks which is about what I would expect from my plot size of 195TiB. So from each of these 5 block wins I get 0.25XCH which makes a total of 1.25 XCH and this is shown in Chia GUI as my Block Rewards.
But the Wallet page of the GUI shows a Spendable Balance of 8.311 XCH.
I would have expected to see 7.98 + 1.25 = 9.23 XCH.
During this latest Dust Storm, my Wallet is receiving 2 or 3 2e-1XCH every minute. Does this cause problems with the Wallet?

How are you sure you won 5 blocks?
Also, I think not every block “found” gives rewards

Edit: never mind, I see that’s not the problem after reading better

Space Pool tells me the Date and Time of each of my Block wins. The last one was on the 26th Jan 2022. These appeared in the Chia GUI transactions.

Check the transactions from the pool I guess. And if it is less than it says, put the question to them

Sorry, I missed that. You are right, the total should be that 9.23XCH, assuming that all pool rewards went to the same wallet. So, is it possible that around the time you upgraded to v1.3.1, somehow your pool rewards are ending up at a different address? Can you use chiaexplorer to trace where the latest rewards are being directed? Or, maybe if you could watch your wallet, and check if it will be bumped, the next time you get rewards from Space pool?



It would appear that the Wallet transactions is missing everything from the 4th March 2022 to the 21st March 2022. And this includes the Dust Storm stuff of lots of 2e-12 as well as the Space Pool payouts.
This morning (23/03/2022) it all seems to be back on track and the Space Pool payout has appeared in my Wallet.
So it looks like the Chia upgrade from V1.2.11 to V1.3.1 has lost a chunk of data from the Wallet files.
When I did the upgrade, I did the manual upgrade of the database from the command line, but then found that the Node sync’d but the Wallet was stuck.
I looked in the config.yaml file and noticed that the wallet database path was still set to V1. Changed it to V2 and restarted the GUI and the Wallet sync’d.
Was this an erroneous move and was this the point when it corrupted?

Put the wallet database path in the .yaml file back to V1. Wallet now sync’s but no difference to the XCH in the Wallet. I think I can say that this is nothing to do with Space Pool, I have just lost all the transactions between the 4th and 23rd March. Don’t know where they would be stored or if they can be recovered. Worse things happening in the world at the moment than worrying about the loss of 0.9 XCH.

If Space Pool reports pay-outs in that period and you never changed the pay-outs address during this period, could you check the pay-outs address on xchscan.com to see if the pay-outs are logged in the blockchain? If the wallet doesn’t see those then this is a serious bug and please report your findings on the issues page of github https://github.com/Chia-Network/chia-blockchain/issues
Looks as if there’s others there with similar issues.

I have never changed any of the addresses. Everything is just bog standard with what you get when created.
xchscan.com does seem to show all the transactions. But all transactions during this period are missing from the wallets page in the Chia GUI and therefore don’t appear in the Spendable Balance.
What I don’t know is where all these transactions are stored. Is it in one of the Wallet databases? If so, which one?
And what would happen if I deleted this database and restarted the Chia GUI?
Would it rebuild from scratch or would I be in an even worse position?

Afaik the original wallet worked it’s way through the entire synced blockchain database to get all transactions aboard. The light wallet that’s now implemented from 1.3 on cuts some corners there, improving sync time by a lot but appearantly sometimes missing transactions due to circumstances not yet clear.

I think you can delete the wallet db and it will be recreated and resynced then, maybe with other/better results.

But hang on, i’ll try this on a test machine to be sure.

1 Like

Don’t think I have used the light wallet before, but maybe now with V1.3.1 that’s what is used by default.
So are we talking about the files in the wallet/db folder?
There is also a .sqlite-wal file in the mainnet/db folder, is this anything to do with it?

I just deleted the contents (two files) in the wallet/db directory (first stop chia of course).
Restarting chia creats new files and syncing commences from zero, but very quickly.
The former light wallet beta is indeed now the default wallet client in 1.3.0 and higher.

So you can do this and hopefully the ‘in client’ wallet will be complete…

1 Like

Well Done!. That fixed it. Took about 5-6 hours to recreate the Wallet but it is now showing the correct amount.

So this is what you don’t do when you upgrade from V1.2.11 to V1.3.1

After you have run the new installer and manually run the database upgrade, the Wallet will continue to Sync.
I thought it had stalled as the Sync number did not appear to be incrementing.
I closed the Chia GUI and set the wallet database_path in the .yaml file from V1 to V2.
Restarted the GUI and the Wallet sync’d after a couple of minutes.
At this point the wallet database was now missing the most recent 10% of all transactions.

Solution: Delete the wallet database in the wallet/db folder and rebuild.

3 Likes

I had this same wallet issue when I upgraded from 1.3.0 to 1.3.2 yesterday. And shutting down CHIA and deleting files from the wallet/db folder fixed it. It took only an hour or so for the wallet to fully sync and show all of my payouts from my pool.

Tip for those having this same issue: Don’t delete the files in wallet/db that are named “wallet_peers.” I had originally deleted all files in there (I made backups, of course) and then after I started CHIA, the Wallets screen kept switching every 1/2 second between “syncing” and “offline” and wouldn’t ever actually sync. Once I put those 2 “wallet_peers” files back in and restarted CHIA, it was able to sync in about an hour. So, you really only need to delete the files that start with “blockchain_wallet.” You can probably also delete any 0KB files in there. (I did, at any rate)

1 Like

After my update to 1.3.1 I made a manual db update. I did everytjing correct but in the end my wallet was 0.6 chia missing. I uninstalled chia deleted mainnet and every related file. After restart I reinstalled 1.3.1 and began synching from start. After 10 minutes my wallet was correct. !! Because new version 2 wallet sync is separated and very fast.
PS: In discord I have read a warning that 1.3.1 has a security bug so every 1.3.1 user should update to 1.3.2 ASAP.

Not sure, whether it is the case, but maybe if the wallet is not detecting a fully synced local blockchain db, it syncs from the network (and you can see on Wallet panel few extra peers). However, once the manual upgrade is done, it is switching to the local blockchain that is not yet fully synced, so it may be kind of confused as being almost synced, but not really (puts whatever records it has above what the local blockchain is as not really verified). Once the blockchain db finishes sync, the wallet will finish syncing, and it will show all XCH there are.

Another possibility is that wallet needs to sync from peers with v2 dbs, so initially cannot sync from the local db. Once blockchain db upgrade is done, it switches to the local node (again, visible in Wallet panel, as all those extra peers are gone, and the only one that stays is the local node). And as above, it needs to wait for the local blockchain to finish syncing, and takes few extra minutes to finish its own sync.

I have observed this behavior on three different nodes, where blockchain was updated to v2 while chia was stopped. Every time, there was a confusion at the end, as wallet was not right but the UI insisted that all syncing is done, and every time within about 10-20 minutes or so, all got back to normal.

So, maybe after the upgrade, when the UI shows that blockchain is good to go (synced), and wallet looks like synced, but is missing some XCH, it is beneficial to wait about 30 minutes to get the wallet to settle down. At least, that worked for me.

As far as that security fix (latest OpenSSL), I don’t think that this is a pressing issue. I think that the attack is really complicated (to affect the whole network), so all those kids in the basements will need to spend some time to get it working. Otherwise, that vulnerability was fixed on Mar 15 or so (in OpenSSL), and it it would be an easy thing to pull, we would already see the net space collapsing. This attack is really easy to pull on a single web server (or a webserver farm - think Google, any bank, or utility company), where one hostile box can send just a single requests that brings such server down. Targeting 200k chia nodes is a bit more complicated thing, but still doable (IMO). Also, this attack is harmless, as far as compromising wallet or anything else, as it is only causing software crash (no code injection, or any other exploit that would stay on the remote side).

My take is that whoever is doing the current dust storm (for 2 months already) could easily add a couple of more boxes to really produce a much bigger strain on the network. The activity of this attack is smaller by order of one/two magnitudes comparing to the one on November.