-
Notifications
You must be signed in to change notification settings - Fork 444
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
Database disk image is malformed #5252
Comments
What should we do when the database is corrupt beyond repair? Remove it? |
In this case, we should mark the database corrupted and schedule a DB check on the next startup. Ideally, we should employ DB's own mechanisms for that. |
@ichorid do we want to fix this issue in 7.5? |
There were only 2 bugreports with this kind of bug in the last few months. One should put some real effort to garble their SQLite database to produce this kind of error. It is alson not trivial to recover from it later. I would mark it a low-priority and moved to backlog. |
On our (Proxmoxed) Mac, I now have a corrupt
I will save this database image. |
Adding one more stack trace from the error reporter for this issue Traceback (most recent call last):
File "src\tribler-gui\tribler_gui\core_manager.py", line 68, in on_core_finished
RuntimeError: The Tribler core has unexpectedly finished with exit code -1073741819 and status: 1!
[PID:7780] 2020-10-22 00:24:14,067 - ERROR <taskmanager:135> RemoteQueryCommunity.done_cb(): Task resulted in error: database disk image is malformed
Traceback (most recent call last):
File "lib\site-packages\pony\orm\dbapiprovider.py", line 55, in wrap_dbapi_exceptions
File "lib\site-packages\pony\orm\dbapiprovider.py", line 279, in execute
sqlite3.DatabaseError: database disk image is malformed
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "ipv8\taskmanager.py", line 131, in done_cb
File "src\tribler-core\tribler_core\modules\metadata_store\community\remote_query_community.py", line 149, in on_remote_select_response
File "src\tribler-core\tribler_core\modules\metadata_store\store.py", line 287, in process_compressed_mdblob_threaded
File "lib\concurrent\futures\thread.py", line 57, in run
File "src\tribler-core\tribler_core\modules\metadata_store\store.py", line 278, in _process_blob
File "lib\site-packages\pony\orm\core.py", line 476, in __exit__
File "lib\site-packages\pony\orm\core.py", line 490, in _commit_or_rollback
File "lib\site-packages\pony\orm\core.py", line 381, in commit
File "lib\site-packages\pony\orm\core.py", line 370, in rollback_and_reraise
File "lib\site-packages\pony\utils\utils.py", line 95, in reraise
File "lib\site-packages\pony\orm\core.py", line 379, in commit
File "lib\site-packages\pony\orm\core.py", line 1896, in flush
File "lib\site-packages\pony\orm\core.py", line 5421, in _save_
File "lib\site-packages\pony\orm\core.py", line 5330, in _save_updated_
File "lib\site-packages\pony\orm\core.py", line 949, in _exec_sql
File "lib\site-packages\pony\orm\core.py", line 1784, in reconnect
File "lib\site-packages\pony\utils\utils.py", line 95, in reraise
File "lib\site-packages\pony\orm\core.py", line 947, in _exec_sql
File "<string>", line 2, in execute
File "lib\site-packages\pony\orm\dbapiprovider.py", line 74, in wrap_dbapi_exceptions
pony.orm.dbapiprovider.DatabaseError: database disk image is malformed
(Timestamp: 1603293855257, traceback timestamp: 1603293854068) |
Most probably, DB corruption is a result of interrupted/crashed DB upgrade/conversion procedure. Safety measures are disabled doing DB upgrade for speed. |
Sentry issue: TRIBLER-3 |
I'll try fixing it for 7.6. @devos50 , could you please send me the corrupted DB if it is not that big? |
@ichorid it seems that I saved that database on our server named "proxmox" and on the VM with ID 105. You can find the corrupt metadata database in the following path: |
Related error, a user commented: "Even with the tribler update, tribler keeps crashing on my Mac with this error message. It has been this way for the past 4 months and the releases from then. Thanks." |
thanks for suggestion, @sentry-for-tribler bot! 😉 Jokes aside, I'm going to add a subsystem to schedule a DB check after this kind of crashes. |
Got the same issue today when my Mac mini unexpectedly rebooted:
I am unsure which db file is "bad", in ~/.Tribler/7.5/sqlite I have the following two db files from today:
Thanks. |
@rgoshko , thanks for reporting! It is caused by You can try to recover it by creating a dump. Or just delete it (but you will lose your personal channel). We will add a procedure to handle this kind of failures in 7.6. |
Thanks @ichorid , I removed the |
Sentry issue: TRIBLER-2F |
Sentry issue: TRIBLER-55 |
related to #1993 |
Sentry issue: TRIBLER-9T |
Sentry issue: TRIBLER-A7 |
Sentry issue: TRIBLER-AE |
7.11: |
Sentry issue: TRIBLER-DH |
Sentry issue: TRIBLER-11R |
Sentry issue: TRIBLER-15F |
Sentry issue: TRIBLER-15Y |
Sentry issue: TRIBLER-15X |
Sentry issue: TRIBLER-15Q |
Sentry issue: TRIBLER-1EF |
Sentry issue: TRIBLER-1F3 |
Sentry issue: TRIBLER-1F2 |
Sentry issue: TRIBLER-1FE |
Fixed in #7628 |
From the error reporter (7.5.0-RC2):
Related to #1993
The text was updated successfully, but these errors were encountered: