[Samba] Can't create users?

Rowland penny rpenny at samba.org
Fri Nov 20 22:35:18 UTC 2020


On 20/11/2020 22:22, Dan Egli via samba wrote:
> Okay, I re-downloaded the Samba source and recompiled it. It started 
> giving me fits until I modified the samba.service file to point to 
> /etc/samba/smb.conf instead of whatever the default was. Then it 
> started fine. But when I go to add a user via samba-tool, I get an error:

Why do move smb.conf ?

If you run <samba -b | grep 'CONFIGFILE'> does the output show 
/etc/samba/smb.conf ?

Have you set the PATH to use your new Samba files before any possible 
Samba files installed elsewhere ?

>
> samba-tool user create dan
> New Password:
> Retype Password:
> ERROR(<class 'ValueError'>): Failed to add user 'dan':  - unable to 
> parse dn string
>   File 
> "/usr/local/samba/lib/python3.7/site-packages/samba/netcmd/user.py", 
> line 395, in run
>     smartcard_required=smartcard_required)
>   File "/usr/local/samba/lib/python3.7/site-packages/samba/samdb.py", 
> line 458, in newuser
>     dnsdomain = ldb.Dn(self, 
> self.domain_dn()).canonical_str().replace("/", "")
>
>
> How do I fix this? Everthing is using the default path 
> (/usr/local/samba). The only paramater I passed to configure was 
> --enable-fhs since I remember that it croaks without that. 
It shouldn't 'croak' without '--enable-fhs'
> So I just did:
> ./configure --enable-fhs
> make && make install

That should have worked, have you installed the required dependencies to 
build Samba ?

Rowland






More information about the samba mailing list