New net breaks scripts
Ken Cross
kcross at nssolutions.com
Sat Sep 13 18:58:43 GMT 2003
FWIW, here's a patch to fix the first "feature" noted below. It adds a
--no-prompt option to net to inhibit prompting for a password.
It was crucial for my operation when running net in a script, but maybe
nobody else cares, so for those who can use it...
Ken
________________________________
Ken Cross
Network Storage Solutions
Phone 865.675.4070 ext 31
kcross at nssolutions.com
> -----Original Message-----
> From:
> samba-technical-bounces+kcross=nssolutions.com at lists.samba.org
>
> [mailto:samba-technical-bounces+kcross=nssolutions.com at lists.s
> amba.org] On Behalf Of Ken Cross
> Sent: Thursday, August 21, 2003 10:35 AM
> To: 'Multiple recipients of list SAMBA-TECHNICAL'
> Subject: New net breaks scripts
>
>
> 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
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: no-prompt.patch
Type: application/octet-stream
Size: 2054 bytes
Desc: not available
Url : http://lists.samba.org/archive/samba-technical/attachments/20030913/56ec70fa/no-prompt.obj
More information about the samba-technical
mailing list