0

i have Windows 2008 Server on which i store DB backups on daily basis. I want to be able to download new files only using wget, curl or windows built-in FTP doesn't matter.

Can you help me with command? I need only new files, ones that exists on local machine (Windows Vista) and server should be skipped.

Thanks

1

See the --noclobber option for wget. Also, if you have ncftpget available, I believe it skips existing files by default.

1

With wget: New = doesn't exist OR more recently modified

Each time run: (probably won't work on existing files - you need the initial download to contain the remote timestamp) wget --timestamping -r ftp://yoursite.com/path/

https://superuser.com/questions/283481/how-do-i-properly-set-wget-to-download-only-new-files

With cURL you can use the -z option to specify that only files after a certain date should be downloaded

curl -z "Jun 30 2011" http://yoursite.com/file.html

http://curl.haxx.se/docs/manual.html

1

What you are actually looking for is --timestamping. --no-clobber just wont download existing files taking no concideration if the files on the server are newer or not.

--timestamping looks at the file to see if the version remote is newer than local before downloading.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.