New to TrueNAS and I already tested but getting permission denied when mounting a truenas share. CIFS is installed on ubuntu
Trying to hook a network share to an ubuntu machine. I’m using this guide “mount-cifs-shares-permanently” at the ubuntu server doc site, following the steps for a credentials file.
what’s in credentials > home directory for user that i made: /mnt/data/fs1/books
When checking users and the users permissions they have r/w and execute on the folder books.
TrueNAS audit logs show NT_STATUS_WRONG_PASSWORD
Here are the errors on the ubuntu server:
mount error(13): Permission denied
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg)
checking dmesg shows
[ 8.762849] netfs: FS-Cache loaded
[ 8.824717] Key type cifs.spnego registered
[ 8.824737] Key type cifs.idmap registered
[ 8.825423] CIFS: No dialect specified on mount. Default has changed to a more secure dialect, SMB2.1 or later (e.g. SMB3.1.1), from CIFS (SMB1). To use the less secure SMB1 dialect to access old servers which do not support SMB3.1.1 (or even SMB3 or SMB2.1) specify vers=1.0 on mount.
[ 8.825426] CIFS: Attempting to mount //IP Address/books
[ 8.855749] CIFS: Status code returned 0xc000006d STATUS_LOGON_FAILURE
[ 8.855939] CIFS: VFS: \\IP Address Send error in SessSetup = -13
[ 8.856290] CIFS: VFS: cifs_mount failed w/return code = -13
[ 8.962774] EDID block 0 is all zeroes
[ 9.905910] EDID block 0 is all zeroes
[ 11.231731] EDID block 0 is all zeroes
[ 12.208771] EDID block 0 is all zeroes
[ 241.355195] CIFS: enabling forceuid mount option implicitly because uid= option is specified
[ 241.355198] CIFS: enabling forcegid mount option implicitly because gid= option is specified
[ 241.355199] CIFS: Attempting to mount //IP Address/books
[ 241.359314] CIFS: Status code returned 0xc000006d STATUS_LOGON_FAILURE
[ 241.359334] CIFS: VFS: \\IP Address Send error in SessSetup = -13
[ 241.359366] CIFS: VFS: cifs_mount failed w/return code = -13
mounting the root dataset is not permitted, becaue it’s owned by root and root cant be used to acces smb shares.
You have to create a child dataset, create a dedicated user, edit the permissions on the cild dataset and then mount the child dataset.
Did you create share on your truenas from the shell? If so, you should not. Almost all settings within truenas should be made from the GUI.
Warning: the supported mechanisms for making configuration changes
are the TrueNAS WebUI, CLI, and API exclusively. ALL OTHERS ARE
NOT SUPPORTED AND WILL RESULT IN UNDEFINED BEHAVIOR AND MAY
RESULT IN SYSTEM FAILURE.
Ok. I think I understood the problem. You created a dataset, and gave permissions for it. This is all “internal” (or better said, inter-machine) linux stuff.
For the sake of it being accessible via SMB over the network, you must create an SMB share of this very dataset. You should take a look at this doc.
hmm for dataset permissions, the only options on that window are to set an owner or add a group. no option to add a user for some reason.
a questions, so is adding the user to that folder with r/w and execute under credentials not enough. I used to manage Active directory in the past and when giving permissions you could do it via a group or by directly assigning the user.
So direct user assignment wont work in truenas? just trying to understand, thanks