automate ftp transfer from windows xp to unix

Posted on 2011-10-31
Last Modified: 2012-05-12
Hello, I need to write a batch file that will automatically ftp a file from my Windows XP box to my SCO Unix box.  I can do this manually without a problem but  need to schedule it to run every night at 1:00 a.m..  The file name is not always going to be the same.  Can I use a wildcard?
Question by:foxhelp
    LVL 16

    Expert Comment

    by:JammyPak push from Windows you can just write a .bat file, then call an ftp script for the ftp commands

    see here:

    use mput so you can use a wildcard in the put statement

    you could also look for a Windows command line scp to copy to unix instead of using ftp
    LVL 16

    Expert Comment

    oh yea, then use task scheduler to set the job up...or the good old at command
    LVL 16

    Expert Comment

    If you need a secure transfer (FTPS or SFTP) or if you need Passive Mode for data transfers the native DOS command line FTP client won't work.

    If this is a project for work, or it is more complicated than a simple transfer then you might consider using Robo-FTP.

    Author Comment

    Here is my script but it is not logging in to the server.  I get a not logged in error.

    @ftp -i -s:"%~f0"&GOTO:EOF
    cd c:\telaidnorcross\queue
    cd /server/lown
    put Lown*

    Can you check the script and let me know what is wrong with it.  It should issue an ftp to, log in as root with devsysone as the password, cd to /server/lown directory, and put a file out there.


    LVL 16

    Accepted Solution

    I don't think the wildcard will with with a put - try to mput

    Author Closing Comment

    That worked.  Thanks

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Free Trending Threat Insights Every Day

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Our Group Policy work started with Small Business Server in 2000. Microsoft gave us an excellent OU and GPO model in subsequent SBS editions that utilized WMI filters, OU linking, and VBS scripts. These are some of experiences plus our spending a lo…
    Join Greg Farro and Ethan Banks from Packet Pushers ( and Greg Ross from Paessler ( for a discussion about smart network …
    As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
    The Task Scheduler is a powerful tool that is built into Windows. It allows you to schedule tasks (actions) on a recurring basis, such as hourly, daily, weekly, monthly, at log on, at startup, on idle, etc. This video Micro Tutorial is a brief intro…

    779 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

    14 Experts available now in Live!

    Get 1:1 Help Now