SAMBA Veto Files

Ed_

Cadet
Joined
Sep 27, 2016
Messages
5
I need to use the smb.conf parameter "veto files". How do I do this in Cobia?
 

Kris Moore

SVP of Engineering
Administrator
Moderator
iXsystems
Joined
Nov 12, 2015
Messages
1,471
Interesting, what is the use-case for needing Veto files on TrueNAS? First request for this I've seen :)
 

DL_

Cadet
Joined
Apr 2, 2024
Messages
3
Interesting, what is the use-case for needing Veto files on TrueNAS? First request for this I've seen :)
Use Case: To prevent macos from arbitrarily creating a number of non-critical metadata files it uses in it's file system (like .thumb) commonly known as DOT files.

Typical SMB extra configuraiton:

veto files = /._*/.DS_Store/.AppleDouble/.Trashes/.TemporaryItems/.Spotlight-V100/
delete veto files = yes

There doesn't appear to be an 'Extra' configuration in the GUI. If the smb.conf (assuming its presence in TrueNAS Scale) file is modified directly, would this configuration be revoked in a future TrueNAS update?
 

Kris Moore

SVP of Engineering
Administrator
Moderator
iXsystems
Joined
Nov 12, 2015
Messages
1,471
Something we should look at supporting native then, if there is enough benefit for other users. Can you put in a suggestion ticket into Jira so this doesn't get lost on us?
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
I don't think vetoing files is a good solution to this personally. It's just asking to in the future have undefined behavior from clients that automatically create them and expect them to be there. It's better to just configure your client not to create the files to begin with.
 

DL_

Cadet
Joined
Apr 2, 2024
Messages
3
@Kris. As a mac, windows and linux user, I have had to always add this to my smb config (and syncthing for that matter) otherwise when I look at the share in linux and windows it is full of these extra metadata files. Here is what it looks like in a non-Apple environment.


@anodos
I recognize your point and I do partly agree but my counter points are
- extra parameters is a valid function of samba and having a open text block in the GUI would be useful for any advance parameter an admin may want to use
- the OS vendor can overwrite the settings at any update. Removing those files at scale after they are written is also risky. I prefer the option of redundancy.
 

PhilD13

Patron
Joined
Sep 18, 2020
Messages
203
I agree with @anodos. I'm not sure it's a good idea at all. If it is an option flag or parameter add on fine, but I wouldn't make it automatic or default or even a checkbox. I use various photo processing programs and plugins and some do depend upon certain dot and meta files being available and accurate. I certainly would not want to process 60,000+ raw photo files from a job only to find out they are missing required files because of some SMB option decided to strip files I expected to be written.

Windows, Mac and Linux do allow hiding these types of flies from view. That is an easy way to hide normal files from view from others that don't have ahe ability to show hudden files. We sometimes do that at work to hide very temporary directories and files.
 

DL_

Cadet
Joined
Apr 2, 2024
Messages
3
I absolutely agree, and never had the opinion or expectation to have this as an automatic or default setting for the reason you pointed out; use cases are unique to the user. I stand corrected in calling those files benign. As you pointed out, instead I will rephrase that their usefulness is case by case which is why I DO NOT believe this should be a default setting or a simple check box.

I propose an open text box entry field in the GUI used to enter special parameters that are pushed into the smb.conf on the backend. These parameters would need to be type out in the text box field. Most people may ignore that field when setting up samba. Those with specific samba setting requirement, however, can add those entries into the text field. Another benefit of a text field is that the administrator would also need to know how to configure that parameter inside of smb.conf in order to use it thereby an extra parameter cannot be incidentally used.
 

PhilD13

Patron
Joined
Sep 18, 2020
Messages
203
Sure, an flag/additional parameter field is fine where additional setup parameters if needed or wanted could be added and is what generally is available in various setups already in Truenas. This would satisfy the various use cases that may need and additional specialized setup.
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
@Kris. As a mac, windows and linux user, I have had to always add this to my smb config (and syncthing for that matter) otherwise when I look at the share in linux and windows it is full of these extra metadata files. Here is what it looks like in a non-Apple environment.


@anodos
I recognize your point and I do partly agree but my counter points are
- extra parameters is a valid function of samba and having a open text block in the GUI would be useful for any advance parameter an admin may want to use
- the OS vendor can overwrite the settings at any update. Removing those files at scale after they are written is also risky. I prefer the option of redundancy.

Those are apple double files to represent the fork... I'm not sure that's necessary on the latest SMB versions with OSX.
 
Top