[Samba] howto sync unix passwd & samba passwd?

Iris Lames iris.lames at gmail.com
Wed May 21 21:32:32 GMT 2008


Hi,

I'm using samba-3.0.28-0.fc8. I'm trying to build a file server for 100
users. I created a perl script that automatically adds the 100 users plus
their passwords with success. Now I'm having difficulty creating a script
using the smbpasswd command because passwords must be entered in stdin. I
also tried smbpasswd -s option but it asks passwd in stdin. Is there a way
that I can use the command smbpasswd plus the user password in one line?

Also, I read about mksmbpasswd.sh and test it but it did not work at all.
My smb.conf contains:
smb passwd file = /etc/samba/sambapassword
and did:
cat /etc/passwd | grep test | /usr/bin/mksmbpasswd.sh >
/etc/samba/sambapassword


Is there a way for me to sync the userpassword and smbpasswd? Help me
please.

-Iris Lames


More information about the samba mailing list