Cannot add folder to smb share

Trying to add a SMB share from a pool that I imported after having to reinstall truenas scale. When trying to create the share I keep getting this error…
Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 211, in call_method
result = await self.middleware.call_with_audit(message[‘method’], serviceobj, methodobj, params, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1529, in call_with_audit
result = await self._call(method, serviceobj, methodobj, params, app=app,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1460, in _call
return await methodobj(*prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/service/crud_service.py”, line 230, in create
return await self.middleware._call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1460, in _call
return await methodobj(*prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/service/crud_service.py”, line 261, in nf
rv = await func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/schema/processor.py”, line 49, in nf
res = await f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/schema/processor.py”, line 179, in nf
return await func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/plugins/smb.py”, line 872, in do_create
verrors.check()
File “/usr/lib/python3/dist-packages/middlewared/service_exception.py”, line 72, in check
raise self
middlewared.service_exception.ValidationErrors: [EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications: McStorage - NFSV4, McStorage/ix-applications - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/catalogs: McStorage - NFSV4, McStorage/ix-applications/catalogs - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/default_volumes: McStorage - NFSV4, McStorage/ix-applications/default_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/k3s: McStorage - NFSV4, McStorage/ix-applications/k3s - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases: McStorage - NFSV4, McStorage/ix-applications/releases - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/charts: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/charts - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/config: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/config - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/dnsmasq: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/dnsmasq - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/charts: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/charts - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/config: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/config - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/transcode: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/transcode - POSIX

Any help with this is much appreciated. Thanks.

Post how you have your pools laid out. SMB share dataset should be a child of the root pool dataset. What version of TrueNAS?

![Screenshot 2025-02-18 212153|300x500]

I think the issue has to do with ACLs that were on my old truenas config.(my ssd bit the dust and no…I did not have a backup :unamused:. I moved a folder in the shell from that McShare folder you see there to a new share and I couldn’t open it due to permissions.

Given the last few lines of the error you seem to have a missmatch of acl types.
Some Datasets in the path seem to have posix acls and others nfsv4.
Take a look at each dataset in the path and adjust the acl types to one, either nfsv4 or posix.

The problem I have here is that dataset ‘McShare’ is not able to be edited by my truenas. What I mean is when I look at datasets in the webgui ‘McShare’ does not show up. I was doing some research and found that you might be able to strip the ACLs through the shell but I am still researching that. I did create a new dataset and I am trying to move the data from the dataset I cannot access(McShare) to the new one but, I am very new to using linux and learning as I go here. If you have any tips for stripping these ACLs through the shell then I would appreciate it.

is McShare the root Dataset or a child Dataset?
Because permissions on the root dataset can’t be changed. Its always owned by root. Only permissions and acl types of child datasets can be changed.

Example:
/mnt/McShare → McShare is the root dataset
/mnt/McShare/Movies → Movies is the child Dataset

McShare is a child of the dataset. The path is as follows /mnt/McStorage/McShare.

I also tried removing the acl from the folder using these commands. # setfacl -b -R McShare/

What’s confusing to me is that the error is for the ix-applications dataset and not McShare

I just tried to add the McStorage as a dataset and got this error…

Error: Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 211, in call_method
result = await self.middleware.call_with_audit(message[‘method’], serviceobj, methodobj, params, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1529, in call_with_audit
result = await self._call(method, serviceobj, methodobj, params, app=app,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1460, in _call
return await methodobj(*prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/service/crud_service.py”, line 230, in create
return await self.middleware._call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1460, in _call
return await methodobj(*prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/service/crud_service.py”, line 261, in nf
rv = await func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/schema/processor.py”, line 49, in nf
res = await f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/schema/processor.py”, line 179, in nf
return await func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/plugins/smb.py”, line 872, in do_create
verrors.check()
File “/usr/lib/python3/dist-packages/middlewared/service_exception.py”, line 72, in check
raise self
middlewared.service_exception.ValidationErrors: [EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications: McStorage - NFSV4, McStorage/ix-applications - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/catalogs: McStorage - NFSV4, McStorage/ix-applications/catalogs - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/default_volumes: McStorage - NFSV4, McStorage/ix-applications/default_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/k3s: McStorage - NFSV4, McStorage/ix-applications/k3s - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases: McStorage - NFSV4, McStorage/ix-applications/releases - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/charts: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/charts - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/config: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/config - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/dnsmasq: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/dnsmasq - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/charts: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/charts - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/config: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/config - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/transcode: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/transcode - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/mcshare: McStorage - NFSV4, McStorage/mcshare - OFF

What about /mnt/McStorage/McShare as share path? that should remove the problem with the ix-application dataset.

This is what I get when trying to set that as a share path…

Error: Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 211, in call_method
result = await self.middleware.call_with_audit(message[‘method’], serviceobj, methodobj, params, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1529, in call_with_audit
result = await self._call(method, serviceobj, methodobj, params, app=app,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1460, in _call
return await methodobj(*prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/service/crud_service.py”, line 230, in create
return await self.middleware._call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1460, in _call
return await methodobj(*prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/service/crud_service.py”, line 261, in nf
rv = await func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/schema/processor.py”, line 49, in nf
res = await f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/schema/processor.py”, line 179, in nf
return await func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/plugins/smb.py”, line 872, in do_create
verrors.check()
File “/usr/lib/python3/dist-packages/middlewared/service_exception.py”, line 72, in check
raise self
middlewared.service_exception.ValidationErrors: [EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications: McStorage - NFSV4, McStorage/ix-applications - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/catalogs: McStorage - NFSV4, McStorage/ix-applications/catalogs - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/default_volumes: McStorage - NFSV4, McStorage/ix-applications/default_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/k3s: McStorage - NFSV4, McStorage/ix-applications/k3s - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases: McStorage - NFSV4, McStorage/ix-applications/releases - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/charts: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/charts - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/config: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/config - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/dnsmasq: McStorage - NFSV4, McStorage/ix-applications/releases/mcpihole/volumes/ix_volumes/dnsmasq - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/charts: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/charts - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/config: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/config - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/transcode: McStorage - NFSV4, McStorage/ix-applications/releases/mcplex/volumes/ix_volumes/transcode - POSIX
[EINVAL] sharingsmb_create.path_local: ACL type mismatch with child mountpoint at /mnt/McStorage/mcshare: McStorage - NFSV4, McStorage/mcshare - OFF

OK, please post screenshots of the ACL permissions of the child datasets.
Since it’s still complaining about an acl missmatch your only option seems to be to change the different acl type to the other one.

Unfortunately I cannot see the ‘McShare’ folder in the list of datasets so there is no way for me to adjust the ACL in truenas. I tested moving a folder from within the ‘McShare’ folder to the ‘mcshare’ data set then reapplied the ACLs recursively and that worked but transferring everything to a new dataset would take a huge amount of time.

So I did some more poking around and found this post that sounds a lot like what I am experiencing…

Even after using the nfs4xdr_setfacl -b command I still can’t get truenas to share the file. I even looked at the ACL file that was being used and it doesn’t have any specific ACLs that should be blocking anything.

I think your problem is the folder? McShare is in the Root dataset, McStorage. All the data in McShare needs to be moved to a Child dataset of McStorage, that is correctly set up for SMB sharing, and then the ACLs fixed?

It might also be a problem to have ‘McShare’ and ‘mcshare’ for Windows

@awalkerix can you take a quick peek at this?

I’m pretty sure the folder is the problem too. It takes forever thought to transfer items from one folder form another in the shell. There are definitely still some ACLs applied to the folder and subfolders within it though because anytime I transfer a folder to a new dataset I cannot access it until I apply the ACLs recursively to the dataset. Then I can access the folder.