Following various guides around the net, I put together a batch file that should upload a .zip to our central file server. However, If I use “ftp -n -s:ftpup.dat 108.174.61.82 20” it doesn’t work with the port 20 added to the host. I have also tried “ftp -n -s:ftpup.dat” then “open 108.174.61.82 20” on the next line which also fails. What exactly am I doing wrong?
cd MySQL
@echo off
echo user backups>ftpup.dat
echo passwordhere>>ftpup.dat
echo cd /MySQL>>ftpup.dat
echo binary>>ftpup.dat
echo put MYSQL-%location%.%backuptime%.zip>>ftpup.dat
echo quit>>ftpup.dat
ftp -n -s:ftpup.dat serveriphere 20
del ftpup.dat
Are you running FTP server or port 20?
Telnet serveriphere 20 to check if the port is listening, maybe you have
it running on default port 21
PS: Is it raw ftp protocol?. Maybe It is using SFTP or FTPS
EDIT: Try with
Remove the -n autologin flag
Try with this: