[Samba] passwd sync - troubles

Mac dmccann at nibsc.ac.uk
Tue Mar 12 03:07:05 GMT 2002


Hi all,

>Subject: Re: [Samba] passwd sync - troubles
>From: Terry Davis <tdavis at approbation.org>
>To: Andrew Bartlett <abartlet at pcug.org.au>, dmccann at nibsc.ac.uk
>Cc: samba at lists.samba.org
>Date: 11 Mar 2002 12:50:12 -0600
>
>responses and failing.  What is weird is that it did change the
>passwords when it was failing on the chat responses, can someone explain
>that one to me? 
>


Ah, that too is normal.

Imagine a password chat of:-

	*new*passwd* %n\n  *retype*passwd* %n\n  *wibble*wibble*

The first phrase matches, and the password is sent. The second phrase
maches, and the password is sent.  At this point the (UNIX) passwd
program has everything it needs and changes the password.  Samba is
waiting for 'wibble*wibble', but this will never come, so it _thinks_
the UNIX passwd program failed.

Since Samba thinks the UNIX passwd change failed, Samba won't change the
SMB passwords, but the UNIX password has changed.

This is the only combination I've seen that does this, but I wouldn't be
surprised if there are others.

There's also an even worse case where the UNIX passwd program spits out
quite a bit of output (over more than one line, say) but Samba doesn't
read it in. Everything then hangs, the UNIX passwd program can't exit
(because it's output is not being consumed) and the Samba daemon isn't
looking for anymore output, but is just waiting for the UNIX passwd prog
to exit (which it can't).

The answer is debug your chat script thoroughly (including failed
password changes!)

I'd quite like not to have to use a log level of 100 to do it though.  


                               Mac
          Assistant Systems Adminstrator @nibsc.ac.uk
                        dmccann at nibsc.ac.uk
   Work: +44 1707 654753 x285      Everything else: +44 7956 237670 (anytime)




More information about the samba mailing list