Second, this is really a unix question, not a perl one, since this is the way passwd works.I disagree. He's not having problems with passwd per se, he's having problems accessing it through perl. There is a difference.
As for the original question, I think that part of the problem can have some light shed on it by the answer to the question "where do stdout and stderr go when you do a system call?" . Also, passwd expects a tty to be communicating with it, and has provisions to prevent things like scripts interfacing with it. Fortunately for you, Expect.pm is around. Expect simulates a tty, allowing you to script an interface to things like passwd.
thor
In reply to Re: Re: Calling interactive programs from with a script
by thor
in thread Calling interactive programs from with a script
by Pearte
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |