bisq-network / bisq

A decentralized bitcoin exchange network
https://bisq.network
GNU Affero General Public License v3.0
4.7k stars 1.26k forks source link

100% CPU (constant high cpu) in v1.1.1 #2856

Closed microlancer closed 5 years ago

microlancer commented 5 years ago

Not sure if related to #294 or #555 but I'm seeing 100% cpu for hours and hours without end. I'm running v1.1.1 and I have one trade open.

Screenshot from 2019-05-30 07-34-23

I'm seeing the "Synchronizing DAO" activity bar spinning forever as well, not sure if it's related.

This 100% CPU is really heating up my hardware, and fans are going max speed all day.

ghost commented 5 years ago

My experience is that if the sync doesn't realize in 2/3 minutes, then the best is to restart the appli.

If restarting doesn't help, please have a look at the concerned part of the concerned logfile, and upload it here. So it could provide some info about what is occuring.

ripcurlx commented 5 years ago

We are planning to release a new version (1.1.2) next week which should help with the DAO sync issue. Fingers crossed, that it will also fix your problem.

sqrrm commented 5 years ago

@thorie7912 Did you see an improvement with the new release? If so, please close this issue.

microlancer commented 5 years ago

I did not see an improvement. It's running now and still at 100% CPU. v1.1.2

a123b commented 5 years ago

I've encountered this too in v1.1.2 while trading BSQ. When it happens and you go to the BSQ wallet's transaction list, the whole app gets incredibly laggy until you switch to another screen (green bar animation gets very choppy, if you click on something it can take a few seconds for something to happen etc.)

If the sync doesn't finish within 1-2 minutes of starting the app, it will never finish and you have to restart the app. Don't know if it was a coincidence, but every time it happened to me I had started Bisq with limited heap size (-Xmx512M). Without that memory limit, I never faced this problem.

sqrrm commented 5 years ago

Bisq is fairly greedy with memory, best to give more if possible.

I thought the DAO syncing issue would've been resolved but apparently it's still a problem.

ghost commented 5 years ago

@thorie7912 , What is your OS ? and how much RAM has your computer ? Maybe with not enough RAM the computer uses all of its time to swap to the disk.

microlancer commented 5 years ago

I monitor my ram/swap usage often, and I have 16 GB with usage ~40-50% most of the time. It should be enough. I'm running Ubuntu 18.04.

ghost commented 5 years ago

@thorie7912 , You may have a look at your sys log files. In linux it's at /var/log. You can only look in admin mode. There you may get some information on why Bisq eats so much CPU.

a123b commented 5 years ago

I doubt you'll find anything related to high CPU usage of a Java app in the system logs... Running Bisq with a CPU profiler would probably be very helpful.

microlancer commented 5 years ago

Any tips on how to run a CPU profiler? I recall doing some jvm-debug stuff a long time ago.

a123b commented 5 years ago

I just tried attaching to Bisq in VisualVM just for fun. @thorie7912 here's how I did it:

I attached the CPU profiler right after starting Bisq, before I entered the wallet password. After a while I switched to the BSQ wallet transactions list where the app eventually became completely unresponsive while using 100% CPU. I stopped the profiling then, but the app was still unresponsive. Then I decided to profile another minute of this hanging state. Here are the saved snapshots: bisq-cpu-profiling-snapshots-a123b.zip

Some observations:

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] commented 5 years ago

This issue has been automatically closed because of inactivity. Feel free to reopen it if you think it is still relevant.

spogulis commented 4 years ago

The issue is still relevant. Downloaded a new installation of Bisq on new hardware and, while the DAO is synchronizing, hardware usage is as following: CPU - 20 to 40% RAM - ~4GB of 16 Network - pretty much maxed out at 25 MB/s.

It bogs down the whole system (i7, 1060GTX), so this should be looked into.

da-kami commented 3 years ago

Similar problems here. Running on macOS Catalina CPU between 100% and 125% (on Quadcore)

It shows:

image

Due to CPU usage UI lags heavily, almost not usable.

ripcurlx commented 3 years ago

@da-kami Do you see the same CPU usage after the DAO finished synchronizing as well?