Q

Using an FTP script to send a text file from AIX to AS/400

ISeries PC/Windows connectivity expert Shahar Mor explains how to send a text file from an AIX machine on Linux to a remote AS/400.

This Content Component encountered an error
Can you please provide a step-by-step procedure to send a text file from AIX on a Linux platform to an IBM AS/400 remote system? Can you provide the full script of what I should do from beginning to end?
Your best option is to use FTP script from the AIX machine to the AS/400 as follows:
  1. Start FTP server on AS/400 using the STRTCPSVR *FTP command
  2. Obtain the AS/400 details (user, password, name, address)
  3. Use LFTP. It is sophisticated file transfer program with a command-line interface. For example, the following will send file zz.text. The variables are:
    • $FTPU is FTP user
    • $FTPP is user password
    • $FTPS is AS/400 address and name

lftp -u $FTPU,$FTPP -e "cd qgpl; mput /dir /zz.txt; quit" $FTPS

A description for LFTP can be obtained here

This was first published in March 2008

Dig deeper on FTP

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchEnterpriseLinux

SearchDataCenter

Close