View Single Post
Old 12-08-2016, 12:33 PM   #1
EightWeight
Enthusiast
EightWeight began at the beginning.
 
EightWeight's Avatar
 
Posts: 35
Karma: 12
Join Date: Dec 2011
Device: Kindle4, PW
Restore/recreate Calibre database

I have been trying to restore the database of my Calibre library. Calibre reported it corrupt and offered to recover it. It went all the way through the list of books (about 1200) and at the very end threw this error:

calibre, version 2.73.0
ERROR: Failed to repair library: Restoring database failed, click Show details to see details

Traceback (most recent call last):
File "site-packages/calibre/db/restore.py", line 123, in run
File "site-packages/calibre/db/restore.py", line 239, in create_cc_metadata
File "site-packages/calibre/db/restore.py", line 29, in __init__
File "site-packages/calibre/db/backend.py", line 370, in __init__
File "site-packages/calibre/db/backend.py", line 1117, in initialize_database
File "src/cursor.c", line 231, in resetcursor
IOError: IOError: disk I/O error

After acknowledging this error Calibre asks me to choose a library. After I choose one it throws this error:

calibre, version 2.73.0
ERROR: Bad database location: Bad database location u'/run/user/1000/gvfs/smb-share:server=stratus,share=books_music/Books'. calibre will now quit.

Traceback (most recent call last):
File "site-packages/calibre/gui2/main.py", line 275, in initialize_db_stage2
File "site-packages/calibre/db/legacy.py", line 76, in __init__
File "site-packages/calibre/db/legacy.py", line 48, in create_backend
File "site-packages/calibre/db/backend.py", line 369, in __init__
File "site-packages/calibre/db/backend.py", line 1100, in fget
File "site-packages/calibre/db/backend.py", line 813, in conn
File "site-packages/calibre/db/backend.py", line 263, in __init__
CantOpenError: CantOpenError: unable to open database file

What is the u' before /run/user/.... ? and what else can I do to attempt a restore?

BTW calibredb restore_database -r does not work either.
EightWeight is offline   Reply With Quote