View Single Post
Old 10-26-2013, 04:40 AM   #14
aleyx
Addict
aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.aleyx can self-interpret dreams as they happen.
 
Posts: 250
Karma: 20386
Join Date: Sep 2010
Location: France
Device: Bookeen Diva, Kobo Clara BW
A "killall calibre-server" is all that's needed to stop the content server. It's read-only on the DB, so no harm done.

I use a simple calibre-server.sh at boot:

Code:
#!/bin/bash
calibre-server --port 8081 --restriction FanFiction --daemonize
calibre-server --port 8080 --restriction Novels --daemonize
Which give me two content server instances on two ports, each giving me one of my virtual libraries. Still haven't gotten around making it an init.d service script... Ah well. I'm lazy that way.

Then I have calibre-update.sh to, well, update Calibre when a new version is out:

Code:
#!/bin/bash
killall calibre-server
sudo python -c "import sys; py3 = sys.version_info[0] > 2; u = __import__('urllib.request' if py3 else 'urllib', fromlist=1); exec(u.urlopen('http://status.calibre-ebook.com/linux_installer').read()); main(install_dir='/opt')"
$HOME/bin/calibre-server.sh
I haven't yet found (or looked at, in all honesty) a way to automatically check if a new version is available and run calibre-update.sh accordingly in a cron. The installer at http://status.calibre-ebook.com/linux_installer doesn't check the local version of Calibre, so it downloads and install even if it's not necessary...


Quote:
One nice way to set it up could be to have three copies of your calibre library.
Hm... I don't really see it. I mean, the backup copy is a given, of course, and should be a part of your global backup policy anyways. But I don't see the use for (C), as the content server automatically picks up changes to the Calibre library.

My current library (~1400 books, many of them having several formats) is currently 971MB. I'm not hurting for disk space, but still...

Edit: I could see it if the Calibre doing the updates lived on one computer, the content server on another, and you didn't want any of them to work on a share. But that's not the case here; there's only one server and it's headless.

Last edited by aleyx; 10-26-2013 at 04:56 AM.
aleyx is offline   Reply With Quote