Re: fsmonitor on linux is triggered due to unison changes its fingerprint cache
Boris Kirkorowicz <[email protected]> Fri, 26 Sep 2025 10:34:26 +0200
| Newsgroups | gmane.network.unison.general |
|---|---|
| Message-ID | <[email protected]> |
Hi, Am 26.09.25 um 04:35 schrieb 'Dale R. Worley' via unison-users: > [send send attempt] > > Ulrich Gemkow <[email protected]> writes: >> On Sunday 21 September 2025, Dale R. Worley wrote: >>> My understanding of all this is weak, but I notice an oddity in this bug >>> report that nobody else seems to have commented on: >>> >>> Ulrich Gemkow <[email protected]> writes: >>>> The inotify watch tool shows this sequence about every second: >>>> >>>> # ~/.unison/homesync/ OPEN fpd51d53afbd71ea49fcec7a981a36e25f >>>> # ~/.unison/homesync/ ACCESS fpd51d53afbd71ea49fcec7a981a36e25f >>>> # ~/.unison/homesync/ CLOSE_NOWRITE,CLOSE fpd51d53afbd71ea49fcec7a981a36e25f >>>> # ~/.unison/homesync/ OPEN fpd51d53afbd71ea49fcec7a981a36e25f >>>> # ~/.unison/homesync/ MODIFY fpd51d53afbd71ea49fcec7a981a36e25f >>>> # ~/.unison/homesync/ CLOSE_WRITE,CLOSE fpd51d53afbd71ea49fcec7a981a36e25f >>> >>> That line that says "MODIFY" -- what is being modified and who is >>> modifying it? Your report says that nothing has been changed in the >>> actual user files and that Unison makes no changes. >> >> This is the output of a tool which uses the Linux inotify syscall to >> watch for changes in a directory tree. It tells that the file named >> at the end of the line is modified ((fpd51d53afbd71ea49fcec7a981a36e25f). >> >> This is unisons fingerprint file. > > Ah! I had assumed that "fpd51d53afbd71ea49fcec7a981a36e25f" was some > sort of internal code. > > The let me propose this sequence of events: > > 1. Unison wakes up and runs. > 2. No files have changed, so it doesn't do anything. > 3. Unison does not change the contents of fpNNNNNNNN but it updates its > modification date. > 4. Unison sleeps. > 5. fsmonitor is notified that the modification date of fpNNNNNNNN has > changed. > 6. fsmonitor wakes up Unison. > 7. Unison wakes up and runs. > etc. > > What we need for this situation is that if Unison detects no changes, it > should not modify the file system, not even the files in ~/.unison. In > particular, it should not change the fp* file if it does not change its > contents. > > Dale what about excluding these files from being watched by inotifywait using paramter @<file>? -- Mit freundlichem Gruß Best regards Kirkorowicz To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].