Quantcast
Channel: [EN] Enduser support
Viewing all articles
Browse latest Browse all 10525

Use Samba as non root

$
0
0

Hi,

I'm trying to configure Samba on my ET8000 to offer shares without using the root user.

First I added two new user accounts (adduser), then I added the user to the Samba data base (smbpasswd -a).

For the first changes in the Samba config I changed to "security = user" and changed the "valid users" of one share.

cat /etc/samba/smb.conf
[global]
   load printers = no
   guest account = root
   log file = /tmp/smb.log
   log level = 1
   security = user
   encrypt passwords = yes
   server string = Fileserver
   workgroup = Anstandswauwau
   netbios name = %h
   case sensitive=yes
   preserve case=yes
   short preserve case=yes
   socket options = TCP_NODELAY
   preferred master = yes
#   oplocks = no

#[Root]
#  comment = Everything - take care!
#  path = /
#  read only = no
#  public = yes
#  guest ok = yes

[Harddisk]
  comment = The harddisk
  path = /media/hdd
  read only = no
  public = yes
  guest ok = no
  browseable = yes
  valid users = mine

 

As soon as I try accessing the server with any user I get the following lines in my log:

 

[2014/04/10 17:16:49, 0] lib/util_sec.c:assert_gid(119)
  Failed to set gid privileges to (-1,1000) now set to (0,0) uid=(0,0)
[2014/04/10 17:16:49, 0] lib/util.c:smb_panic(1633)
  PANIC (pid 16280): failed to set gid
 
[2014/04/10 17:16:49, 0] lib/util.c:log_stack_trace(1737)
  BACKTRACE: 1 stack frames:
   #0 /usr/sbin/smbd(log_stack_trace+0x40) [0x778aca58]
[2014/04/10 17:16:49, 0] lib/fault.c:dump_core(181)
  dumping core in /var/log/cores/smbd
[2014/04/10 17:16:49, 0] lib/util_sec.c:assert_gid(119)
  Failed to set gid privileges to (-1,1000) now set to (0,0) uid=(0,0)
[2014/04/10 17:16:49, 0] lib/util.c:smb_panic(1633)
  PANIC (pid 16281): failed to set gid
 
[2014/04/10 17:16:49, 0] lib/util.c:log_stack_trace(1737)
  BACKTRACE: 1 stack frames:
   #0 /usr/sbin/smbd(log_stack_trace+0x40) [0x778aca58]
[2014/04/10 17:16:49, 0] lib/fault.c:dump_core(181)
  dumping core in /var/log/cores/smbd
[2014/04/10 17:17:04, 0] lib/util_sec.c:assert_gid(119)
  Failed to set gid privileges to (-1,1000) now set to (0,0) uid=(0,0)
[2014/04/10 17:17:04, 0] lib/util.c:smb_panic(1633)
  PANIC (pid 16286): failed to set gid
 
[2014/04/10 17:17:04, 0] lib/util.c:log_stack_trace(1737)
  BACKTRACE: 1 stack frames:
   #0 /usr/sbin/smbd(log_stack_trace+0x40) [0x778aca58]
[2014/04/10 17:17:04, 0] lib/fault.c:dump_core(181)
  dumping core in /var/log/cores/smbd

 

Is there any way of using Samba in a proper way? I mean, without doing all as root and some user management?

 

Thanks,

MiNe


Viewing all articles
Browse latest Browse all 10525

Trending Articles