Library Deleted after I synced

I went to sync my library, and once I did, all of my 500+ resources were deleted—except for 38 of them.

Not sure what happened.

Can anybody help me retrieve my resources?
«1
  • edited July 12, 2018
    It looks like you (or a computer with your account details) deleted those 500+ items from the server on April 25th, and you haven't synced since then. Syncing now pulled down those deletions.

    If you had the items previously on the computer you're using now, you can restore from a backup of your Zotero data directory. As a last resort, you should be able to use one of the last automatic backups (though those won't include attached files). Make a backup of your entire data directory now before the current backups age out.
  • I am not able to locate any data that was present before the supposed April 25th deletion of my files.

    Is there a way I can just simply find a "history" of syncs and choose to open the files that were in my Zotero before April 25th?

    I'm sorry, I'm struggling to follow the instructions in the links you sent.

  • edited July 16, 2018
    Is there a way I can just simply find a "history" of syncs and choose to open the files that were in my Zotero before April 25th?
    No. When you delete data, it's deleted. So the only way to get it back is to get it from a backup you took or an automatic backup made by Zotero, which covers the past day or so. If you were looking at the data on your current computer before syncing — and you made a backup of your Zotero data directory when I said to above — you should be able to restore at least the data if not the files from before you synced down the deletions.
    I'm sorry, I'm struggling to follow the instructions in the links you sent.
    The linked instructions are written quite carefully, so if you're having trouble with something, quote exactly what you're not understanding and we can try to help further.
  • Thanks, Dan.

    The data that I'm looking at are the current files in my Zotero (38 files). But I'm not sure how to retrieve the other 500ish files. I don't see those when I click my Zotero Data Directory.

    What exactly is a "back up?" Is this a file back up that saves files automatically? Or is this something that a Zotero user has to do manually? If the former, that's where my question lies: where can I find those backed-up files? If the latter, then I am not sure what I did to back up the files.
  • This is all explained on the linked page. I'd start there, and quote specific things you don't understand.

    https://www.zotero.org/support/zotero_data
  • To clarify, here is the process to which I'm referring:

    (1) I click "Data Directory"

    (2) My home directory (I use Mac) opens up and I see a folder entitled "Zotero."

    (3) I open the file entitled "Zotero."

    (4) That file contains 38 files of the 500ish I have.

    Question: How do I retrieve the other 460ish files that were deleted apparently on April 25th?
  • edited July 16, 2018
    If you weren't backing up your computer and/or Zotero data directory and you don't have those files on another synced computer, you can't get those files back. (If you think you might have a computer that still has the files, you should disconnect it from the internet before checking. But since these deletions had to come from somewhere, they may have been made on any other computer you were syncing with and the files would be gone from there too.)

    If you backed up your data directory when I said to a few days ago, you should be able to restore your database from before you synced down the April 25th deletions. If not, it might be too late, but do so immediately and then check the dates on the zotero.sqlite.bak (and similar) files in your data directory.
  • How do I open the zotero.sqlite., zotero.sqlite.bak., zotero.sqlite.1.bak. files?

    I click but there isn't an application on my MacBook that will allow it to open?
  • (Actually, if you do manage to restore your database from before the sync that pulled down the deletions and then restore it to the online library, as explained on the linked page, there's a small chance we'd be able to recover some of the files on the server side. But restoring your data locally would be the first step.)
  • That is, how do I open them to "check the dates?"
  • Again, please see the linked page, which explains how to do this. I'm afraid we just can't walk people through this when we already have it written down in extensive detail.
  • edited July 16, 2018
    That is, how do I open them to "check the dates?"
    For that I just mean look at the timestamp of the file in the filesystem. That will tell you when the backup was made. To actually examine the contents, you'd follow the linked instructions for restoring from an automatic backup.
  • Where can I find a "timetamp?" And what is a "filesystem?"

    I apologize that I am such a burden regarding all this. I simply just don't know what the article is saying. I understand that it's clearly written, but I just don't understand the jargon.

    For example, in the sentence "Close Zotero, move one level up in the filesystem (Cmd-up-arrow on macOS, Alt-up-arrow on Windows), and rename the directory to “Zotero-Old”. Next, copy the data directory from your backup to the original location," ...

    What is a "filesystem?" What is a "directory" for which I should rename "Zotero-Old?" Because of these misunderstandings on my part, I cannot understand the next sentence, which says I should copy the "data directory" from my "backup" (which I am unaware of the file that contains this 'backup') to the "original location." Where is the original location?

    Again, I am sorry. I'm not trying to cause you trouble; i'm simply trying understand what you're saying so that I can retrieve my files back.
  • Thanks, Dan.

    You've written extensive instructions. I'll figure it out.

    Just know that it would be of great help if you provided screenshots with all your instructions for those of us who are unfamiliar with some of the jargon.

  • edited July 17, 2018
    directory = folder
    filesystem = the files on your computer that you see in Finder
    timestamp = the date and time that you see when you look at a file in Finder

    Ultimately this is somewhat technical stuff, but we really do try to explain it in context if you read the page in full. E.g., the very top of the page says "The easiest and most reliable way to find your Zotero data is by clicking the “Show Data Directory” button in the Advanced tab of your Zotero Preferences window." If you do that, you'll see the Zotero folder. So that's your data directory. (We could consider replacing all instances of "directory" with "folder" to make it a bit more accessible, but "data directory" is somewhat of a more canonical term, and a decade of documentation refers to it as such. In any case, it should be pretty clear in context.)

    "original location", again, makes sense if you read it in context. The paragraph says to make a note of the full path of the data directory, and then has you rename that folder to "Zotero-Old". So the original location is whatever the folder was named before you renamed it. I've updated the page to clarify that that's "Zotero" by default. (But note that section is only relevant if you actually have a backup of your data directory.)
  • I've added another line to the top of the page to clarify the "data directory" part.
  • I found other zotero.sqlite files dating back to May.

    When I rename the old zotero.sqlite file to "zotero.sqlite.old" and replace it with the NEW zotero.sqlite file, I reopened Zotero (after upgrading to the 5.0), and there are no files.
  • Do I understand correctly?

    The "zotero.sqlite" file is THE file that contains what your Zotero library CURRENTLY shows you?
  • Because when I "sync," after rearranging these file names, nothing changes. Even my online account doesn't show any changes.
  • I found other zotero.sqlite files dating back to May.
    Where, what are their exact names, and what are their sizes and timestamps?
    The "zotero.sqlite" file is THE file that contains what your Zotero library CURRENTLY shows you?
    Yes.
    Because when I "sync," after rearranging these file names, nothing changes. Even my online account doesn't show any changes.
    Yeah, don't do that. The page explains how to restore local data from a backup to your online library, but that's irrelevant until you've found the correct data locally.
  • I just found one from 4/25.

    Name: "zotero.sqlite.old"

    Size:958KB

    Location: "ColtonMoore1" (Colton is my name)
  • edited July 17, 2018
    958KB would be an empty database.

    But you don't need a backup from 4/25 — you just need the last automatic backup from your Zotero data directory from before you synced down the deletions. As I say above:
    If you were looking at the data on your current computer before syncing — and you made a backup of your Zotero data directory when I said to above — you should be able to restore at least the data if not the files from before you synced down the deletions.
  • I'm still a bit confused as to the difference between what you mean by "data" and the actual files that pull up when I click "Data Directory" in my Zotero Preferences. Because of this miscommunication, I'm attaching a Dropbox link with the process I'm using along with screenshots to help clarify my confusion.

    See this link, please: https://www.dropbox.com/s/na4pjln2arf0ilu/ZOTERO QUESTIONS.docx?dl=0
  • I'd recommend asking someone to help you further in person. Someone moderately tech-savvy should be able to follow the linked directions pretty easily. But we just can't get into questions like "what do you mean by 'data'" when it's explained on the linked page.

    It's not clear whether you made a backup of your data directory when I originally said to or what other backups you have, but basically, if you find a zotero.sqlite.* file that's substantially larger than 1 MB, that would be a non-empty database, and you should be able to disable auto-sync and swap that in as explained on the linked page to see what's in it. If you do find the data you're looking for, you can follow further instructions on that page to restore it to your online library. (You still won't have your attachment files unless you actually have a backup of the entire Zotero data directory with files in 'storage', but if you post here after restoring your online library we can look to see whether we can reassociate the restored items with the files.)
  • Could you just tell me what the next step is? I've given you screenshots in the dropbox link. What am I missing? I'm honestly asking for help.
  • Generally what you're doing is right, (though note that you shouldn't be doing anything with zotero.sqlite while Zotero is running. Close down Zotero once you have the data folder open)

    But we have no idea if you´re doing this with the right sqlite files -- you don´t say where they are from.

    Check the filesize and date of sqlite files: How large are they? If none of them are much larger than 1MB, they´re not the right file.

    Also, do you have a back-up copy of the folder containing those sqlite files? Back-up doesn't mean anything special here. It just means a copy of that folder. That would be included, e.g., in a Timemachine-created back-up of your harddisk.
  • I found a file that is 5MB. I've renamed it zotero.sqlite.

    My Zotero is off.

    I tried to open it. Zotero told me to download the most recent edition of Zotero.

    I downloaded the most recent edition of Zotero 5.0.53.

    I opened the edition of Zotero. Library is empty.

    But the 5MB file is named correctly. What now? Your instructions say, "When you reopen Zotero, you should see your restored Zotero data." But I don't see my library restored.
  • edited July 17, 2018
    A 5 MB file can still be empty. (Basically, 1 MB and 5 MB are generally bad.)

    It would really help us help you if you would answer our questions — you still haven't provided the names, locations, file sizes, and timestamps of the various zotero.sqlite files you're finding.

    You also have repeatedly avoided saying whether you made a backup of the Zotero data directory when I first said to five days ago or whether you made other backups before. If you didn't, OK — that might make it hard to recover your data, but it doesn't do any good to avoid the questions.

    Despite your email suggesting otherwise, we obviously want to help you, or else we wouldn't be spending so much time here trying to do so. But you have to meet us halfway. We need you to answer the questions we ask and cite specific things in the linked instructions where you're getting tripped up for us to be able to help (as well as to update those instructions to make them clearer for others in the future).
  • I have TimeMachine. I've never manually backed up any files from Zotero.

    I answered "names" and "locations" in the Dropbox link. The file sizes vary: 5MB, one file named "zotero.sqlite-journal" at 427KB, and one file named "zotero.sqlite-old" at 958KB.

  • Timestamps are 5/9, 5/10, and 7/17
Sign In or Register to comment.