Re: FTP will not accept password from a batch file
- From: "Bernard Cheah [MVP]" <qbernard@xxxxxxxxxxxxxxxxxxx>
- Date: Tue, 9 Jan 2007 16:06:45 +0800
a) post the relevant iis ftp log file.
b) post the actual script content created. don't delete it first
c) if you run the batch file manually, does it work?
--
Regards,
Bernard Cheah
http://www.iis.net/
http://www.iis-resources.com/
http://msmvps.com/blogs/bernard/
"Ragnar Midtskogen" <ragnar_ng@xxxxxxxxxxxxxx> wrote in message
news:udcdP94MHHA.4912@xxxxxxxxxxxxxxxxxxxxxxx
Hi all,
I have run into a strange problem running FTP with a batch file.
The batch file is used to run various NTBACKUP backup operations, then FTP
the backup files to a different server.
The batch file runs correctly and creates all the backup files but does
not get logged in to the FTP server
Looking at the log file created by the batch file I can see that the
connection to the FTP server is made and the userid accepted.
But the password apparently is not, because I get error 331, need
password.
In a command window I can connect OK manually with the same userid and
password.
I have set up backups on a couple of dozen of our servers using basically
the same batch file and they all work well.
The last part of the batch file, where I create and run an FTP script is
shown below:
----------------------------------------------------
REM create FTP script
echo open [IP address] > FTPscript.txt
echo [userid] >> FTPscript.txt
echo [password] >> FTPscript.txt
echo prompt n >> FTPscript.txt
echo cd E:\%DAY% >> FTPscript.txt
echo put %BackUpDir%\%ServerName%-backup.bkf >> FTPscript.txt
echo put %BackUpDir%\Registry_Settings\%ServerName%-Registry-backup.bkf >>
FTPscript.txt
IF %DAY%==Sun echo cd E:\SystemState
IF %DAY%==Sun echo put
%BackUpDir%\System_State\%ServerName%-SystemState-backup.bkf >>
FTPscript.txt
echo quit >> FTPscript.txt
FTP -s:FTPscript.txt
ERASE FTPscript.txt
------------------------------------------------------
Any comments or suggestions would be appreciated.
Ragnar
.
- Follow-Ups:
- Re: FTP will not accept password from a batch file
- From: Ragnar Midtskogen
- Re: FTP will not accept password from a batch file
- References:
- FTP will not accept password from a batch file
- From: Ragnar Midtskogen
- FTP will not accept password from a batch file
- Prev by Date: Re: FTP on SBS2003 R2/IIS V6.0/ISA Server 2004
- Next by Date: Non-technical staff to download website pages securely
- Previous by thread: FTP will not accept password from a batch file
- Next by thread: Re: FTP will not accept password from a batch file
- Index(es):
Relevant Pages
|
|