How to stop .DS_STORE files and ._ files being created in shares (SERVER SIDE)


Recommended Posts

19 hours ago, MothyTim said:

Unraid smb set to hide dot files but windows still shows them?

 

On 6/27/2016 at 5:44 PM, John_M said:

If Samba is set up to hide the dot files but Windows is set to display them, they should appear greyed out.

To hide them completely you have to tell Windows not to display them. See the table below:

 

                              Samba hide             Samba show

Windows hide          Invisible                  Invisible

Windows show        Greyed out              Visible

 

I still maintain that I'm fundamentally opposed to the idea of configuring a file server to refuse to store certain files. It's much better to configure Macintosh clients not to create the annoying files on shared network storage in the first place. See here, for example: https://www.tekrevue.com/tip/stop-ds-store-files-mac-network/

defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool TRUE

 

Edited by John_M
Added more info
  • Like 2
Link to comment
  • 8 months later...
  • 2 years later...

Adding

 

veto files = /._*/.DS_Store/._.DS_Store/
hide files = /._*/.DS_Store/._.DS_Store/
delete veto files = yes

to my smb-extra.conf does not give me the desired result.

I still see the files I want to hide on my array and unassigned devices.
Even after array restart and server reboot.

Any ideas why?

My smb-extra.conf looks like that:
 

#unassigned_devices_start
#Unassigned devices share includes
   include = /tmp/unassigned.devices/smb-settings.conf
#unassigned_devices_end

veto files = /._*/.DS_Store/._.DS_Store/
hide files = /._*/.DS_Store/._.DS_Store/
delete veto files = yes

[rootshare]
path = /mnt/user
comment =
browseable = yes
valid users = admin
write list = admin
vfs objects =

 

Link to comment
3 hours ago, derpuma said:

Adding

 

veto files = /._*/.DS_Store/._.DS_Store/
hide files = /._*/.DS_Store/._.DS_Store/
delete veto files = yes

to my smb-extra.conf does not give me the desired result.

I still see the files I want to hide on my array and unassigned devices.
Even after array restart and server reboot.

Any ideas why?

My smb-extra.conf looks like that:
 

#unassigned_devices_start
#Unassigned devices share includes
   include = /tmp/unassigned.devices/smb-settings.conf
#unassigned_devices_end

veto files = /._*/.DS_Store/._.DS_Store/
hide files = /._*/.DS_Store/._.DS_Store/
delete veto files = yes

[rootshare]
path = /mnt/user
comment =
browseable = yes
valid users = admin
write list = admin
vfs objects =

 

There is currently a bug in samba.

https://bugzilla.samba.org/show_bug.cgi?id=15143

veto files isn’t working until this bug is fixed.

  • Like 1
Link to comment
24 minutes ago, wgstarks said:

There is currently a bug in samba.

https://bugzilla.samba.org/show_bug.cgi?id=15143

veto files isn’t working until this bug is fixed.


Thanks for the hint. So I guess hide files isn'T working too.
This might be also the reason for my Samba syslog errors...
 

Oct 12 13:09:49 Tower  smbd[11653]:   ===============================================================
Oct 12 13:09:49 Tower  smbd[11653]: [2022/10/12 13:09:49.358392,  0] ../../lib/util/fault.c:174(smb_panic_log)
Oct 12 13:09:49 Tower  smbd[11653]:   INTERNAL ERROR: smbd_scavenger_parent_dead in pid 11653 (4.17.0)
Oct 12 13:09:49 Tower  smbd[11653]: [2022/10/12 13:09:49.358403,  0] ../../lib/util/fault.c:178(smb_panic_log)
Oct 12 13:09:49 Tower  smbd[11653]:   If you are running a recent Samba version, and if you think this problem is not yet fixed in the latest versions, please consider reporting this bug, see https://wiki.samba.org/index.php/Bug_Reporting
Oct 12 13:09:49 Tower  smbd[11653]: [2022/10/12 13:09:49.358411,  0] ../../lib/util/fault.c:183(smb_panic_log)
Oct 12 13:09:49 Tower  smbd[11653]:   ===============================================================

 

Edited by derpuma
Link to comment
  • 8 months later...

Super late to the party on this one, brand new unraid user.. trying to learn -

 

I've spent about a day on this already trawling to forums and youtube videos - and wrestling with different potential solutions...

these mac 'double files'/forks are doing my head in and make everything on the server a mess - if only there was an easy switch to hide them all in the array i think i could live - although it still feels messy knowing that they are there (granted they take up minimal space) would rather not go down the path of routinely spinning up disks to delete later.

 

I think i've now managed to get all the prevent new 'duplicate' ._filenames using the veto commands above - but i'm still getting constant .DS_Store files created when viewing from mac.  I'm also reading the bug mentioned above has now been fixed?

 

I'm also looking for a way to prevent these files ._filenames and .DS_Store files copying across when i plug in drives directly to the array as unassigned devices - I need to load something like 60TB from usb drives onto the new server.. so much faster if i can plug them in directly...  i.e 'copy the whole drive please, but ignore any file or folder starting with a '.' '?

 

any help 'dumbed down to newie level - greatly appreciated!

 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.