Mailinglist Archive: opensuse (3605 mails)
| < Previous | Next > |
Re: [SLE] command line ftp copy
- From: "Richard Mancusi" <vrman49@xxxxxxxxx>
- Date: Mon, 19 Jun 2006 10:51:47 -0500
- Message-id: <653ba2540606190851r462a56d9y687f2af43f7d1bb5@xxxxxxxxxxxxxx>
Not sure if this helps you, but much can be done in a shell
script. Following is one that I use every day. (isn't pretty,
but works) It is run from a LInux box and does the following:
1. Obtains files from a VMS Alpha box and writes
them to a directory on the Linux box
2. Logs on to a MS Win box, deletes specific files, and
then copies the Linux files to the MS box.
Note: the "m" in mget, mdelete, and mput = multiple
Perhaps this will inspire your creative process. Wish I
had more time to help but I am swamped. good luck
Rich
-------------------
#!/bin/bash
RMT_HOST=192.xxx.xxx.xxx
RMT_USERID=system
RMT_PASSWORD=xxxxxxxx
RMT_DIR='dsa0:[temp]'
ftp -n -i -v -d <<eof
open $RMT_HOST
user $RMT_USERID $RMT_PASSWORD
cd $RMT_DIR
lcd /home/vrman/zeod_transfer
mget *200*.txt*
prompt off
bye
eof
RMT_HOST=192.xxx.xxx.xxx
RMT_USERID=administrator
RMT_PASSWORD=xxxxxxx
ftp -n -i -v -d <<eof
open $RMT_HOST
user $RMT_USERID $RMT_PASSWORD
mdelete *200*.*
lcd /home/vrman/zeod_transfer
mput *.*
prompt off
bye
eof
--------------------
On 6/19/06, Per Jessen <per@xxxxxxxxxxxx> wrote:
--
TNS
--
Check the headers for your unsubscription address
For additional commands send e-mail to suse-linux-e-help@xxxxxxxx
Also check the archives at http://lists.suse.com
Please read the FAQs: suse-linux-e-faq@xxxxxxxx
script. Following is one that I use every day. (isn't pretty,
but works) It is run from a LInux box and does the following:
1. Obtains files from a VMS Alpha box and writes
them to a directory on the Linux box
2. Logs on to a MS Win box, deletes specific files, and
then copies the Linux files to the MS box.
Note: the "m" in mget, mdelete, and mput = multiple
Perhaps this will inspire your creative process. Wish I
had more time to help but I am swamped. good luck
Rich
-------------------
#!/bin/bash
RMT_HOST=192.xxx.xxx.xxx
RMT_USERID=system
RMT_PASSWORD=xxxxxxxx
RMT_DIR='dsa0:[temp]'
ftp -n -i -v -d <<eof
open $RMT_HOST
user $RMT_USERID $RMT_PASSWORD
cd $RMT_DIR
lcd /home/vrman/zeod_transfer
mget *200*.txt*
prompt off
bye
eof
RMT_HOST=192.xxx.xxx.xxx
RMT_USERID=administrator
RMT_PASSWORD=xxxxxxx
ftp -n -i -v -d <<eof
open $RMT_HOST
user $RMT_USERID $RMT_PASSWORD
mdelete *200*.*
lcd /home/vrman/zeod_transfer
mput *.*
prompt off
bye
eof
--------------------
On 6/19/06, Per Jessen <per@xxxxxxxxxxxx> wrote:
Roger Oberholtzer wrote:
> Does SUSE 10 come with a command line ftp copy command. I mean that I
> can copy a file from the local system to a remote ftp location, giving
> all info on the command line.
I think you'll have to use some stdin input to do the PUT command. I
have automated ftp stuff before, but I don't think I've ever managed to
put everything on the command-line.
> Oddly, the ftp client I see in 10.0 allows this when copying from a
> remote server, but not when copying to a remote server. This works
> (copies remfile to the local machine):
This is the AUTO-FETCH feature.
> but this does not
> ftp remfile user:pass@xxxxxxxxxxxxxx:/
>
I don't think that is a supported format. At least not according to the
manpage.
/Per Jessen, Zürich
--
Check the headers for your unsubscription address
For additional commands send e-mail to suse-linux-e-help@xxxxxxxx
Also check the archives at http://lists.suse.com
Please read the FAQs: suse-linux-e-faq@xxxxxxxx
--
TNS
--
Check the headers for your unsubscription address
For additional commands send e-mail to suse-linux-e-help@xxxxxxxx
Also check the archives at http://lists.suse.com
Please read the FAQs: suse-linux-e-faq@xxxxxxxx
| < Previous | Next > |