delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/11/18/15:39:52

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Thu, 18 Nov 2004 15:39:21 -0500 (EST)
From: Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: Stephen Studley <sstudley AT adobe DOT com>
cc: cygwin AT cygwin DOT com
Subject: Re: Executing ssh from perl
In-Reply-To: <p0610050bbdc2adfcf70d@[153.32.225.133]>
Message-ID: <Pine.GSO.4.61.0411181537080.17559@slinky.cs.nyu.edu>
References: <p0610050abdc2a0cde006@[153.32.225.133]> <Pine DOT GSO DOT 4 DOT 61 DOT 0411181407420 DOT 17559 AT slinky DOT cs DOT nyu DOT edu> <p0610050bbdc2adfcf70d@[153.32.225.133]>
MIME-Version: 1.0
X-Scanned-By: MIMEDefang 2.39

On Thu, 18 Nov 2004, Stephen Studley wrote:

> At 2:12 PM -0500 11/18/04, Igor Pechtchanski wrote:
> > On Thu, 18 Nov 2004, Stephen Studley wrote:
> >  > The successful scenario simply returns the expect stdout:
> > >  debug3: channel 0: will not send data after close
> > >  <some dir>/<files>
> > >
> > >  Thanks in advance.
> > >
> > >  Stephen
> >
> > Try giving the "-n" argument to ssh.
>
> unfortunately, no change in my results.
> BTW: I have ssh configured for passwordless connection.

You *did* properly escape the command string, right?  Otherwise,

my $str = `ssh -n user AT machine DOT domain ls`;

will try to interpolate the contents of the array @machine into the
command...  You need to use

my $str = `ssh -n user\@machine.domain ls`;

BTW, the -n flag is still useful, since some commands don't properly run
otherwise.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha AT cs DOT nyu DOT edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor AT watson DOT ibm DOT com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"The Sun will pass between the Earth and the Moon tonight for a total
Lunar eclipse..." -- WCBS Radio Newsbrief, Oct 27 2004, 12:01 pm EDT

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019