# Syncthing generates cnflicts when file only changed on one device

**URL:** https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628
**Category:** Support
**Created:** [November 21, 2021, 4:15am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628 "2021-11-21T04:15:48Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![oleg](https://forum.syncthing.net/user_avatar/forum.syncthing.net/oleg/32/11102_2.png) [@oleg](https://forum.syncthing.net/u/oleg)
#### Post date: [November 21, 2021, 4:15am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/1 "2021-11-21T04:15:48Z")

</div>

Similar to previous topic ([conflicts when file only changed on one device](https://forum.syncthing.net/t/conflicts-when-file-only-changed-on-one-device/16980)), but I don’t use nfs.

I’m using syncthing to sync code betweeen Windows 10 (local), and two Linux machines (remote). I’m editing code on local machine, run compiler and get a lot of sync conflicts. Strangely, syncthing thinks all conflicted files are originated on local machine, which is strange. Any way I can debug / fix it?

I’m using v1.18.4

---

<div class="post-metadata">

### Author: ![calmh](https://forum.syncthing.net/user_avatar/forum.syncthing.net/calmh/32/15311_2.png) [@calmh](https://forum.syncthing.net/u/calmh)
#### Post date: [November 21, 2021, 6:45am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/2 "2021-11-21T06:45:44Z")

</div>

My guess would be you have an IDE open on some of the other machines, which auto builds/formats/resaves/whatever causing conflicts. I’d debug by shutting down stuff on the other machines.

---

<div class="post-metadata">

### Author: ![oleg](https://forum.syncthing.net/user_avatar/forum.syncthing.net/oleg/32/11102_2.png) [@oleg](https://forum.syncthing.net/u/oleg)
#### Post date: [November 22, 2021, 2:48am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/3 "2021-11-22T02:48:10Z")

</div>

Nope, there are no IDEs open on remote machines. These machines are for passive storage only. Moreover, conflicts are created when I put remote machines on pause in remote devices. All conflicting files created by SyncThing have suffixes corresponding to the local machine id, and sometimes several such files are created (all corresponding to local machine). I assume that sync conflict means that file was edited on remote machine and local machine simultaneously, and suffix (the XXXX in filename-.sync-conflict-DATE-TIME-XXXX.ext) corresponds to the machine on which the particular version was created.

---

<div class="post-metadata">

### Author: ![calmh](https://forum.syncthing.net/user_avatar/forum.syncthing.net/calmh/32/15311_2.png) [@calmh](https://forum.syncthing.net/u/calmh)
#### Post date: [November 22, 2021, 6:10am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/4 "2021-11-22T06:10:20Z")

</div>

Indeed. I have no idea how that can happen if there’s no modifications from the other side.

---

<div class="post-metadata">

### Author: ![imsodin](https://forum.syncthing.net/user_avatar/forum.syncthing.net/imsodin/32/3317_2.png) [@imsodin](https://forum.syncthing.net/u/imsodin)
#### Post date: [November 22, 2021, 6:19am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/5 "2021-11-22T06:19:13Z")

</div>

You can run `syncthing cli debug file <folder-id> <file-path>` on either/both the original and conflict file, and the version vector will show which remote device was involved.

---

<div class="post-metadata">

### Author: ![oleg](https://forum.syncthing.net/user_avatar/forum.syncthing.net/oleg/32/11102_2.png) [@oleg](https://forum.syncthing.net/u/oleg)
#### Post date: [November 23, 2021, 5:15am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/6 "2021-11-23T05:15:35Z")

</div>

Results are same for original and modified files:

```
{
  "availability": null,
  "global": {
    "deleted": false,
    "ignored": false,
    "invalid": false,
    "localFlags": 0,
    "modified": "1969-12-31T16:00:00-08:00",
    "modifiedBy": "",
    "mustRescan": false,
    "name": "",
    "noPermissions": false,
    "numBlocks": 0,
    "permissions": "0",
    "sequence": 0,
    "size": 0,
    "type": "FILE_INFO_TYPE_FILE",
    "version": []
  },
  "globalVersions": "{}",
  "local": {
    "deleted": false,
    "ignored": false,
    "invalid": false,
    "localFlags": 0,
    "modified": "1969-12-31T16:00:00-08:00",
    "modifiedBy": "",
    "mustRescan": false,
    "name": "",
    "noPermissions": false,
    "numBlocks": 0,
    "permissions": "0",
    "sequence": 0,
    "size": 0,
    "type": "FILE_INFO_TYPE_FILE",
    "version": []
  },
  "mtime": {
    "err": null,
    "value": {
      "real": "0001-01-01T00:00:00Z",
      "virtual": "0001-01-01T00:00:00Z"
    }
  }
}

```

---

<div class="post-metadata">

### Author: ![imsodin](https://forum.syncthing.net/user_avatar/forum.syncthing.net/imsodin/32/3317_2.png) [@imsodin](https://forum.syncthing.net/u/imsodin)
#### Post date: [November 23, 2021, 6:20am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/7 "2021-11-23T06:20:18Z")

</div>

That’s equivalent to “not found” (all default values). Please double check you are using the path relative to the folder root, e.g. “foo/bar” when the abs path is “/folder/root/foo/bar”.

---

<div class="post-metadata">

### Author: ![oleg](https://forum.syncthing.net/user_avatar/forum.syncthing.net/oleg/32/11102_2.png) [@oleg](https://forum.syncthing.net/u/oleg)
#### Post date: [November 29, 2021, 12:39am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/8 "2021-11-29T00:39:27Z")

</div>

I digged into the json generated by syncthing. It turned out that conflicting version was generated on a Linux machine (Raspberry Pi), where synchronized directory was shared by SMB. Can that be a source of a problem?

---

<div class="post-metadata">

### Author: ![AudriusButkevicius](https://forum.syncthing.net/user_avatar/forum.syncthing.net/audriusbutkevicius/32/277_2.png) [@AudriusButkevicius](https://forum.syncthing.net/u/AudriusButkevicius)
#### Post date: [November 29, 2021, 9:55am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/9 "2021-11-29T09:55:11Z")

</div>

Yes, smb/fat potentially loses permissions/timestamps as we try to set them ending up generating conflicts.

---

<div class="post-metadata">

### Author: ![system](https://forum-uploads.syncthingcdn.net/original/2X/0/0b50e0a202b22ae6a67190759e8c868805b8ed9f.png) [@system](https://forum.syncthing.net/u/system)
#### Post date: [December 29, 2021, 9:55am UTC](https://forum.syncthing.net/t/syncthing-generates-cnflicts-when-file-only-changed-on-one-device/17628/10 "2021-12-29T09:55:55Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
