I was able to produce the following error using smbpasswd when the directory /etc/samba did not exist:
[r...@varda]# smbpasswd -a New SMB password: Retype new SMB password: startsmbfilepwent_internal: file /etc/samba/smbpasswd did not exist. Couldn't create new one. Error was: No such file or directoryUnable to open passdb database. startsmbfilepwent_internal: file /etc/samba/smbpasswd did not exist. Couldn't create new one. Error was: No such file or directorystartsmbfilepwent_internal: too many race conditions creating file /etc/samba/smbpasswd add_smbfilepwd_entry: unable to open file. Failed to add entry for user root. Failed to modify password entry for user root [r...@varda]# If this looks like the error you got, try the following: # cd /etc # mkdir samba # smbpasswd -a