-
Notifications
You must be signed in to change notification settings - Fork 451
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The Tribler core becomes unresponsive when running with a large metadata store #5578
Comments
@synctext , we need your laptop to reproduce this. |
In-depth reproduction:
diff --git a/src/tribler-core/tribler_core/session.py b/src/tribler-core/tribler_core/session.py
index dcafe99aa..ca5161843 100644
--- a/src/tribler-core/tribler_core/session.py
+++ b/src/tribler-core/tribler_core/session.py
@@ -415,7 +415,8 @@ class Session(TaskManager):
channels_dir = self.config.get_chant_channels_dir()
metadata_db_name = 'metadata.db' if not self.config.get_chant_testnet() else 'metadata_testnet.db'
database_path = self.config.get_state_dir() / 'sqlite' / metadata_db_name
- self.mds = MetadataStore(database_path, channels_dir, self.trustchain_keypair)
+ import pathlib
+ self.mds = MetadataStore(pathlib.Path('/media/quinten/USB DISK/tribler_metadata/metadata.db'), channels_dir, self.trustchain_keypair)
# IPv8
if self.config.get_ipv8_enabled():
|
🤦 |
The only way to guarantee that the metadata store will work even on very slow 🐌 media, is to implement an asynchronous priority queue. We already have a ticket for this: #4320 |
@synctext , do you really run Tribler on a thumb drive? If you do, what's your opinion, should we keep it as a blocker, and thus prioritize making Tribler run on extremely slow storage media? |
no, my Linux box is SSD storage with fast i7. |
@synctext , if you really can reproduce it every time, the only way I can debug it is to connect remotely to the machine that shows the problem. |
Also related to #5208 |
This still smells like an I/O issue to me. Even SSDs can have bad performance, for instance https://haydenjames.io/linux-server-performance-disk-io-slowing-application/ :
@synctext could you provide any sort of insight (for example by following the tutorial on the linked webpage) that your disk is still O.K.? |
Its not my laptop, it's Tribler :-)
|
@synctext That's one big write, I'm more interested in performance for many small ones (for instance many small commits to an SQL database).
If that doesn't bring down your disk to +- 20 MB/S or worse, it's in the clear. |
Ahhh, good to check. My SSD has quite bad performance for small fragments. Almost like hard-disk seek times.
|
@synctext Well there's the problem, that's even slower than my thumbdrive. Now how to improve that.. I don't know :) |
Ok, let's try to get a satisfactory resolution for this issue. On the software mitigation front:
On the hardware front, one (or more) of the following may be at play:
On the software front, these are very invasive changes that need proper testing and these have been--rightfully--postponed to |
Agreed. This 3-minute blocking behaviour has not been reproduced or been easily traced to a bug; so lets leave this for My Ubuntu box has decent performance, just not if you force dd to use synchronized I/O. Further improving our async IO is obviously on our ToDo list, once we have a dashboard and PopularityCommunity progress.
The Web docs: |
Great item for ToDo list, @devos50 So maximum stress test:
|
@kozlovsky basically solved this by some SQL magic |
Has this been tested with the notorious |
@synctext noticed that when running Tribler with a large metadata store, Tribler becomes slow and occasionally unresponsive. For example, search queries can take several minutes to return results. I have tested Tribler with his state directory, but was unable to reproduce this on my Mac.
We could try to integrate this state directory with the application tester, and monitor the response times of requests.
I can share the state directory on request.
The text was updated successfully, but these errors were encountered: