Can't Find My Database after Moving to New Computer

Hi, I just got a new computer (MacBook Air 2020 M1, running MacOS Big Sur).

I used the apple migration tool to move everything from my old computer (a 2015 Macbook Air) to the new computer.

However, when I opened Zotero, there was nothing in there. It said that the folder it was directed towards didn't have a database.

So, I found a Time Machine backup of my Zotero file and copied it all over. Then, I pointed Zotero on my M1 Mac to the Old file folder. Still nothing showed.

Currently I have sqlite files as follows:
- zotero-october2020.sqlite from October 1, 2020 that is 8.7 MB
- zotero.sqlite from February 2, 2021 that is 975 mb.

I was able to find a storage folder in my Time machine backup that has lots of other subfolders.

My current data directory is in the default location.

I've never used Zotero on this computer before.
  • When's the last time you actually used Zotero on the other computer? Migration Assistant should've copied your files exactly as they were. If you recently used some sort of disk-cleaning tool — including the built-in macOS tool — you might have simply deleted the database by mistake. We've had a number of recent reports of people doing that.
    Currently I have sqlite files as follows:
    - zotero-october2020.sqlite from October 1, 2020 that is 8.7 MB
    - zotero.sqlite from February 2, 2021 that is 975 mb.
    I assume you mean KB, not MB? That is, an empty database?

    Are these located in the default data directory? Is there a 'storage' folder there containing subfolders from your past usage of Zotero?

    Basically, if you have an empty zotero.sqlite database and a 'storage' folder with files, you almost certainly just deleted the .sqlite database by mistake, perhaps while trying to free space.

    Note that zotero-october2020.sqlite isn't a file Zotero would've created, so that's something you would've had to have done. That looks like it has data in it, but only up through last October.

    If the Time Machine backup only has an empty database, you can move back through the history to see if you can find a larger version of the database.
  • Thank you so much for your help.

    I hadn't opened Zotero for a few months on the old computer and I did use a disk-cleaning tool to free up some space. So, it wouldn't surprise me if I deleted the .sqlite file.

    The database titled, "zotero-october2020.sqlite" is one that I made from a Time Machine Back up. It is 8.7 MB, not KB. The one from February 2 is KB, not MB.

    The one titled "zotero-october2020.sqlite" has a storage folder associated with it that's 1.12 GB.

    So, if I'm tracking, it seems like I have an old .sqlite file along with the storage for that file. Shouldn't I be able to back up from there?

    Each time I open Zotero > Preferences > Advanced > General > Files and Folders and I point it to the new "Zotero-October 2020" folder, nothing happens. It doesn't update.

    I've tried finding an older Time Machine Zotero backup, then copying and pasting all the files and folders into the default Zotero folder on the new computer. When I do this, I get the following error message:

    The Zotero database cannot be opened.

    "Make sure you have read and write permissions for all files in the Zotero data directory and that security software isn’t preventing Zotero from accessing that directory."

    Any help would be greatly appreciated!

  • edited 28 days ago
    OK, so leave Zotero pointing at the default location (/Users/:username/Zotero), or change it to point to there if it's not currently.

    If you get the permissions error after copying in a backup file, you'll need to fix the permissions in that folder so that your current macOS user account has read and write permissions for all files and folders in that folder. We can't really provide general OS support, so you can search for instructions for that elsewhere if need be, but basically you do it by selecting the folder, doing File → Get Info, and adjusting the permissions at the bottom (possibly after clicking the lock icon in the bottom right).

    I'd recommend leaving 'storage' alone for the moment and focusing on the .sqlite file. Zotero will use whatever file is named zotero.sqlite in that folder, so you can try various .sqlite backups by copying them into that folder and making sure they have that name, fixing permissions if necessary, and then starting Zotero.
  • Hey dstillman,

    Thank you so much for the help. I finally was able to get it to work. The clincher was going into the zotero.sqlite file, File --> Get Info --> and then giving everyone "Read&Write Permissions." What I didn't realize is that my macOS username wasn't added to the list of approved Read&Write permissions.

    Thanks a ton!
Sign In or Register to comment.