1.9.18p4 smbpasswd and unix sync with sunos 5.5 nis server

Todd Pfaff todd at edge.cis.mcmaster.ca
Wed Apr 8 20:37:53 GMT 1998


i found the following to work for syncing samba and unix passwords.

my environment is:

  sunos 5.5
  samba-1.9.18p4
  samba password server is also nis master server

in smb.conf:

  allow hosts = localhost [ + whatever other hosts you want to allow ]
  unix password sync = yes
  passwd program = /bin/passwd -r files %u; cd /var/yp; make passwd
  passwd chat = *New\spassword:* "%n\n" *new\spassword:* "%n\n" *updated\spasswd* . *pushed\spasswd*

note the \s for spaces in the expect string and the "" around the
response string.  i found this to be the only variation that would work.
the \s seemed to be necessary in the expect string - using "" around the
string didn't seem to work.  the "" in the response string are necessary
in case there are any spaces in the new password string.

the 'passwd -r files' and 'cd /var/yp; make' are necessary since this is
the only way root can change a user's nis password without knowing the old
password in sunos 5.5.  unfortunately, this will only work on the nis
master server.  fortunately, in my case, the nis master server is always
the samba password server.

--
Todd Pfaff                         \  Email: pfaff at mcmaster.ca
Computing and Information Services  \ Voice: (905) 525-9140 x22920
ABB 132                              \  FAX: (905) 528-3773
McMaster University                   \
Hamilton, Ontario, Canada  L8S 4M1     \



More information about the samba mailing list