![]() |
#1 |
Banned
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 666
Karma: 1752814
Join Date: Jan 2008
Device: Sony Reader PRS-505 : Onyx Boox Max : Sony PRS-900 : Onyx Kepler Pro
|
Tips to speed up adding books?
So, I'm a somewhat new user of calibre and I'm currently using the command line to add books. I have quite a few and I understand that it isn't a good idea apparently to use tools like parallel to write multiple entries to the calibre db. I'm currently using a for loop that does a find on the available formats that calibre can import and after importing, deletes the file.
for I in `find . -type f -name "*.azw" -o -name "*.azw3" -o -name "*.azw4" -o -name "*.chm" -o -name "*.djvu" -o -name "*.rb" -o -name "*.snb" -o -name "*.tcr" -o -name "*.epub" -o -name "*.lit" -o -name "*.lrf" -o -name "*.mobi" -o -name "*.pdf" -o -name "*.rtf" -o -name "*.prc" -o -name "*.pdb" -o -name "*.txt" -o -name "*.doc"` ; do calibredb add --duplicates "$I" && rm -v "$I"; done So, this works fine but I was wondering if anyone had done anything interesting to either speed up the process or multithread it somehow. I had a friend who used a hadoop cluster to speed up jobs, I was wondering if anyone had done something similar with calibre. |
![]() |
![]() |
![]() |
#2 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Do not call calibredb separately for each file. Every time you call calibredb, it has to load the entire db into memory. Instead use the multiple book adding options of calibredb.
It is on my todo list to add a a client/server mode for calibredb, so you can avoid this overhead. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Banned
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 666
Karma: 1752814
Join Date: Jan 2008
Device: Sony Reader PRS-505 : Onyx Boox Max : Sony PRS-900 : Onyx Kepler Pro
|
I see. Ok, I'll give it a try, thank you very much!
|
![]() |
![]() |
![]() |
#4 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Client-server model for calibredb to come alongside the client-server GUI inside the content server?
Sounds cool anyway -- looking forward to it! |
![]() |
![]() |
![]() |
#5 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Since the server will be getting write support, there are various things that will become possible with it eventually, such a client server mode for calibredb, directly opening libraries that reside behind a server in the gui using websockets, and so on.
However, that's a long road, so dont get too excited. |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Yup -- I am aware there is a long way to go. It's still interesting to get a long-term view of the plan.
![]() ![]() |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
tips for adding images in epub | hapax legomenon | ePub | 37 | 01-16-2024 06:38 PM |
Speed reading tips and techniques? | sweevo | Lounge | 11 | 08-19-2010 02:00 PM |
Tips on how to scan your own books? | ficbot | Workshop | 2 | 12-17-2009 03:19 PM |
Adding books speed question | karmalized | Calibre | 3 | 03-02-2009 11:32 PM |