Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Automated FTP from as400 to internal lan ftp server?

316 views
Skip to first unread message

Tom Johnson

unread,
Jul 21, 2003, 8:28:03 AM7/21/03
to
I'm trying to automate an ftp session where I'm sending a file from the
as400 to an ftp server located on our lan.

I use the following to run a script:
PGM
OVRDBF FILE(INPUT) TOFILE(WTJ932/COIFILE) +
MBR(COIMBR1)
OVRDBF FILE(OUTPUT) TOFILE(WTJ932/COIFILE) +
MBR(COIMBR1)
FTP RMTSYS('10.4.1.14')
DLTOVR FILE(INPUT)
DLTOVR FILE(OUTPUT)
ENDPGM

For the script I use:
<blank line>
user wtj932 summer03a
ascii
cd c:/
lcd wtj932.lib
mput inforce.file
quit

When I run it I get the following:
Output redirected to a file.
Input read from specified override file.
Connecting to remote host 10.4.1.14 using port 21.
220- PMSLIC FTP Server WAR-FTPD 1.65 Ready
220 Please enter your user name.
Enter login ID (wtj932):
331 User name okay, Need password.
Please log in before issuing this command.
Enter an FTP subcommand.
> user wtj932 *********
530 Already logged in. New useraccount denied.
Enter an FTP subcommand.
> ascii
550 Please log in before issuing this command.
Enter an FTP subcommand.
> cd c:/
You must first issue the USER subcommand.
Enter an FTP subcommand.
> lcd wtj932.lib
Could not access library WTJ932.LIB.
Enter an FTP subcommand.
> mput inforce.file
You must first issue the USER subcommand
Enter an FTP subcommand.
> quit
221 Goodbye. Control connection closed.

I am completely confused about the user ID and Password. I've tried using
and FTP user ID and Password, a LAN user ID and Password and an AS400 user
ID and password but they all com up the same.

I'd like to start there and once thats done move on to the next issue.


J. Hilberts

unread,
Jul 21, 2003, 9:47:55 AM7/21/03
to
Hi tom,

Perhaps you should try to use two different filemembers.

One for input purpose and another for output.

You are using the same, so I would say after your username is keyed in, the
input file isn't the same anymore because the repsonse will be written in
the same file.

Good luck


"Tom Johnson" <tjoh...@pmslic.com> schreef in bericht
news:bfgm8j$42n6$1...@news.boulder.ibm.com...

Tom Johnson

unread,
Jul 21, 2003, 10:47:52 AM7/21/03
to
Thanks, I was just going to try that. I was able to get the file over. Now I
just need to clean up the process.

The most recent commands are:
0001.00 user dummy dummy
0002.00 close
0003.00 open '10.4.1.14'
0004.00 user coldfusion webstuff
0005.00 ascii
0006.00 mput inforce
0007.00 quit

I added the dummy user ID and password because I read that somewhere and
coupled with the close it then allowed the session to open and it accepted
the User ID and password. With this I am able to get the file to transfer.


"J. Hilberts" <jacques....@veilingzon.nl> wrote in message
news:bfgqui$3tq8$1...@news.boulder.ibm.com...

0 new messages