While re-profiling our company's backup strategy, we've needed a piece of software to use while copying files between servers and to our local system using FTP w/o interaction and preferably using command line paremeters. No promising solutions were available on the internet. Because this was a real "must" for us that we can not give up, I've decided to build the tool "FTP Push" that will fullfill our needs.

You can find the tool at http://ali.inal.info/FTPPush/FTPPush.zip. Because the tool is built with C# on .NET Framework 3.5, you need to have this Framework installation first. While fulfilling our needs, I've tried to build a more flexible tool in order to make it work in other similar cases for different users.

Here is some of the features:
* Because no user interaction is needed and is runnable through command line, you can set the tool as scheduled task and automate your jobs.
* By passing different setting files as parameter to tool, you can plan different profiled FTP uploads.
* Ports other than 21 are also supported so you may configure your firewall as needed.
* You can define unlimited number of folders in a setting file so all folders will be uploaded sequentially.
* You redirect different folders to different (or same) folders on target FTP sites. Folders will be created automatically in case of need.
* File search patterns can be defined on folders.
* Optionally, you can set the tool to recurse subfolders of upload folders.
* Upon completion of the upload procedure, an upload log report can be delivered to predefined admin list via e-mail.
* You can set mailing server settings and also perform SMTP Authentication.

Tool is using a setting file (like below) that can either be passed to tool as command line parameter or saved next to executable file as "settings.xml":

<?xml version="1.0"?>
<FTPInfo>
<server address="ftp://ftp.yourdomain.com" port="21">
<credentials>
<UserName>ftppush.user</UserName>
<Password>ftppush.password</Password>
<Domain />
</credentials>
</server>
<folders>
<folder localPath="d:\Backups\PSTs" remotePath="PSTs" filter="*.pst" recurse="true" />
<folder localPath="d:\Backups\DBs" remotePath="DBs" filter="*.mdb;*.mdf;*.accdb" recurse="true" />
</folders>
<mailing server="smtp.yourdomain.com" port="35" subject="FTP Push Status Info">
<authenticateAs>
<UserName>sender@yourdomain.com</UserName>
<Password>password</Password>
<Domain />
</authenticateAs>
<fromName>FTP Push Service</fromName>
<fromEmail>sender@yourdomain.com</fromEmail>
<admins>
<admin>admin1@yourdomain.com</admin>
<admin>admin2@yourdomain.com</admin>
</admins>
</mailing>
</FTPInfo>


You're able to set all features mentioned above using this XML file. Then just simply save this file next to exe file named as "settings.xml" or save it with another name and pass this name to exe file as command line parameter. By this way, you'll be able to automate different upload task with just one exe file.

You can download and test the tool from http://ali.inal.info/FTPPush/FTPPush.zip. This tool will always be freeware. I'm open to all requests and suggestions, I'll try to improve the tool as I find time.

I hope this tool also works for others...



Bu yazının Türkçe sürümü bulunmaktadır

Copyright Ali INAL ©2009 - Creative Commons Licence
preload preload preload

Taşındık!


Ali's Surprisingly Web blog'u, artık yeni, güçlü ve daha esnek altyapısıyla yeni adresinden yayın yapıyor. Yeni adresimiz: http://surprisingly.web.tr. Bu eski blog sayfalarındaki bütün içerik, yeni blog altyapısına da taşındı. Arzu ederseniz sizi yeni blog'umda ağırlamak isterim.
Yeni blog'a gitmek istiyorum Bu sayfayı okumak istiyorum

We've Moved!


Ali's Surprisingly Web Blog is now serving from a new, stronger and flexible system with a brand new address. Our new address: http://surprisingly.web.tr. Also we've migrated all old content from this blog to our new blog. If you wish, I want to welcome yo to my new blog.
I want to visit new blog I want to stay and read this page