Factory restored laptop - can't locate backed-up Zotero library

Hi everyone,

I've seen a lot of great help been offered here and I'm hoping that someone will be able to help save my thesis. I use Zotero Standalone, but I don't really use the online version of Zotero.

My computer had to be factory restored a week ago, and I don't believe that the Zotero data directory was backed up before the restore happened. The Documents folder from my Mac was the only thing that was backed up before the restore, because I didn't realize that wiping the computer would delete the Zotero metadata. There is a zotero.sqlite and zotero.sqlite.bak file in my drive, but I'm pretty confident that they're both the "reset" version of those files with no content on them.

My next move was to check my online database, since I'm very confident that auto-syncing my files was turned on before the factory reset happened (the "Sync Automatically" check-box in the Sync section of my Preferences). However, when I went to check My Library after logging in here, the library is also empty.

That leads me to believe that the online library was overwritten by the local (empty) library when auto-sync processed at some point; but when I went to check the Trash for the old/deleted library, it was nowhere to be found.

If indeed my computer synced its local, empty library to the online collection and deleted the previous libraries, then why am I not able to access the library in the trash? Does anyone have any other suggestions for retrieving my former library and saving my thesis?

Thanks in advance for any help offered - if nothing else I will absolutely back up my Zotero files from here on out! TT_TT
  • That leads me to believe that the online library was overwritten by the local (empty) library when auto-sync processed at some point
    No, this doesn't happen.

    Your current account never synced with the online library before today. If you were syncing, it was with a different account.

    Other than finding that or finding a backup of your previous data directory, I'm afraid there'd be no way to get your data back.
  • And just to add here for the future, you shouldn't back up the Zotero data directory, or Documents, or any other specific folders — you should just back up your entire computer in an automated manner using Time Machine.
  • If recovery of your file(s) is important to you then I can suggest some "last chance saloon" options.

    Although your Mac may have been "factory restored", depending on the restoration method used, there is a slim chance of recovery of lost data using forensic tools. However before following the steps below find out what was involved in the factory restore process since if a magnetic wipe was involved you will be wasting your time. But if it was a simple hard drive reformat you have a chance.


    The principles are as follows:

    (a) Stop using your Mac hard drive since if there is any residual data to recover (post restoration) it may be overwritten by your actions.

    (b) Use an external OS running via USB (I have no experience with Mac) which can be used to try to recover the data on your internal drive. i.e. the external drive is your master OS and your internal (slave) drive is the subject for forensic data recovery.

    (c) On the running external USB OS install forensic tools such as testdisk.
    http://www.cgsecurity.org/wiki/TestDisk_Download

    (d) Note that you will need some extra disk space to save any files recovered from your internal drive and importantly this must not be on the internal drive which you are scanning. So use an external drive with sufficient spare space to save any recovered data.

    (e) If testdisk doesn't work (and it may take several overnight runs for full scan of your internal drive) then the next step is to try other recovery tools such as photorec.

    (f) Note that such recovery tools do not restore the hierarchical file system you see in your Mac. You may end up with a huge batch of files saved in a folder in your external drive all randomly named. You then have to painstakingly go through these to find zotero.sqlite and zotero.sqlite.bak (since they are not named as such). You will need an sqlite viewer for this.

    (g) Learn about other forensic data recovery tools to try on Mac.

    (h) Also use an automated backup process to avoid the need for deep recovery.

Sign In or Register to comment.