Damaged Lock Files in XUbuntu 18.04

Discuss new features and functions
Posts: 3
Joined: 16 Jan 2019

lionkm

I'll just describe what happened: I connected a new, 1TB Seagate Backup Plus USB drive to an Optiplex GX620 running XUbuntu 18.04, created 7 backup folders in its root directory and set up FreeFileSync 10.7 Build 12/12/2018 - Unicode x64 to mirror 5 local HDD folders and 2 network folders. I stopped the backup 2 or 3 times and then re-ran it when I'd done whatever I needed to do, and since it was taking a long time, (to be expected backing up 133,000 files/124.3 GB of data), I set it up to shut down when complete.

The next morning, when I went to view the USB drive's contents (in Thunar 1.6.10), 3 of the folders were shown as empty. When I tried running FreeFileSync again, pressing the "Compare" button resulted in errors stating that FFS locks could not be created in those 3 folders. Having had something similar happen in the past, I opened an xfce4-terminal (0.8.7.4) window, "changed" to the USB drive and found that the backup appeared to have been "successful" (the folders were not empty), but that in each folder (and in 2 subfolders of another folder), there were damaged "files" named like FreeFileSync lock files. Where I would normally expect ls -l to give something like:
lrwxrwxrwx 1 user group 42 Jun 4 2018 [name].lock
...everything but the [filespec] was show with question marks, thus:
?????????? ?? ? ? ? ? ? [name].lock

Even as root, the system would not let me rename, move or delete these "files" (I tried rm & rmdir), or change their attributes or owners. That may be a XUbuntu bug, and fsck was also unable to even recognize that there was something wrong with them, but FreeFileSync was unable to create locks in those directories. I'm sorry I didn't record all the error messages. I even tried moving all the valid files and directories to other folders and deleting the folders with the damaged lock files, without success. There was nothing I found I could do in XUbuntu that would fix or delete those files, and I don't have a directory editor for XUbuntu...

What I finally did was boot into Windows 7 Professional and use Windows' file manager tools to repair the drive. The reason I'm posting this here is that there appears to be a problem with what FreeFileSync does with locks it creates when it's stopped while comparing folders for synchronization.
Posts: 3
Joined: 16 Jan 2019

lionkm

This problem still exists in Ubuntu (Xubuntu) 18.04. Here's the result of ls -l in an affected folder:
root@OptiPlex780:/media/kent/3F226CEF1B70943F/Backup_2/Everyone# ls -l
ls: cannot access 'sync.ffs_lock': Input/output error
total 156
drwxrwxrwx 1 user user 4096 Jun 24 23:12 Hangul
drwxrwxrwx 1 user user 32768 Jul 2 09:08 Humor
drwxrwxrwx 1 user user 16384 Jun 24 23:13 Info
drwxrwxrwx 1 user user 4096 Jun 24 23:13 'Linksys WMP11 v1'
drwxrwxrwx 1 user user 4096 Jul 2 09:08 People
drwxrwxrwx 1 user user 8192 Jun 25 07:19 PowerPoint
drwxrwxrwx 1 user user 4096 Jun 24 23:13 Sayings
drwxrwxrwx 1 user user 20480 Jun 24 23:13 Sound
drwxrwxrwx 1 user user 12288 Jun 24 23:13 Stationery
-????????? ? ? ? ? ? sync.ffs_lock
drwxrwxrwx 1 user user 4096 Jun 24 23:13 Text
drwxrwxrwx 1 user user 4096 Jun 24 23:13 'Transportation & Maps'
drwxrwxrwx 1 user user 4096 Jun 24 23:15 Videos