Sponsored Content
Top Forums Shell Programming and Scripting Replicate remote directory to local directory with ftp Post 302767623 by panyam on Thursday 7th of February 2013 06:59:13 AM
Old 02-07-2013
Try like this:

(1) connect to the remote ftp server and list the files and disconnect
(2) compare the file names with local ones and note which files are not present.
(3) Again connect to the remote ftp server and *mget* the files.
 

10 More Discussions You Might Find Interesting

1. Solaris

[FTP]opying of file from remote to local machine

Hi All, i wannna copy a file from the remote machine to my local machine using FTP protocol. i have made a connection to the remote machine , then i used the "get" cmd to copy the remote file as below :-> ftp> get (remote-file) /home/aruba/opmtools/was50/Was5Install.doc (local-file)... (1 Reply)
Discussion started by: sonbag_pspl
1 Replies

2. Shell Programming and Scripting

Problem with ftp- how to check if the remote directory exists.?

I am trying to initiate a ftp session from my shell script in the following way. In my script, as per my requirements i am writing the required ftp commands to a file and then I am using this file to carry out the ftp process. for example temp.txt will contain cd /home/user/mydir append... (2 Replies)
Discussion started by: anijan
2 Replies

3. UNIX for Dummies Questions & Answers

Scp from local to external directory

Hi, I am trying to copy a whole directory from my home /RUN1 to the external directory jorgensen@hal.oerc.ox.ac.uk:/home/compchem/jorgensen/simulations The command I have used is: scp -r jorgensen@hal.oerc.ox.ac.uk:/home/compchem/jorgensen/simulations The error message I get is: ... (5 Replies)
Discussion started by: chrisjorg
5 Replies

4. Shell Programming and Scripting

Replicate one directory with another

I have a dir as /library/utility/apache-tomcat/tbase-6001/repositories which has many huge directories and files. I am planning to replicate it to another folder /library/utility/apache-tomcat/tbase2008-6001/repositories Normal copy command is taking a hell lot of time and getting hung in... (1 Reply)
Discussion started by: Tuxidow
1 Replies

5. UNIX for Dummies Questions & Answers

How to transfer file from Local PC to Unix Directory without FTP!!!

Dear Friends, How to transfer files from my local PC to Unix directory without using FTP. Scenario: Transfer/Upload a file from PC to unix using web browser without using FTP technologies. I heard something like sendunix and sendpc used to transfer files from unix to Desktop and... (1 Reply)
Discussion started by: kk_c2il2
1 Replies

6. Shell Programming and Scripting

FTP files from different directory from remote server to one directory in local

Hi All, I want to search for .log files from folders and sub folders in remote server and FTP them to one particular folder in the local machine. I dont want to copy the entire directory tree structure, just have to take all the .log files from all the folders by doing a recursive search from the... (3 Replies)
Discussion started by: dassv
3 Replies

7. UNIX for Dummies Questions & Answers

File listing from remote to local directory

Hello, I have a file at remote server. I have to select only current day's files that are dropped on ftp server. The files do not have date or timestamp on them. so I plan to get the file listing from remote server to the local server. Based on file listing date I can find out when the files... (2 Replies)
Discussion started by: pavan_test
2 Replies

8. Shell Programming and Scripting

How to transfer file from Local PC to UNIX Directory without FTP?

Dear All, i am trying to get the file from windows location to unix location without using FTP and neither thru entering the user id and password. I have one unix form which is running on web application and user is entering the location and file name there now i know the file name and path. So i... (8 Replies)
Discussion started by: ripudaman.singh
8 Replies

9. Solaris

Ftp a directory to another server from the local server what is the command

ftp a directory to another server from the local server what is the command (2 Replies)
Discussion started by: PMoore
2 Replies

10. Shell Programming and Scripting

Unable to ssh and list files in local directory from remote.

#!/bin/bash script_work_dir="/home/websys/TEST_dpi_42_file_trnsfer_engine/PORT22/script_work_area" script_config_dir="/home/websys/TEST_dpi_42_file_trnsfer_engine/PORT22/script_config" dpi_sourceServerList=$script_config_dir"/dpi_sourceServerList" dpi_srvr_42="rtm@1.1.1.1"... (8 Replies)
Discussion started by: sadique.manzar
8 Replies
FTPMIRROR(8)															      FTPMIRROR(8)

NAME
ftpmirror - Mirroring directory hierarchy using FTP protocol SYNOPSIS
ftpmirror [package] DESCRIPTION
ftpmirror is an utility to copy directory hierarchy (usually called 'mirror') using FTP protocol. A similar perl script exists, whose name is 'mirror', but ftpmirror requires less memory than mirror. OPTIONS
Please, note that the original documentation about ftpmirror was written originally in japanese. (README.jis and RELEASE.jis) If you can contribute by translating any aspect of these files, please contact Dario Minnucci <debian@midworld.net>. I'll be glad to include your contributions here to improve this manual. Formerly ftpmirror operatio mode was MASTER->SLAVE but seems that since version 1.96 the SLAVE->MASTER (reverse mirror) is supported. This behaviour can be controlled for each package section in the main configuration file (/etc/ftpmirror/ftpmirror.cf). MASTER->SLAVE --> get-mode = yes (default) SLAVE->MASTER --> put-mode = yes Other configuration flags extracted from original documentation are: (Sorry but most of them are still undocummented.) todo: (string, default: full-mirror) verbose: (boolean, default: no) log-mask: (comma separated list) test-mode: (boolean, default: no) ftp-server: (string) ftp-gateway: (string) ftp-port: (service, default: ftp) ftp-bindaddr: (ip address) ftp-user: (string, default: anonymous) ftp-pass: (string, default: `whoami`@`hostname`) ftp-group: (string) ftp-gpass: (string) ftp-passive: (boolean, default: no) To enable passive file transfer set ftp-passive to yes. ftp-idle: (numeric, default: 0) ftp-max-idle: (boolean, default: 0) ftp-list-method: (LIST or STAT or STAT-A or STAT-AT, default: STAT) ftp-timeout: (numeric, default: 300) ftp-login-retry: (numeric) ftp-login-delay: (numeric, default: 60) ftp-stats: (boolean, default: no) remote-timezone: (timezone string, default: undef) http-proxy: (string) server: (string) package: (string) put-mode: (boolean, default: no) unlink: (boolean or 'rename', default: yes) unlink-limit: (size value, default: 0) ftp-force-mtime: (boolean, default: no) ignore-mtime: (boolean, default: no) temp-directory: (pathname, default: $TMPDIR || /tmp) lock-directory: (pathname, default: temp-directory) create-directory: (boolean, default: yes) remote-directory: (string) local-directory: (pathname) master-db-directory: (pathname) remote-db-directory: (pathname) local-db-directory: (pathname) lslR-file: (string) lslR-copy: (pathname) transfer-file-regexp: (regexp) transfer-directory-regexp: (regexp) override-file-regexp: (regexp) override-directory-regexp: (regexp) load-local-dirinfo: (boolean, default: no) store-local-dirinfo: (boolean, default: no) load-remote-dirinfo: (boolean, default: no) override-file-uid: (uid, default: 0) override-file-gid: (uid, default: 0) override-file-mode: (octal value, default: 0644) override-directory-mode: (octal value, default: 0755) default-file-uid: (uid, default: 0) default-file-gid: (gid, default: 0) default-file-mode: (octal value, default: 0644) default-directory-mode: (octal value, default: 0755) EXAMPLES
ftpmirror provides a 'ready-to-use' sample package for testing porpouses. In order to run the provided test package you need to issue the following commands (both commands must be run by the same user): mkdir -p /tmp/upstream /usr/bin/ftpmirror upstream This package should copy directory hierarchy from the original author's FTP location (ftp://ftp.intec.co.jp/pub/utils/ftpmirror) to your local hard drive (/tmp/upstream). IMPORTANT CONSIDERATION
The inclusion of this configuration is intended to be used ocassionally. Please don't abuse this site. SEE ALSO
For other supported configuration options see /etc/ftpmirror/ftpmirror.cf where you will find commented examples. AUTHOR
ftpmirror was originally written by Ikuo Nakagawa <ikuo@intec.co.jp> This manual page was written by Dario Minnucci <debian@midworld.net>, for the Debian project (but may be used by others). Dario Minnucci <;debian@midworld.net> June 1, 2007 FTPMIRROR(8)
All times are GMT -4. The time now is 05:36 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy