06-17-2011, 11:10 PM | #1 |
Member
Posts: 23
Karma: 10
Join Date: Jul 2010
Device: Nook
|
Library disappeared?
I just recently moved my library to a new directory to keep my books more organized. After I moved the library, all the files were in the designated folder but being the neat freak I am I renamed the folder. Afterwards, all my books don't show up in calibre, however, all the files are still in the folder. I tried to restore my database through calibre library options but I get the message:
calibre, version 0.8.6 ERROR: Failed: Restoring database failed, click Show details to see details Traceback (most recent call last): File "site-packages\calibre\library\restore.py", line 102, in run File "site-packages\calibre\library\restore.py", line 187, in create_cc_metadata File "site-packages\calibre\library\database2.py", line 189, in __init__ File "site-packages\calibre\library\database2.py", line 138, in connect ValueError: Path to library too long. Must be less than 75 characters. |
06-17-2011, 11:36 PM | #2 | |
Well trained by Cats
Posts: 29,809
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
https://www.mobileread.com/forums/sho...54&postcount=1 The only folder you can rename is the folder that contains all the 'author' folders and Metadata.db To recover from that change, you simply use the small arrow on the Library Icon and switch/Create to the new folder. If you tampered with the other folders and files: |
|
Advert | |
|
06-18-2011, 05:46 AM | #3 |
Grand Sorcerer
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
Make the path to your library folder shorter. Calibre will refuse to use the library in a folder (assuming that there is one) until the full name (from C: or whatever drive) of that folder is less than 75 characters.
|
06-18-2011, 12:31 PM | #4 |
Grand Sorcerer
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
More information: apparently restore_database can attempt to create a library with a path longer than the allowed maximum. This can happen on windows machines where the path to the temp folder is very long, perhaps caused by a very long user name. This problem has been fixed for the next release.
It isn't clear to me if this is the problem you are facing, and if so how to work around this problem in the short term. Probably the best approach is to ask calibre to "open an existing library at a new location" using the switch/create library (menu on the library toolbutton), since the library is probably still good. |
06-18-2011, 12:52 PM | #5 |
creator of calibre
Posts: 43,860
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
You can workaround it by setting the TEMP environment variable to some directory with a short path, but in the OPs case, the correct solution is to use switch to another library as chaley pointed out.
|
Advert | |
|
06-21-2011, 02:16 AM | #6 | |
Member
Posts: 23
Karma: 10
Join Date: Jul 2010
Device: Nook
|
@theducks: Yes, the only thing I changed was the name of the folder that contained my current library. However, after I changed the name of the folder all the books no longer appeared in calibre.
Quote:
Also, I don't understand why it is saying that the path needs to be shorter than 75 characters. Since the path is already less than 75 characters without me even moving the folder Last edited by itsmattxp; 06-21-2011 at 02:40 AM. |
|
06-21-2011, 09:17 AM | #7 |
Wizard
Posts: 4,812
Karma: 26912940
Join Date: Apr 2010
Device: sony PRS-T1 and T3, Kobo Mini and Aura HD, Tablet
|
Did you try renaming the folder back to it's original name?
Worst case you can make a new library and reimport your books and if you have the opf files it should give you all of your metadata. I am pretty sure it is the second option under add books that you use for this. I did it a few months back and it took only a couple of hours for 9984 books Helen |
06-21-2011, 10:13 AM | #8 | |
Well trained by Cats
Posts: 29,809
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
I recommend: DO NOT Re-Import. Library Maintenance: Restore database |
|
06-21-2011, 11:39 AM | #9 |
Member
Posts: 23
Karma: 10
Join Date: Jul 2010
Device: Nook
|
An OPF exists in each folder but when I try to restore the database, it won't let me because it says the path is more than 75 characters when it isn't.
|
06-21-2011, 11:51 AM | #10 | |
Well trained by Cats
Posts: 29,809
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
XP: "C:/documents and settings/<original username>/Documents/ is where you are really, looking at 'My Documents' Other 'trip-ups': use of International characters anywhere in the path name. Note my comment about 'original' username. I discovered (was on W7) that renaming a User leaves the folder (ought of sight , normally) with the original name (probably so as to not break all those stored shortcuts). |
|
06-21-2011, 11:58 AM | #11 | |
Member
Posts: 23
Karma: 10
Join Date: Jul 2010
Device: Nook
|
Quote:
|
|
06-21-2011, 12:04 PM | #12 | |
Well trained by Cats
Posts: 29,809
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
C:\Users\<username>\ mine is in Public on W7 |
|
06-21-2011, 12:07 PM | #13 |
Grand Sorcerer
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
Your problem is probably the one discussed in posts 4 and 5 -- the temp directory path is too long. Have you tried Kovid's suggestion of setting the TEMP environment variable before running restore?
Alternatively, you can wait until the end of the week for the next release, which allows a longer temporary file path name. |
06-21-2011, 12:11 PM | #14 | |
Member
Posts: 23
Karma: 10
Join Date: Jul 2010
Device: Nook
|
Quote:
Edit: Moved it to the public documents folder and it still doesn't work. Last edited by itsmattxp; 06-21-2011 at 01:05 PM. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Strange - Annotations disappeared, library and calibre find no books | samysam | Sony Reader | 1 | 12-08-2010 05:31 AM |
Collections disappeared | desertblues | Amazon Kindle | 6 | 09-20-2010 06:38 AM |
Please Help - My Entire Calibre Library Disappeared | Marcy | Calibre | 17 | 08-14-2010 09:56 AM |
All My Books Disappeared | mousetater | Calibre | 12 | 07-30-2010 03:13 PM |
Reader Library disappeared after upgrade | nikev | Sony Reader | 0 | 12-19-2009 11:33 PM |