How can I force the server to sync to my local machine?

I have a simple setup, one server, one user, one laptop. It is all on a local, private network.

The server keeps a copy of all of my work and is updated any time I am at home.

I recently had some issues with my laptop, which are now resolved. While the laptop was at the shop, I continued to work on another laptop, which was not connected to nextcloud. When I got my laptop back, I restored from my backup (not NextCloud) and copied the updated files from the other laptop to my laptop.

Now when I go into NextCloud, one of the folders (the one that had the changes I copied) is unchecked and there is a message

“Unchecked folders will be removed from your local file system and will not be synchronized to this computer anymore.”

I re-checked the folder and continued to sync, but now I discover that all of the files that I updated are now renamed to “file_conflict_date” files, which means I have to go through them all one by one and rename them to get things back to how they should be :frowning:

Is there a way I can avoid this in the future and force nextcloud to always treat my local version as gospel?

I may not be understanding correctly, but it sounds like you took your first laptop (let’s call it laptop A) offline for a while, worked on some files on laptop B (no connection to Nextcloud), then copied the updated files from laptop B to laptop A and tried to sync your updated files?

That should work, but from what you described my first thought would be that the dates on the files changed, possibly to an earlier date than what Nextcloud knows about. That can definitely cause some conflicts.

This is what I would try:

  • Copy your current set of files outside of the Nextcloud directory (temporarily)
  • Delete the old set of files from Nextcloud (preferably from the web interface), including all the conflicts
  • Copy the new files back in and let them sync like they’re brand new files

Unfortunately it’s about 70Gb of files over wifi, so deleting and re-syncing is a pain.

I don’t know why it didn’t work, nothing should have had an earlier date. I was hoping there was some setting that tells nextcloud to never overwrite/rename local files for this scenario.

The bummer is that there’s currently no interface to resolve conflicts from the client, so it’s going to be a manual process for you. :disappointed_relieved:
Fortunately, it looks like the owncloud team is working on this for their client, so it’s only a matter of time before this makes it into the nextcloud client.