openzfsonosx / zfs

OpenZFS on OS X

Home Page:https://openzfsonosx.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dropbox issues when moving ~/Dropbox folder to a zfs filesystem

captain-haddock17 opened this issue · comments

Hi !

When I move my ~/Dropbox folder to a ZFS /Volumes/zDisk/User/myuser through the Dropbox utility, I have the following :

  1. transfer is OK
  2. next time Dropbox tries to sync, it hangs forever .

I did tried to have some clues about the particularities of ZFS folder, no way.

I had to go back, with a complete rm -r ~/.dropbox because otherwise Dropbox.app was still referencing /Volumes/zDisk/User/myuser/Dropbox. (I was in a kind of deadlock)
This way I could get a fresh ~/Dropbox folder on a APFS (or JHFS+) volume.

Eventually, I found on Dropbox's website some indication that it can't handle external disks and network filesystems.
Dropbox has to capture some disk events

see Dropbox.com : Move a Dropbox folder to a new location

So why is ZFS filesystem not compatible ?

Software versions and params
MacOS 10.14.6 Mojave
name -a

Darwin macpro.home 18.7.0 Darwin Kernel Version 18.7.0: Mon Feb 10 21:08:45 PST 2020; root:xnu-4903.278.28~1/RELEASE_X86_64 x86_64

ZFS v1.9.0
sysctl -a {zfs,spl}

zfs.kext_version: 1.9.4-0
spl.kext_version: 1.9.4-0

ZFS params
zfs get aclmode,aclinherit,xattr,utf8only,normalization,casesensitivity,com.apple.browse,com.apple.ignoreowner,com.apple.mimic_hfs,com.apple.devdisk zDisk/Users/William

NAME PROPERTY VALUE
zDisk/Users/william aclmode passthrough
zDisk/Users/william aclinherit restricted
zDisk/Users/william xattr sa
zDisk/Users/william utf8only on
zDisk/Users/william normalization formD
zDisk/Users/william casesensitivity insensitive
zDisk/Users/william com.apple.browse off
zDisk/Users/william com.apple.ignoreowner off
zDisk/Users/william com.apple.mimic_hfs on
zDisk/Users/william com.apple.devdisk poolonly

to double cross-check, I did another test with carefully applying the chflags / chown / chmod instructions on ZFS Dropbox folder.
No way !

Note : I have the same issue with 2 other users accounts on my rig.

Did some other cross-check test :

As ZFS seems to presents himself as a Disk image (? needs confirmation), I did a test with a regular/plain MacOS DiskImage file mounted in my user space (APFS).

with a Disk image as Dropbox folder, I do not have this sync issue.

So I wonder where the problem is ...
I suspect some MacOS apps need to interact with the filesystem through some event-driven framework.

I encountered other weird phenomena when opening a folder on zfs with some IDE (Textmate.app ; VS Code.app) when a subfolder has been updated by other app (i.e. compiler).
I'll try to document this later.

HTH.... william

my ZFS disk is seen as : diskutil info disk6s1

Partition Type: ZFS Dataset
File System Personality: ZFS
Type (Bundle): zfs
Name (User Visible): ZFS Dataset

OS Can Be Installed: No
Media Type: Generic
Protocol: Disk Image
(...)
Device Location: Internal
Removable Media: Fixed

my DiskImage

Partition Type: 41504653-0000-11AA-AA11-00306543ECAC
File System Personality: APFS
Type (Bundle): apfs
Name (User Visible): APFS
Owners: Disabled
(...)
Media Type: Generic
Protocol: Disk Image
(...)
Device Location: External
Removable Media: Removable
Media Removal: Software-Activated

When it hangs, could you run "sudo spindump" and see if it has stacks stuck