On Sat, Apr 20, 2002 at 08:13:19AM -0700, drieux wrote:
> 
> On Saturday, April 20, 2002, at 04:28 , Mayank Ahuja wrote:
> [..]
> >
> >Summary: Is there a PERL equivalent of rsh or remsh or rlogin on UNIX?
> 
>       my ($user , $hostname , $command_to_run ) = ThatFunkThatSetsTheses();
>       my $cmd = "rsh -n -l $user $hostname $command_to_run";

Which is sufficient for simple single command problems, but if you're in
need of more complex stuff, you need an interactive shell.  At that
point you're reading 'perldoc perlipc' and start fiddling with
IPC::Open3 and friends and run into all kinds of line buffering problems
('perldoc IPC::Open3' discusses this too).  The before mentioned
'Expect' module aims at working around these, but it's been about 2
years back since I last used them, so my information might be outdated.

-- 
                       If we fail, we will lose the war.

Michael Lamertz                        |      +49 221 445420 / +49 171 6900 310
Nordstr. 49                            |                       [EMAIL PROTECTED]
50733 Cologne                          |                 http://www.lamertz.net
Germany                                |               http://www.perl-ronin.de 

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to