[svlug] Problem in SSH !

Anagha Tongaonkar yogiana_t at yahoo.com
Wed Aug 3 14:38:45 PDT 2005


It is a proprietory utility.

I run a bash script(a.sh)on machine A which performs the
following:
 - FTP the necessary file on machine B 
 - ssh into B [ssh user at B "/home/b.sh"] and launch another
bash script (child script - b.sh) on machine B.

b.sh runs on B and it includes the Compress command that
needs to be run on B.

Pls note, Compress executable is in PATH. Also, the b.sh
takes care of going to appropriate directory. There is no
problem of file/directory permisions on B.

************* partial a.sh **********

#script to FTP file from machine A to machine B

echo "Now SSH into B..."
ssh -l $(whoami) B "/home/b.sh"


***************** b.sh **************

echo "hostname: $(hostname)"

#Run Compress cmd in the destination directory
cd /u1/Data/test

echo "which Compress:"
which Compress
echo "Now executing Compress command ..."

Compress file="myData.csv" op="compress"

echo "AFTER the Compress command"

*************************************************


Will appreciate helpful replies.
Thank you,
Anagha


--- bharat krishnamurthy <bharat at cs.unm.edu> wrote:

> On Wed, 3 Aug 2005, Anagha Tongaonkar wrote:
> 
> > Now, I am running into next problem that is: after the
> file
> > transfer using FTP, I ssh into machine B and then try
> to
> > run an executable "Compress" on machine B. However, the
> > executable is not executed completely, it just hangs
> > halfway. If I run the same execuatble on command line
> on B,
> > it works fine, but if I ssh into B from A (through bash
> > script) and then try to run the executable, it just
> doesn't
> > run completely.
> 
> Is this the unix compress utility or something that u
> wrote? Also how are 
> you executing it on the remote system? Are you using "ssh
> user at server 
> compress <filename>" ? What files are you compressing on
> the server? Maybe you
> should post your script here.
> 
> Bharat
> 



		
____________________________________________________
Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs 
 




More information about the svlug mailing list