TrueNas scale cannot access SMB share

NewToTrueNas

Cadet
Joined
Dec 4, 2022
Messages
8
As the title says.... I've some problems with getting an SMB share to work.
This is my first attempt at setting up a TrueNas installation, so please try to add a link or something pointing me in the correct direction.

What I've done so far:
- Install TrueNas (TrueNAS-SCALE-22.02.4)
- Setup a single storage pool with 6 drives as rz2
- Added local group
- Added local user and set the new group as primary user group
-- (Samba Auth enabled for both)
- Created new dataset with share type SMB
- Edited the ACL of the new dataset and added the user group with full control
- Created a new SMB share for the new dataset

I've documented all steps with screenshots (1-10).
When trying to access the share from my Win10 machine, get a Windows cannot access \\IP\name error message.
 

Attachments

  • 01_creategroup.JPG
    01_creategroup.JPG
    59.4 KB · Views: 400
  • 02_createuser.JPG
    02_createuser.JPG
    82.4 KB · Views: 226
  • 03_createuser.JPG
    03_createuser.JPG
    77.1 KB · Views: 226
  • 04_createdataset.JPG
    04_createdataset.JPG
    79.8 KB · Views: 226
  • 05_createdataset.JPG
    05_createdataset.JPG
    77.9 KB · Views: 209
  • 06_configureACL.JPG
    06_configureACL.JPG
    101.6 KB · Views: 221
  • 07_dspermissions.JPG
    07_dspermissions.JPG
    106.8 KB · Views: 234
  • 08_createshare.JPG
    08_createshare.JPG
    69.8 KB · Views: 206
  • 09_tryconnect.JPG
    09_tryconnect.JPG
    125.2 KB · Views: 245
  • 10_failed.JPG
    10_failed.JPG
    127.6 KB · Views: 303

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
What about the root of the server? \\192.168.1.118 without the share path?
 

NewToTrueNas

Cadet
Joined
Dec 4, 2022
Messages
8
Just \\192.168.1.118 results in the same "windows cannot access" error but explorer does not show a login promt.
 
Joined
Oct 22, 2019
Messages
3,641
Did you modify the permissions of the root dataset by any chance?

Code:
getfacl /mnt/Pool0

And,
Code:
ls -la /mnt/Pool0
 

NewToTrueNas

Cadet
Joined
Dec 4, 2022
Messages
8
I thought about that. I did not (at least intentionally) change anything about the root/pool.

But I was not sure, so I reset my system and setup everything again (exactly the same as the first time). It still does not work. (Please note, I made as small "mistake" and gave the pool another name...)


I've run the commands you posted in the Shell (Web UI). The results are attached as screenshot. Sorry about that, I was not able to copy the output from the shell. Copy or paste requires a "insert key" which my laptop does not have :( and copy via F12 insect element is not en option since the output is rendered inside a canvas.
 

Attachments

  • test.png
    test.png
    50.6 KB · Views: 304
  • permissionsPool0.png
    permissionsPool0.png
    381.9 KB · Views: 264

NewToTrueNas

Cadet
Joined
Dec 4, 2022
Messages
8
Btw. here is the output from the client side:

> Test-NetConnection -ComputerName 192.168.1.118 -CommonTCPPort SMB

ComputerName : 192.168.1.118
RemoteAddress : 192.168.1.118
RemotePort : 445
InterfaceAlias : Wi-Fi
SourceAddress : 192.168.1.116
TcpTestSucceeded : True


> net view \\192.168.1.118
System error 5 has occurred.

Access is denied.
 

Attachments

  • testconn.png
    testconn.png
    182.1 KB · Views: 267
Joined
Oct 22, 2019
Messages
3,641
What about on this newly reset system:
Code:
getfacl /mnt/Pool-0/d0
 

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
I've run the commands you posted in the Shell (Web UI).
You should probably set up SSH ASAP. The Web shell is terrible.

As for your immediate issue, make a (semi-)real user (not root!) the owner of any datasets that will be shared.
 
Joined
Oct 22, 2019
Messages
3,641
Here the output.
That doesn't look right.

Is the ACL you configured in the GUI not being applied? :oops:

According to those permissions, it's no wonder your user cannot access the SMB share from Windows.

@anodos is more familiar with the ACL-side of things for TrueNAS.
 

NewToTrueNas

Cadet
Joined
Dec 4, 2022
Messages
8
@Ericloewe I created a new user and assigned that user as owner of the dataset `d0`.

@winnielinnie I've run the command again after changing the user of the dataset. But it still looks the same (not that I expected any changes).

I've documented everything by screenshots...
 

Attachments

  • 2022-12-04 23_56_33-Users - 192.168.1.118.png
    2022-12-04 23_56_33-Users - 192.168.1.118.png
    605.7 KB · Views: 251
  • 2022-12-04 23_56_42-Users - 192.168.1.118.png
    2022-12-04 23_56_42-Users - 192.168.1.118.png
    605.8 KB · Views: 189
  • 2022-12-04 23_57_13-Edit ACL - 192.168.1.118.png
    2022-12-04 23_57_13-Edit ACL - 192.168.1.118.png
    788.8 KB · Views: 181
  • 2022-12-04 23_58_46-Shell - 192.168.1.118.png
    2022-12-04 23_58_46-Shell - 192.168.1.118.png
    439.5 KB · Views: 168
  • 2022-12-04 23_59_05-Storage - 192.168.1.118.png
    2022-12-04 23_59_05-Storage - 192.168.1.118.png
    809.9 KB · Views: 159
  • 2022-12-04 23_59_19-Share ACL - 192.168.1.118.png
    2022-12-04 23_59_19-Share ACL - 192.168.1.118.png
    706.5 KB · Views: 150
  • 2022-12-05 00_03_30-Storage - 192.168.1.118.png
    2022-12-05 00_03_30-Storage - 192.168.1.118.png
    744.7 KB · Views: 298
Joined
Oct 22, 2019
Messages
3,641
Wait, my bad, since you're on SCALE:
Code:
nfs4_getfacl /mnt/Pool-0

and
Code:
nfs4_getfacl /mnt/Pool-0/d0
 
Joined
Oct 22, 2019
Messages
3,641
Can you try this?

From Windows 10, in the CMD or Powershell command-line:
Code:
net use /d /y *


Then even for good measure, reboot the computer and try to access the SMB share again?
 

NewToTrueNas

Cadet
Joined
Dec 4, 2022
Messages
8
I run both commands.
The first one did not work; error: "Operation to request attributes not supported". I probably finally have to setup SSH and stop using the web shell (will try that tomorrow or more correct this morning).

On the Windows side: I do not have any network drives mapped or credentials stored for the share. I tried to reboot the client machine and also tried to access the share from 2 difference PCs Win10 and Win11. Nothing worked... BUT after running your script, I was able to access the share.
Thank you very much!
 

Attachments

  • output.png
    output.png
    468.6 KB · Views: 355
Top