Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 03-14-2022, 06:58 PM   #1
Nitrousoxide
Enthusiast
Nitrousoxide began at the beginning.
 
Posts: 49
Karma: 10
Join Date: Nov 2009
Device: None
Updating GUI and OPDS after cli adding books

Does anyone know how to get Calibre to update the opds and gui databases when you add a book via the command line?
Basically, I have another app generating epubs and dropping them in a directory. I then run a cron job to calibredb add the files in that directory. This works fine and they appear in the DB. But the GUI and OPDS server don't pick them up until I manually have it check through the GUI
I tried running calibredb check_library but that doesn't seem to cause the GUI or OPDS to pick up the database change.

These are the relevant parts of the bash script that I'm running

calibredb add -acIilsStt directory/path/to/books/for/input
calibredb check_library
Nitrousoxide is offline   Reply With Quote
Old 03-14-2022, 10:01 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
When running a calibre server, connect to it using calibredb. See the docs of calibredb for how to do that. Then it will update the GUI and OPDS automatically.
kovidgoyal is offline   Reply With Quote
Old 03-14-2022, 10:50 PM   #3
Nitrousoxide
Enthusiast
Nitrousoxide began at the beginning.
 
Posts: 49
Karma: 10
Join Date: Nov 2009
Device: None
Quote:
Originally Posted by kovidgoyal View Post
When running a calibre server, connect to it using calibredb. See the docs of calibredb for how to do that. Then it will update the GUI and OPDS automatically.
I got this working with this command, for anyone in the future who might see this.

calibredb add -acIilsStt --username (username) --password (password, likely need to surround with quotes due to odd characters) --library-path 'http://192.168.1.1:8080(replace with actual IP and port)/#(name of DB, look up at the top of the calibre gui window to see what it is, it also needs the preceeding "#" that i left in here, entire IP address + DB name was surrounded with quotes like here due to # sign breaking things in a bash script otherwise)' directory/path/to/books/for/input

Without all the notes:
calibredb add -acIilsStt --username user_name --password 'pass_word' --library-path 'http://192.168.7.233:6838/#DB' directory/path/to/books/for/input

You could probably use the local host ip for that, it wasn't working for me for some reason so I used the network IP of the server.
Nitrousoxide is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Calibre 5.71 - CLI - Message error when adding books/exporting data Bertrand Calibre 4 12-18-2020 09:05 AM
Calibre issues with adding books using cli klackerz Calibre 1 07-06-2018 06:06 AM
Adding books on cli leads to error johnny_cgn Calibre 11 06-26-2018 04:12 AM
adding books from OPDS server? Claghorn Library Management 2 09-05-2012 05:48 AM


All times are GMT -4. The time now is 03:07 PM.


MobileRead.com is a privately owned, operated and funded community.