Solved

Batch File: WGET to fully mirror FTP site

Posted on 2011-09-02
3
1,514 Views
Last Modified: 2012-08-13
Hi there,

With WGET, I was able to mirror from the FTP site. However, when I delete a file at the FTP site, it is not deleted at the local folder.

REF: http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/MS_DOS/Q_27287357.html?cid=1575#a36473643

I need to use WGET to fully mirror an FTP site.

Thanks for your help,
Rene

 
wget.exe -m --passive -P LocalFolder ftp://username:password@domainname.com:1111

Open in new window

0
Comment
Question by:ReneGe
3 Comments
 
LVL 3

Assisted Solution

by:vk3kjc
vk3kjc earned 250 total points
ID: 36477448
The version that I use does not have that capability although I do have vague recollections of an older (Unix?) version doing it. I remember the frustration at it deleting files if the FTP connection failed for some reason and it did not find the file on the server.

I now use rsync, which does have a --delete option, between servers or if I am in a Windows environment, I use relatively inexpensive commercial software (Beyond Compare).

If you you only have FTP access to the source data, the only option with wget might be to delete all the files and download them all again.
0
 
LVL 51

Accepted Solution

by:
Bill Prew earned 250 total points
ID: 36477634
Agreed, it looks like WGET doesn't support that, so it's really not a true option for that type of mirroring sync.

If you want to explore another option, take a look at CWRSYNC at the link below.  I use this for some local server sync activities, but getting the command line right can take a bit of trial and error. And the server you are connecting to has to support the rsync command.

http://www.itefix.no/i2/node/10650

Also, FWIW, I live by Beyond Compare, and happily pay it's cost. I don't typically use it for batch sync type things though, I use it for two file "diff and merge" type activities with a UI. It's a great tool for comparing two files, or two folder structures and identifying differences.

http://www.scootersoftware.com/

~bp
0
 
LVL 10

Author Closing Comment

by:ReneGe
ID: 36477800
Thanks a million to you both.

You just saved me a lot of time  ;-)

If I need help for using the refered apps, I'll open new questions.

Cheers,
Rene
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

This article will show, step by step, how to integrate R code into a R Sweave document
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Learn the basics of strings in Python: declaration, operations, indices, and slicing. Strings are declared with quotations; for example: s = "string": Strings are immutable.: Strings may be concatenated or multiplied using the addition and multiplic…
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now