old files not sync'ing w/ new external library location


hello,

i moved my standalone library to a new external hard drive.

items created before the move to new hard drive are not sync'ing with their files (even though the files do exist on my external drive, there are too many thousands of them to re-sync each manually). items created after the move are sync'ed without issue, it seems.

how do i re-sync the de-sync'ed file-items?

thank you!

  • how did you move the library exactly? And what do you mean by "syncing with their files"? If you get any error messages, could you provide them (as they appear)?
  • edited November 15, 2017
    i moved the entire library i had been using on one external drive to a new drive, and customized the data directory location to the folder with the sqlite file on the new drive.

    by not "syncing with their files": the zotero item has a hollow blue circle in the "attachment" column (rather than a blue circle for items that are synced).

    i get the following message when clicking on items with hollow blue circle:
    "The attached file could not be found.
    It may have been moved or deleted outside of Zotero, or, if the file was added on another computer, it may not yet have been synced to or from zotero.org."
  • The easiest would be to check where exactly Zotero is looking for files you're trying to open, either by looking at debug output https://www.zotero.org/support/debug_output or by using Zutilo https://github.com/willsALMANJ/Zutilo/releases

    If you can't figure that out, provide a debug ID for trying to open an attached file.
  • edited November 15, 2017

    this is the debug output from trying to open an item
    D1986582357
  • You can look at the debug output yourself to see the path. (Otherwise we'd need to post it publicly here.)

    If you have a linked attachment base directory set in the Advanced → Files and Folders pane of the Zotero preferences, you may be able to just change that. Otherwise, the easiest option is to use Zutilo to correct the paths, and then set up the linked attachment base directory so this doesn't happen in the future (because the files will all be stored as relative paths). You can do fix this without Zutilo, but you have a bit less visibility into what you're doing.
  • edited November 15, 2017
    i don't seem to have any linked attachment base directory set in my zotero prefs.

    zutilo downloaded but i couldn't figure out how to open it.

    when i look at the debug output.. it seems that zotero standalone is still looking for the old file attachment along the old path (on the previous external hard drive), rather than updating the path for the old files to (the new hard drive) where i have moved the entire library.
  • Right, those are linked files, so the path won't change automatically. Zutilo can help with that.

    To do it all in Zotero, you'd want to temporarily mount the old hard drive (if it's still available), set a linked attachment base directory (which will make all the paths relative to that directory), plug in the new hard drive, and then update the base directory to point to the same location on the new drive.
  • edited November 15, 2017
    since i can't open zutilo, i'll try to do it in zotero, but does it matter that the older library on that older drive is not up-to-date (missing newer files)?

    so, first i set the attachment base directory to the old drive?

    what do you mean point to the "same location"? (won't it be a new location on a new drive?)

  • edited November 15, 2017
    well, the library works fine on the old drive... (i want to move it because old drive is showing signs of deterioration).

    but the library still wouldn't work on the new drive after i updated the base directory to the equivalent position on this new drive.

    thoughts?
  • You'll need to either use Zutilo or debug this with the base directory setting using the paths shown in the debug output.

  • im using stand alone -- do i need firefox to open zutilo? i get this message:

    There is no application set to open the document “zutilo_utility_for_zotero-2.0.3-fx.xpi”.
  • edited November 15, 2017
    See the installation instructions here: https://github.com/willsALMANJ/Zutilo#zotero-standalone
  • edited November 15, 2017
    thanks for this.. i'm still having trouble figuring out how to use zutilo to fix this file linking
    (...that's after reading and searching for ways to do so on: https://github.com/willsALMANJ/Zutilo/blob/master/docs/USAGE.md)
  • If you can post the relevant paths here, we can likely tell you more specifically what to do.
  • edited November 15, 2017
    the old path:
    /Volumes/2tb oore/DOCTORATE/ZOTERO/Zotero/Profiles/nem16z0a.default/zotero

    the new path i want:
    /Volumes/4tb oore/ZOTERO/Zotero/Profiles/nem16z0a.default/zotero

    Note... when i artificially change the new path to look like the old path, it works (all files seem to appear linked and function as such). However, this is not an accurate naming system: the new drive is 4tb and my zotero is now post "doctorate".
  • This is where the database is, but this wouldn't (or at least shouldn't) be where you have linked files?

    So to clarify: By default, Zotero stores attachments in the storage folder in the data directory. If you do that, moving the data directory will keep attachments working. It appears your attachment are, instead, links to files outside Zotero. You may have set up Zotfile to do that or may have done that manually -- hard to tell. We'd need to know where some of these links point (and, if they are indeed in the storage folder, how that happened).

  • the linked files are stored in a folder right 'next door' (to the folder containing Zotero which contains Profiles folder):

    /Volumes/2tb oore/DOCTORATE/ZOTERO/DANI ZOTERO

    in that folder i have the author folders. (maybe i used zotfile to do this during my previous forum thread)
  • edited November 15, 2017
    except now i see that the most recent file additions are indeed stored in the default zotero folder (containing the folders with alphanumeric names -containing nearly 40k folders, most of which seem empty, and yet which all together take up about 2gigs!?).

  • Right, so what you want to do is to enable "Modify attachment Path" in the Zutilo preferences (right below the Zotero ones) to show up in the Zutilo or Zotero context menu (doesn't matter which)
    Then
    - select one item where the PDF doesn't open
    - right-click on it and select "Modify attachment Path"
    - In the first popup that asks for the old partial path input

    /Volumes/2tb oore/DOCTORATE/ZOTERO/

    In the second popup asking for the replacement string use
    /Volumes/4tb oore/ZOTERO/

    if that works do so for all items with missing attachments.

    You did have Zotfile set up to move & link files. You'll have to look through your old thread to replicate your set-up.
  • edited November 15, 2017
    yes it worked for the few i did!

    do i select "replicate all instances of partial path string"?

    to do this for my entire library (>4k items in basic view) do i simply "select all" and do as one batch?

    is having linked files stored in separate folder less efficient? i may have done this so that i could find files by naming convention...
  • No on the "replicate" part (though it doesn't matter)

    Yes on doing this with select all.

    Linked files have ups and downs -- it's not per se less efficient, no, but you need to pay attention to things like relative paths, they're not usable in groups, and they're not accessible (or backed up) by Zotero online.
  • edited November 15, 2017
    there are about 60 items that remain unlinked (some are just pdf with no parent item). i can't find the files when i search using the finder. any idea how or where i might retrieve these?

    thank you!
  • Zutilo has a show file path option. Use that to figure out where Zotero is looking.

  • all of them seem to be in "storage" folder of old library (old hard drive).

    do i try to move them with... zotfile? when i try to replicate my previous zotfile set up?
  • you can move the subfolders they are in into the new storage folder in
    /Volumes/4tb oore/ZOTERO/Zotero/Profiles/nem16z0a.default/zotero
    and would then probably want to use Zotero to move them.
  • edited November 15, 2017
    i do this manually or with Zutilo?

    Zutilo's "show path" keeps pointing to "storage" but then the file is found in some old folder (in an older version that may be missing annotations)... when i select it, the file then seems moved to the "storage" folder.

    is this right?

This is an old discussion that has not been active in a long time. Before commenting here, you should strongly consider starting a new discussion instead. If you think the content of this discussion is still relevant, you can link to it from your new discussion.

Sign In or Register to comment.