View Single Post
Old 09-08-2012, 03:15 PM   #1
ICDeadPpl began at the beginning.
Posts: 10
Karma: 10
Join Date: Mar 2010
Location: Sweden
Device: Kobo Aura H2O
Question Library on Cifs share, DB on local disk?

I have a NAS with a cifs share, where I'd like to store the library (96 GB).
On my local computer I have an 128 GB SSD, which is why I don't want to store the libtrary on my local machine.
I read that you can have the DB location overridden, so I tried that.
I tried to override the DB location with this (Ubuntu 12.04):
Exec=env CALIBRE_OVERRIDE_DATABASE_PATH=/home/jan/Calibre calibre
Yet, when I start Calibre it throws an error:

Traceback (most recent call last):
  File "/usr/lib/calibre/calibre/library/", line 131, in load_preferences
  File "/usr/lib/calibre/calibre/library/", line 198, in __init__
  File "/usr/lib/calibre/calibre/library/", line 146, in connect
    self.conn = connect(self.dbpath, self.row_factory)
  File "/usr/lib/calibre/calibre/library/", line 366, in connect
    raise DatabaseException(*conn.proxy.unhandled_error)
DatabaseException: unable to open database file
	RemoteTraceback (most recent call last):
	  File "/usr/lib/calibre/calibre/library/", line 248, in run
	  File "/usr/lib/calibre/calibre/library/", line 225, in connect
	OperationalError: unable to open database file
I also tried export CALIBRE_OVERRIDE_DATABASE_PATH=/home/jan/Calibre, but it just doesn't seem to "take" the env variable?

Or have I misunderstood the concept?
From the Calibre manual: CALIBRE_OVERRIDE_DATABASE_PATH - allows you to specify the full path to metadata.db. Using this variable you can have metadata.db be in a location other than the library folder. Useful if your library folder is on a networked drive that does not support file locking.

Wouldn't it be easier for everyone, if the setup wizard would let one (optionally) choose separate locations for the library and the database?
ICDeadPpl is offline   Reply With Quote