-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Parity burning CPU. #6300
Comments
Actually, in general doing anything in the UI seems to peg my CPU for a while and all of my interactions are really delayed. For example, I just went to execute a contract method. While I was filling in the parameters the UI was pegged (not sure what it was doing). Then when I clicked to send the UI pegged for a while and I had to wait a non-trivial amount of time for the signer to appear. Then the CPU pegged again once I signed. I don't remember experiencing all of these issues with Parity 1.6.x. |
Could you do me a favor and check your logs while you are using the UI? Does the number of RPC requests increase significantly after opening the UI? |
After a lot more trial and error and troubleshooting with @tomusdrw I found that rolling back to 1.6.10 did not resolve the issue (including a full chain re-sync since that was required with rollback), and deleting chain and 1.6.10 then installing 1.7.0 and fully syncing also didn't resolve the issue. I also found that it wasn't just a problem when the UI was open, though the UI being open did exacerbate the problem and this appears to be caused by having multiple detached hardware wallets (wiping out my accounts and creating a new single normal account made the UI less impactful when clicking around.
This problem appears to have started after upgrading from 1.6.x to 1.7.0, but unfortunately nothing I did was able to get my computer back into a healthy state (other than While in this pathologically bad state, My I/O is crazy high, ~100MB/s average (very spiky). The following screenshot is just |
@5chdn I suspect the tags are wrong, since it turns out this isn't specifically related to the UI. I can edit the description (or you can) if you like to make it more clear what the issue is about. |
You are describing multiple issues here.
Does this sum it up correctly? Edit, also one of the more recent perfomance issues might be related #6280 |
I'm not sure if (3) is unrelated or related, the disk IO didn't bother me but it stood out when I went investigating the CPU burn. Unfortunately, after running Parity all day today with |
@MicahZoltu does the problem persist once ancient block download is complete? I actually do expect that ancient block download will lead to high CPU usage, since ethash verification of the header chain is still required. The heavy I/O usage is also because ancient block headers, bodies, and receipts are being written to disk, and the spikes are likely rocksdb compaction. This is something which should be alleviated when block pruning is implemented. Out of curiosity, how well is your node keeping up with the head of the chain? It could be that the latest blocks are heavy enough to lead your computer to struggle. |
@rphmeier I had previously been running my node locally for months, maintaining sync and without the I don't notice problems falling behind on block processing when blocks arrive during normal operation, though when it is running at 100% CPU (to the point where other applications on my computer stop behaving correctly) I have seen it fall behind. When Parity is just burning 90% of my CPU for hours on end though, it doesn't fall behind. |
As a minor update, its now a day later and Parity is still running at 100% CPU (default flags at the moment and has been for a while). I have been turning it off periodically so I can actually use my computer, but I try to leave it running overnight at least and when I am doing non-CPU intensive things. Of course, Parity itself has become largely unusable but I would really like to resolve this issue. Please let me know if there is additional troubleshooting I can do. I recognize that without a repro case it is likely difficult for you all to fix this and since I would like Parity to work again for me I am willing to try to help troubleshoot. |
In a desperate attempt to resolve this issue I bought a new computer (Dell XPS 9650). After fully syncing the chain (see #6372) it is back to burning way more CPU than I would expect while not doing any meaningful work (just keeping up with new blocks). I have no accounts or contracts, outside of one account I created to satisfy the wizard. I have done no customization of Parity or anything notable to this computer (Windows 10 Pro, Docker, Node, Chrome). According to process explorer, it is burning ~15% (10%-30% range) of CPU at all times while in "keep the chain synced mode". Disk IO ranges from 10MB/s to 150MB/sec. Changing the mode to "wake to sync" doesn't appear to noticeably change the utilization profile. Here is a utilization graph of just With the problem reproducing on a brand new computer, I have concluded that its not just a problem with my setup/computer/install or a problem with my usage of Parity (accounts, contracts, etc.). The problem isn't as bad on this new computer as it was on the previous one, but I would expect lower background utilization than I'm seeing on a modern computer. |
After many more hours of sitting idle on the computer, it appears to have calmed down to acceptable levels. Perhaps the issue is simply that the UI doesn't give enough information about what is happening (both for troubleshooting, and to make me not freak out)? Presumably, something changed over the past few hours but the UI gives me no indication that it is in any different of a state now than it was several hours ago. Previously it has been mentioned that there was some process that occurs after a sync, on my new computer I suspect that was probably the case. Is there an issue to have the UI convey this information to the user? If not, should I create one? Note: Parity is still completely unusable on my original computer. |
🤣
Go to the status tab, scroll to the bottom and follow the logs by clicking the play button. After a warp sync it fetches ancient blocks, this process takes several hours and fits very well your description above. |
@MicahZoltu After the initial warp sync is complete there's a background process that downloads and validates historical blocks. This process takes a few hours and is CPU demanding. Currently there's progress indication in the console output/logs, but not in the UI. |
I'm tempted to close this as working as desired. This is not really a Parity issue but an Ethereum issue. Your client is processing 400k transactions per day currently, even if it's not sync'ing, that's 5 per second. Regarding the high IO, there is room for optimization regarding the database layer, but there is a separate ticket open. #6280 #6020 Regarding the accounts and dapps issue, that's something we are aware of. #6387 |
@5chdn I won't fight closure of this issue since it doesn't seem like anyone has any ideas for what I can do to further troubleshoot, but I would argue pretty strongly that "working as intended" is not correct (perhaps could-not-reproduce instead?). When I say Parity is burning CPU, I mean 100% CPU 24/7. My computer is unusable, to the point where the OS itself even locks up sometimes (I thought Windows had solved this and made it so the OS always had priority, I'm guessing it is the IO that is blocking in the Kernel). On my new computer, Parity uses a medium amount of CPU initially while syncing and then archiving (~15%-30%), but then drops down to background idle of ~1% utilization (with UI closed). To me the behavior on my new computer is "working as intended" and the behavior on my old computer (which is only ~6 months old) is definitely not "working as intended". On my old computer I have have quit using Parity, and if it weren't for having just bought a new computer I would have switched to Geth or MetaMask or something (not sure what exactly). |
Yeah, I'm getting this pretty much and therefore referred to the open IO tickets. If you say it's not IO but CPU and your computer does that 24/7, I would have to ask you for logs to figure out what's going on (Status tab at the bottom). Could you also tell me, did you have a lot of accounts on your old computer? |
I have 5 accounts (I removed my hardware wallets), 2 addresses and 2 contracts. I used to have more, but I have deleted most of them to try to troubleshoot. I have previously watched the logs when in this state and nothing appears out of the ordinary. Is there a way in the UI to get more detailed logs than the default? I'll turn Parity back on on the old computer with log capture enabled and post the logs here (I don't expect anything though based on my past experience). |
Things were actually looking healthy for a bit, then around 1:42 CPU jumped to 100% for 4.5 minutes, finally stabilizing at ~1:44:30.
|
Logs are looking good. I'm pretty sure the issues you are describing is related to #6387. We are preparing a fix currently. I would like you to stay tuned for the patch to test it on your machine. |
I don't know if related, but when I have the parity signer extension open, my parity 1.7 parity.exe CPU usage shoots to 100% with small drops down to 50% but mostly staying at 100%. This occurs until I close the signer. |
I don't use the signer extension so that isn't the same symptoms as I have, though perhaps similar root cause? |
Before filing a new issue, please provide the following information.
Your issue description goes here below. Try to include actual vs. expected behavior and steps to reproduce the issue.
When I open the Parity UI, the CPU pegs for several seconds. If I close the UI and open it again (without restarting Parity) the CPU pegs again. The same symptoms occur if I open any dApp with the Parity extension active or via the Parity browser.
The exact amount of time the CPU burns for varies, but it can be up to 30 seconds.
For the dApps, I can appreciate that some may be doing a ton of log scanning which causes the problem but I would expect opening the
Home
page of the the UI to require nothing but a few account state lookups (I have ~6 accounts).The text was updated successfully, but these errors were encountered: