Hi Paul, [EMAIL PROTECTED] wrote:
>Hi list, > >I'm trying to automate password changes remotely as >a >temporary solution to a problem I have. I'm using >Expect to >do this. Basically the scheme is: > >$ ssh [EMAIL PROTECTED] passwd testuser > >This command is spawned by an Expect script and then >the >password change interaction takes place (at least it >works >for Linux but not Solaris :-\). > >The problem is that this command produces a: >"Permission >denied" error. I get the same result running this >remotely >from the command line. Locally I can run the passwd >binary >no problem. > >I've tested this against Solaris 5.8 and 5.9 with >the same result. > >Any ideas why this is or of a way around this? > > >From memory (I don't have a Solaris box in front of me at the moment), I think it has to do with the fact that running a command instead of a shell leaves SSH without a terminal device to connect to and grab the input from. I got around this by not using the passwd command, but instead I created a shell script which takes the password as input and changes the shadow entry. Kicked off using SSH with ssh-agent and passphrase-protected keys, this allow me to change user's passwords without logging in to each box. I can send you the script if you wish. Kind Regards, Nathan Dietsch _______________________________________________ Solaris-Users mailing list [email protected] http://www.filibeto.org/mailman/listinfo/solaris-users
