![CIFS 权限被拒绝。尝试了我能想到的一切](https://linux22.com/image/223453/CIFS%20%E6%9D%83%E9%99%90%E8%A2%AB%E6%8B%92%E7%BB%9D%E3%80%82%E5%B0%9D%E8%AF%95%E4%BA%86%E6%88%91%E8%83%BD%E6%83%B3%E5%88%B0%E7%9A%84%E4%B8%80%E5%88%87.png)
//192.168.1.64/d /media/d cifs credentials=/home/nick/.smbcredentials,uid=nick,gid=media,file_mode=0777,dir_mode=0777,nofail,user 0 0
这是我安装后的共享的 ls-l:
drwxrwxrwx 2 nick media 0 Jan 20 2023 Blurays2
drwxrwxrwx 2 nick media 0 Jul 26 18:37 cache
drwxrwxrwx 2 nick media 0 Feb 5 2021 'Childrens Movies2'
drwxrwxrwx 2 nick media 0 Jan 22 2023 Movies2
drwxrwxrwx 2 nick media 0 Aug 5 22:34 temp-movies
drwxrwxrwx 2 nick media 0 Jul 11 14:08 tv_shows
这是我通过 smb.conf 文件从服务器获取的共享信息
[d]
path = /media/nick/Backup Drive/
valid users = share, nick
browsable = yes
writable = yes
read only = no
force create mode = 0666
force directory mode = 0777
谁能看到我到底错过了什么吗?
答案1
您需要确保/media/nick/Backup Drive
您的目标用户可以访问它share
并且nick
.
如果没有其他人直接使用服务器,您可以选择完全放宽文件系统权限并让 Samba 来管理访问控制:
chmod a=rwx '/media/nick/Backup Drive'