New net breaks scripts

Ken Cross kcross at nssolutions.com
Thu Aug 21 14:34:44 GMT 2003


Samba-folk:

There are 2 new "features" in the new net utility (SAMBA_3_0) that breaks
scripts pretty badly.

The first is prompting for a password when -P is specified, but the machine
account doesn't exist.  Previously, it would exit nicely with an error
status.  Now it prompts for a password.  For example:

  net ads leave -P

Previously this would work as desired -- if the machine account existed, it
would remove it; if not, it would continue.  Now it hangs waiting for input,
which is a Bad Thing in a script.


The second is "realm must be set in in smb.conf for ADS join to succeed".  I
try to use "net -s /dev/null" in my scripts whenever possible (it keeps
things in a known state), and then add everything on the command line.  Can
we add a command-line option for realm?

Ken
________________________________

Ken Cross

Network Storage Solutions
Phone 865.675.4070 ext 31
kcross at nssolutions.com 




More information about the samba-technical mailing list