Samba problem with create user

YuriiV

Cadet
Joined
Jan 7, 2022
Messages
9
Hi all, there is a problem with samba, the last time I added a new user, it was created in the system but not in passdb.tdb. Tried adding manually through the console and got this output.
pdbedit -a -u test
Unable to modify TDB passwd: NT_STATUS_OBJECT_NAME_COLLISION!
Failed to add entry for user test.
Has anyone had this problem? Should I try to restore from a config backup or is there an easier solution?
TrueNAS-12.0-U7
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,553
Hi all, there is a problem with samba, the last time I added a new user, it was created in the system but not in passdb.tdb. Tried adding manually through the console and got this output.
pdbedit -a -u test
Unable to modify TDB passwd: NT_STATUS_OBJECT_NAME_COLLISION!
Failed to add entry for user test.
Has anyone had this problem? Should I try to restore from a config backup or is there an easier solution?
TrueNAS-12.0-U7
Try removing /var/db/system/samba4/private/passdb.tdb and then re-syncing the users: `midclt call smb.synchronize_passdb -job`
 

Whiskey

Dabbler
Joined
Jul 10, 2021
Messages
29
Thanks! This worked for me too! Only in my case there was no passdb.tdb. I deleted secrets.tdb which did the trick.
No idea why this stopped working. But yesterday I created a bunch of datasets and one share. Today I decided to redo things and deleted the datasets, share and users/groups. Maybe that messed things up.
 
Top