Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disabling recycle bin will also affect other vfs objects (fix inside) #197

Closed
xupefei opened this issue Apr 16, 2019 · 1 comment
Closed
Assignees

Comments

@xupefei
Copy link

xupefei commented Apr 16, 2019

Hi,

First, I want to thank you for publishing this nice image.

I found an issue regarding the recycle bin, that turns it off will also disable all vfs objects. This is because the sed in recycle function deletes all lines that contain the word recycle:

recycle() { local file=/etc/samba/smb.conf
    sed -i '/recycle/d; /vfs/d' $file
}

This will delete all three lines below:

   vfs objects = acl_xattr catia fruit recycle streams_xattr
   recycle:keeptree = yes
   recycle:versions = yes

and hence disables other features, e.g. Time Machine which relies on the vfs fruit.

This issue can be fixed by just deleting the substring recycle from the first line, and leaves others unchanged. Here is a fix with a dirty regex:

recycle() { local file=/etc/samba/smb.conf
    sed -i 's/^\(.*vfs.*\)recycle\(.*\)$/\1\2/' $file
}

which will output

   vfs objects = acl_xattr catia fruit  streams_xattr
   recycle:keeptree = yes
   recycle:versions = yes

The last two lines can be left as-is without an impact.

@dperson dperson self-assigned this Jul 7, 2019
@dperson dperson closed this as completed in 8634dfc Jul 7, 2019
@dperson
Copy link
Owner

dperson commented Jul 7, 2019

Thanks for the report, it's been fixed now. Sorry for the delay.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants