您尚未登录。

#1 2023-11-12 05:15:13

bunny
会员
注册时间: 2023-10-23
帖子: 8
个人网站

[Solved]关于在archlinux构建samba服务器遇到的用户问题

遇到一个很棘手很棘手的问题我samba想创建第二个用户 创建好了好了现在登录不到文件夹 显示没权限 可是虽然是另一个用户的目录 但是权限我都设置好了 而且 我把wlmosv和uu都放在了一个组里面 现在uu你。能登陆进去 但是就是访问不了data 这是我的文件
[rule]
comment = sharefolder browseable =yes
path = /home/wlmosv/sambafloder create mask = 0777
directory mask = 0777 writable = yes
valid users = wlmosv read only = yes public = yes
available = yes
[data]
comment = sharedd
path = /home/wlmosv/data valid users = @dataaccess public = no
browseable = yes writable = yes

其中的uu能登陆 但是不能访问两个文件夹中的任何一个 反正就是提示权限不够 wlmosv只要登录就可以访问两个文件夹 对 wlmosv。可以我不知道为什么
我甚至把两个用户放在了同一个用户组 还给data文件夹给了可执行的权限
>groups uu dataaccess vu

> groups wlmosv
wheel docker vboxusers dataaccess wlmosv

求助大佬解惑 困扰我一晚上

最近编辑记录 bunny (2023-11-13 16:37:14)


我是一个平平无奇的archer

离线

#2 2023-11-12 11:28:58

依云
会员
所在地: a.k.a. 百合仙子
注册时间: 2011-08-21
帖子: 8,916
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

一没有操作时的具体命令,二没有出问题时的报错信息,天知道都发生了啥哟。

离线

#3 2023-11-12 23:21:46

bunny
会员
注册时间: 2023-10-23
帖子: 8
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

这是我的配置文件
FluxBB bbcode 测试

现在samba能正常启动 使用命令

systemctl status smb.service

FluxBB bbcode 测试
neutral
这里是/var/log/samba/log.smbd 的部分输出

[2023/11/12 04:48:48.062817,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:48.063155,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:48.072287,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:48.072498,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:48.085141,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:48.091841,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:48.100224,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:48.113336,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:48:49.953659,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.095165,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.095582,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.106035,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.106262,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.120668,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.131208,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.139057,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:20.149184,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:50:21.813278,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:53:50.962806,  0] ../../source3/smbd/server.c:1746(main)
  smbd version 4.19.2 started.
  Copyright Andrew Tridgell and the Samba Team 1992-2023
[2023/11/12 04:54:11.416391,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:11.416775,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:11.430018,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:11.436792,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:11.443317,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:11.450432,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:11.459483,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:11.466743,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:54:13.139620,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.894357,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.894928,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.905084,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.905374,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.912563,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.919646,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.927278,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:43.934309,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 04:55:46.286222,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 2 groups: 1009 1010
[2023/11/12 05:00:48.717253,  0] ../../source3/smbd/server.c:1746(main)
  smbd version 4.19.2 started.
  Copyright Andrew Tridgell and the Samba Team 1992-2023
[2023/11/12 05:01:11.851307,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:11.851750,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:11.979003,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:11.979303,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:11.992890,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:12.004455,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:12.014620,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:12.067425,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:13.694315,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.535338,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.535393,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.548882,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.551747,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.560246,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.568456,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.576217,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:14.585712,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:15.946751,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.872815,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.873180,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.880456,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.886251,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.894275,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.906030,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.916578,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:16.923993,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:01:19.328256,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.363575,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.364067,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.490933,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.491296,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.498990,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.506035,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.515756,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:35.647179,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:37.018069,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:37.994400,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:37.994679,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:38.005174,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:38.005242,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:38.017245,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:38.023577,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:38.031171,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:38.042059,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:02:39.512573,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:23.352855,  0] ../../source3/smbd/server.c:1746(main)
  smbd version 4.19.2 started.
  Copyright Andrew Tridgell and the Samba Team 1992-2023
[2023/11/12 05:03:43.408079,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:43.408538,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:43.538867,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:43.538987,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:43.551458,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:43.574310,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:43.584259,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:43.591455,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:45.040288,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/data) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.115590,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.115710,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.122879,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.127577,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.133862,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.146906,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.154417,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:46.161500,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:47.491518,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.491906,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.491990,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.501161,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.501249,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.508668,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.516297,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.530278,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:48.536847,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 05:03:50.927367,  0] ../../source3/smbd/smb2_service.c:117(chdir_current_service)
  chdir_current_service: vfs_ChDir(/home/wlmosv/sambafloder) failed: Permission denied. Current token: uid=1006, gid=1009, 3 groups: 1009 1010 1011
[2023/11/12 18:21:23.867937,  0] ../../source3/smbd/server.c:1746(main)
  smbd version 4.19.2 started.cores     log.rpcd_classic   log.rpcd_fsrvp  log.rpcd_mdssvc   log.rpcd_winreg  log.samba-dcerpcd
log.nmbd  log.rpcd_epmapper  log.rpcd_lsad   log.rpcd_spoolss  log.samba        log.smbd

  Copyright Andrew Tridgell and the Samba Team 1992-2023
[2023/11/12 18:57:38.885123,  0] ../../source3/smbd/fake_file.c:121(dosmode_from_fake_filehandle)
  dosmode_from_fake_filehandle: Unexpected fake_file_handle: 3
[2023/11/12 18:57:38.885904,  0] ../../lib/util/fault.c:303(log_stack_trace)
  BACKTRACE: 25 stack frames:
   #0 /usr/lib/samba/libgenrand-samba4.so(log_stack_trace+0x33) [0x7f3e2771a183]
   #1 /usr/lib/samba/libsmbd-base-samba4.so(dosmode_from_fake_filehandle+0x2b) [0x7f3e27aee09b]
   #2 /usr/lib/samba/libsmbd-base-samba4.so(fdos_mode+0x96) [0x7f3e27ac46a6]
   #3 /usr/lib/samba/libsmbd-base-samba4.so(+0xb1891) [0x7f3e27b0c891]
   #4 /usr/lib/samba/libsmbd-base-samba4.so(smbd_smb2_request_process_close+0x271) [0x7f3e27b0cd41]
   #5 /usr/lib/samba/libsmbd-base-samba4.so(smbd_smb2_request_dispatch+0x1b4f) [0x7f3e27b0326f]
   #6 /usr/lib/samba/libsmbd-base-samba4.so(+0xa9b97) [0x7f3e27b04b97]
   #7 /usr/lib/libtevent.so.0(tevent_common_invoke_fd_handler+0x96) [0x7f3e276aec96]
   #8 /usr/lib/libtevent.so.0(+0xecb8) [0x7f3e276b2cb8]
   #9 /usr/lib/libtevent.so.0(+0x69bd) [0x7f3e276aa9bd]
   #10 /usr/lib/libtevent.so.0(_tevent_loop_once+0x96) [0x7f3e276acf06]
   #11 /usr/lib/libtevent.so.0(tevent_common_loop_wait+0x1c) [0x7f3e276ad03c]
   #12 /usr/lib/libtevent.so.0(+0x6a2d) [0x7f3e276aaa2d]
   #13 /usr/lib/samba/libsmbd-base-samba4.so(smbd_process+0x974) [0x7f3e27af0104]
   #14 smbd: client [192.168.180.123](+0x8ae1) [0x55d1d691eae1]
   #15 /usr/lib/libtevent.so.0(tevent_common_invoke_fd_handler+0x96) [0x7f3e276aec96]
   #16 /usr/lib/libtevent.so.0(+0xecb8) [0x7f3e276b2cb8]
   #17 /usr/lib/libtevent.so.0(+0x69bd) [0x7f3e276aa9bd]
   #18 /usr/lib/libtevent.so.0(_tevent_loop_once+0x96) [0x7f3e276acf06]
   #19 /usr/lib/libtevent.so.0(tevent_common_loop_wait+0x1c) [0x7f3e276ad03c]
   #20 /usr/lib/libtevent.so.0(+0x6a2d) [0x7f3e276aaa2d]
   #21 smbd: client [192.168.180.123](main+0x1458) [0x55d1d691c478]
   #22 /usr/lib/libc.so.6(+0x27cd0) [0x7f3e274e9cd0]
   #23 /usr/lib/libc.so.6(__libc_start_main+0x8a) [0x7f3e274e9d8a]
   #24 smbd: client [192.168.180.123](_start+0x25) [0x55d1d691cf15]

这是samba用户可用性:

sudo pdbedit -L -w
smbuser:4294967295:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:32ED87BDB5FDC5E9CBA88547376818D4:[U          ]:LCT-654F68E7:
wlmosv:1000:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:32ED87BDB5FDC5E9CBA88547376818D4:[U          ]:LCT-654F71AC:
uu:1006:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:E1A692BD23BDE99B327756E59308B4F8:[U          ]:LCT-654FE902:

以下是samba用户拥有的访问权限

 › sudo pdbedit -L -v
---------------
Unix username:        smbuser
NT username:          
Account Flags:        [U          ]
User SID:             S-1-5-21-2182842857-3057283826-3025637009-1000
Failed to find a Unix account for smbuser
Primary Group SID:    (NULL SID)
Full Name:            
Home Directory:       \\WLMOSV\smbuser
HomeDir Drive:        
Logon Script:         
Profile Path:         \\WLMOSV\smbuser\profile
Domain:               WLMOSV
Account desc:         
Workstations:         
Munged dial:          
Logon time:           0
Logoff time:          三, 06 2月 2036 23:06:39 CST
Kickoff time:         三, 06 2月 2036 23:06:39 CST
Password last set:    六, 11 11月 2023 19:43:35 CST
Password can change:  六, 11 11月 2023 19:43:35 CST
Password must change: never
Last bad password   : 0
Bad password count  : 0
Logon hours         : FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
---------------
Unix username:        wlmosv
NT username:          
Account Flags:        [U          ]
User SID:             S-1-5-21-2182842857-3057283826-3025637009-1001
Primary Group SID:    S-1-5-21-2182842857-3057283826-3025637009-513
Full Name:            
Home Directory:       \\WLMOSV\wlmosv
HomeDir Drive:        
Logon Script:         
Profile Path:         \\WLMOSV\wlmosv\profile
Domain:               WLMOSV
Account desc:         
Workstations:         
Munged dial:          
Logon time:           0
Logoff time:          三, 06 2月 2036 23:06:39 CST
Kickoff time:         三, 06 2月 2036 23:06:39 CST
Password last set:    六, 11 11月 2023 20:21:00 CST
Password can change:  六, 11 11月 2023 20:21:00 CST
Password must change: never
Last bad password   : 0
Bad password count  : 0
Logon hours         : FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
---------------
Unix username:        uu
NT username:          
Account Flags:        [U          ]
User SID:             S-1-5-21-2182842857-3057283826-3025637009-1003
Primary Group SID:    S-1-5-21-2182842857-3057283826-3025637009-513
Full Name:            
Home Directory:       \\WLMOSV\uu
HomeDir Drive:        
Logon Script:         
Profile Path:         \\WLMOSV\uu\profile
Domain:               WLMOSV
Account desc:         
Workstations:         
Munged dial:          
Logon time:           0
Logoff time:          三, 06 2月 2036 23:06:39 CST
Kickoff time:         三, 06 2月 2036 23:06:39 CST
Password last set:    日, 12 11月 2023 04:50:10 CST
Password can change:  日, 12 11月 2023 04:50:10 CST
Password must change: never
Last bad password   : 0
Bad password count  : 0
Logon hours         : FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF

现在最主要的问题就是wlmosv用户能访问配置文件中的两个文件夹 但是uu却不行  我尝试给data目录添加权限 但是还是没有用。可以看到两个文件夹的权限是一样的都可以写入读取保存的

 ›  ls -l data sambafloder 
data:
总计 4
drwxrwxrwx 2 wlmosv wlmosv 4096 11月12日 04:27 ss

sambafloder:
总计 4
drwxrwxrwx 2 wlmosv wlmosv 4096 11月12日 19:04 datatest.txt

求助大佬帮忙啊啊 我真的不知道是什么问题了 wlmosv和uu这两个用户也是在同一个组里面的

› groups wlmosv   
wheel docker vboxusers dataaccess sambashare wlmosv
┌─────────────────────────────────────────────────────────────────────────────────────────────────────────────────
└  ~
 › groups uu    
dataaccess sambashare uu

hmm hmm hmm 如果大家还需要知道任何日志或者相关的配置文件 我会在收到贴字看到的第一时间回复 感谢


我是一个平平无奇的archer

离线

#4 2023-11-13 10:46:26

依云
会员
所在地: a.k.a. 百合仙子
注册时间: 2011-08-21
帖子: 8,916
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

看一下以下命令的输出:

ls -ld /home /home/wlmosv /home/wlmosv/data
id 1006
grep -E '1009|1010' /etc/group

离线

#5 2023-11-13 14:14:41

bunny
会员
注册时间: 2023-10-23
帖子: 8
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

这是ls -ld /home /home/wlmosv /home/wlmosv/data的输出

ls -ld /home /home/wlmosv /home/wlmosv/data
id 1006
grep -E '1009|1010' /etc/group
drwxr-xr-x  6 root   root       4096 11月12日 02:25 /home
drwx------ 69 wlmosv wlmosv     4096 11月13日 14:12 /home/wlmosv
drwxrwxrwx  3 wlmosv dataaccess 4096 11月12日 04:27 /home/wlmosv/data
uid=1006(uu) gid=1009(uu) 组=1009(uu),1010(dataaccess),1011(sambashare)
uu:x:1009:
dataaccess:x:1010:wlmosv,uu

我是一个平平无奇的archer

离线

#6 2023-11-13 14:23:13

bunny
会员
注册时间: 2023-10-23
帖子: 8
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

我应该把权限设置到data为777之类的吗 emmm mad


我是一个平平无奇的archer

离线

#7 2023-11-13 14:30:55

bunny
会员
注册时间: 2023-10-23
帖子: 8
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

另外附上uu用户的权限查看

/home
 › id uu
uid=1006(uu) gid=1009(uu) 组=1009(uu),1010(dataaccess),1011(sambashare)

我是一个平平无奇的archer

离线

#8 2023-11-13 14:47:25

依云
会员
所在地: a.k.a. 百合仙子
注册时间: 2011-08-21
帖子: 8,916
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

chmod a+x /home/wlmosv

/home/wlmosv 这个目录 uu 进不去。

离线

#9 2023-11-13 16:31:38

bunny
会员
注册时间: 2023-10-23
帖子: 8
个人网站

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

解决了!正如你所说  我通过设置了/home/wlmosv的权限之后 可以了 不过我注意到此时uu还是能访问到sambafloder文件夹 原因是在配置文件里 我把wlmosv的rule配置文件里面的valid users 设置成了wlmosv和uu相同组的dataaccess组 现在我改变了wlmosv对于的rule文件 变成只允许wlmosv访问 这样wlmosv就只能访问wlmosv的文件夹 uu就只能访问uu的data文件夹了 非常感谢!!:p tongue tongue
附上更新后的samba配置文件

[global]
# 全局Samba设置

[rule]
comment = sharefolder
browseable = yes
path = /home/wlmosv/sambafloder
create mask = 0777
directory mask = 0777
writable = yes
valid users = wlmosv  # 允许sambashare组的用户访问
read only = no
public = yes
available = yes

[data]
comment = sharedd
path = /home/wlmosv/data
valid users = uu  # 仅允许用户uu访问
public = no
browseable = yes
writable = yes
create mask = 0777
directory mask = 0777
read only = no

非常感谢帮助! smile  smile  smile


我是一个平平无奇的archer

离线

#10 2024-02-29 00:28:03

evilred
会员
注册时间: 2024-02-29
帖子: 1

Re: [Solved]关于在archlinux构建samba服务器遇到的用户问题

依云 说:

chmod a+x /home/wlmosv

/home/wlmosv 这个目录 uu 进不去。

chmod a+x /home 解决了我的samba没有权限的问题,感谢

离线

页脚