Copy a tar file from remote server
From: Sanjay katiyar (sanjay_katiyar1_at_yahoo.co.in)
Date: 03/17/05
- Previous message: zhicheng wang: "RE: Swap space with 12G memory"
- Next in thread: Smith, Albert: "RE: Copy a tar file from remote server"
- Maybe reply: Smith, Albert: "RE: Copy a tar file from remote server"
- Maybe reply: Tobias Speckbacher: "RE: Copy a tar file from remote server"
- Reply: Xiao Cai: "Re: Copy a tar file from remote server"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 17 Mar 2005 10:57:32 +0000 (GMT) To: General Red Hat Linux discussion list <redhat-list@redhat.com>
I am trying to connect a remote machine thruogh ssh
and want to tar one directory and copy the tar file in
my local machine. My script file looks like this
**************************
!/bin/sh
Date=`date -I`
ssh -l tomcat www.MyRemoteHost.net
tar -cvf /opt/tomcat4/MyDir/bk-$Date.tar
/opt/tomcat4/webapps/MyApp/
scp tomcat@www.MyRemoteHost.net:MyDir/bk-$Date.tar .
**************************
When I run this script in my local machine it ask for
password of user tomcat, after supplying
the password it connects to the remote machine and
does not execute the rest of the commands.
Can any one suggest the right script?
Thanks in advance.
Sanjay
________________________________________________________________________
Yahoo! India Matrimony: Find your life partner online
Go to: http://yahoo.shaadi.com/india-matrimony
-- redhat-list mailing list unsubscribe mailto:redhat-list-request@redhat.com?subject=unsubscribe https://www.redhat.com/mailman/listinfo/redhat-list
- Previous message: zhicheng wang: "RE: Swap space with 12G memory"
- Next in thread: Smith, Albert: "RE: Copy a tar file from remote server"
- Maybe reply: Smith, Albert: "RE: Copy a tar file from remote server"
- Maybe reply: Tobias Speckbacher: "RE: Copy a tar file from remote server"
- Reply: Xiao Cai: "Re: Copy a tar file from remote server"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|