[Gllug] non-interactive passwd

Matthew King matthew.king at monnsta.net
Thu May 8 19:44:07 UTC 2003


> Hi,
>
>> Actually no. Under Linux, it's easy because passwd accepts a --stdin
>> option to accept piped input from elsewhere:
>>
>> 	echo $password | passwd --stdin $user
>>
>> Solaris and AIX aren't so accomodating. You might want to try building
>> the Linux passwd on ther other OSen, and see if you can get it to work
>> that way.
>
> It is a pity they are not as forward-thinking as GNU people.
> I'd be more inclined to use something like expect...
>
> Murray

You could use expect, and a bit of tinkering with some scripting may make
it work.
Personally I'd just type 'echo username:password|chpasswd' and get it over
with.
Matthew

-- 
GIT/CM/M d++(-) s++: a--->? C++++ UL++++$ +++>++++ L+++ E>++ W-- N+ o?
K++  w--- O-- M+ V? PS+>++ PE(--) Y+>++ PGP+++@ t+ 5-- X+(-) R tv-
b++>++++ DI++++ D++ G++ e(*) h!>++ r-- y->++++






-- 
Gllug mailing list  -  Gllug at linux.co.uk
http://list.ftech.net/mailman/listinfo/gllug




More information about the GLLUG mailing list