Changing Zotero Folder to a NAS fails - Error: database is locked

Using netrunner (ubuntu based linux). I mounted a hard drive on a nas via samba - but when pointing the zotero directory to that new path i get:

Datenbank-Upgrade-Fehler (Database Upgrade Error)

[Exception... "Component returned failure code: 0x80630001 (NS_ERROR_STORAGE_BUSY) [mozIStorageConnection.commitTransaction]" nsresult: "0x80630001 (NS_ERROR_STORAGE_BUSY)" location: "JS frame :: chrome://zotero/content/xpcom/db.js :: Zotero.DBConnection.prototype.commitTransaction :: line 497" data: no] [ERROR: database is locked]

The only thing i found about this error is here:
https://forums.zotero.org/discussion/31031/storage-buy-database-locked/

but simply restarting does not help. Same error message occurs with Zotero Firefox Extension and also when i try it with standalone.
When i rename the folder on the nas and and by that force zotero to ask me for the not-found directory location and i point back to the local disk - it works again.
  • Network shares can break some of the standard filesystem locking behavior that the database that Zotero uses (SQLite) relies on. While lots of software uses SQLite, we use a locking mode that prevents database corruption from accidental simultaneous access (say, from Zotero for Firefox and Standalone), and that mode requires some additional filesystem capabilities, which is why you might not see this with other software.

    You may be able to experiment and make adjustments to fix this, but for Zotero's part it just expects standard filesystem behavior.
  • edited August 1, 2014
    so if i understand right you are basically saying that zotero is not meant to be used on a nas ?

    I searched some more and found some entries who are trying something quite similar to my approach:

    https://forums.zotero.org/discussion/30851/best-way-to-setup-zotero-for-a-group/

    Is basically the same what we want to do- store the pdfs locally - if possible in a defined folder structure we already have establisehd on the nas (by the way - we will soon switch from the nas to a zentyal server - don't know if this information helps) - which we mimic with zotero. If thats not possible a single folder on the network drive where everything new is saved to will also be ok.

    What we want now is to find a way for zotero to do so - without having to have the whole zotero + files on each users pc. Hosting on zotero is out of data privacy reasons not an option as the server is located in the us (as far as i know).
  • so if i understand right you are basically saying that zotero is not meant to be used on a nas ?
    Well, not exactly. I think some people do have their data directories on network shares, but we don't test that configuration and can't do anything about it if the network share doesn't conform to standard file locking behavior.
    What we want now is to find a way for zotero to do so - without having to have the whole zotero + files on each users pc. Hosting on zotero is out of data privacy reasons not an option
    I think you may be conflating a couple different things here. Zotero sync is just for syncing — it doesn't prevent the database and files from needing to be stored somewhere locally available. So these issues aren't really related. And if the idea was to have a Zotero database accessible via NAS from multiple computers at the same time, you absolutely can't do that — the only possible way to use a network share would be to have a computer take out an exclusive lock on it (which Zotero itself tries to do to the database, but that's what a network share could break).

    If you don't want to transfer files to each computer, one option would be to transfer just the data directory (e.g., via a roaming home directory — again, as long as it's exclusive) and then use linked files (and ZotFile, perhaps) and an attachment base directory to store PDFs on the NAS.
Sign In or Register to comment.