FTP from AIX to Mainframe


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting FTP from AIX to Mainframe
# 22  
Old 01-05-2018
You would have to use a checksum algorithm that is the same on both hosts, and I don't know what that would be for MVS. Choosing one that doesn't match may leave you thinking every transfer has failed.

If you can work it out, you may be able to use ftp sub-sommands to run a job on the MVS server on completion of the transfer. If you open up the connection and then type rhelp you will get the commands available and can explore them, e.g rhelp site but I can't remember what it was. Sadly it might have been an AS400 that we used to submit jobs on, so I might be going the wrong way.

Other options, depended on what is supported:-
  • Use SFTP which confirms accurate delivery (or not)
  • Use SSH or remote shell to submit your checksum batch job
  • Pull the files back again (to a separate location) and compare. Of course if the files are large this might not be acceptable in time and space.



I hope that some of this is useful,
Robin

Last edited by rbatte1; 01-05-2018 at 05:28 AM.. Reason: Took out IBM ref. doc.
This User Gave Thanks to rbatte1 For This Post:
# 23  
Old 01-07-2018
Quote:
Originally Posted by rbatte1
You would have to use a checksum algorithm that is the same on both hosts, and I don't know what that would be for MVS. Choosing one that doesn't match may leave you thinking every transfer has failed.

If you can work it out, you may be able to use ftp sub-sommands to run a job on the MVS server on completion of the transfer. If you open up the connection and then type rhelp you will get the commands available and can explore them, e.g rhelp site but I can't remember what it was. Sadly it might have been an AS400 that we used to submit jobs on, so I might be going the wrong way.

Other options, depended on what is supported:-
  • Use SFTP which confirms accurate delivery (or not)
  • Use SSH or remote shell to submit your checksum batch job
  • Pull the files back again (to a separate location) and compare. Of course if the files are large this might not be acceptable in time and space.



I hope that some of this is useful,
Robin
Thanks Robin.

I am using
Code:
ftp -siv HOSTNAME PORT_NUM 2>&1 > ftp_log.log

and private mode of connection is also enabled which ensures integrity.

Now I want to ensure if the file has been successfully delivered in MVS or not
for that I am checking the ftp_log.log file for any errors.

Please let me know a better idea to verify the same.
# 24  
Old 01-08-2018
You might get the return message numbers in your output which would help. These are the 3-digit codes for each message and the are helpfully grouped. The definitions are listed here, although this is not an official source.

You can look for them something like this:-
Code:
grep -E "^[45][0-9][0-9] " ftp_log.log | grep -v "^[45][0-9][0-9] bytes"

The grep -v exclusion is in case you send a file with 400-599 bytes. It's not pretty, but it works for me. Sadly, after writing something really complex and flexible to transfer huge amounts of files around, I was off-shored and don't have access to the code any more, so this is from memory already 3 years old.

What do you get in your ftp_log.log file?




Robin
# 25  
Old 01-08-2018
Quote:
Originally Posted by TechGyaann
I can generate cksum in AIX Unix before/after transferring the file to get checksum and byte size of the file.
If you can do that, if you can natively access one system from the other, what do you need FTP for?
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. AIX

AIX Forum: FTP from AIX to Mainframe

This discussion thread is an extension to what was discussed in Shell scripting section. Please refer the post for the requirement: Requirement Post - Click Here The whole thread - Click Here I would like to know how I can use NDM to transfer file from AIX to Mainframe and to verify the... (3 Replies)
Discussion started by: TechGyaann
3 Replies

2. AIX

ODBC Connectivity between Oracle10g on AIX and Mainframe

Hi, I have a task of setting up connectivity between Oracle 10g (AIX) and Mainframe (1 library). Went through couple of documents, forums, blogs etc. MY understanding is ODBC Generic Connectivity is free from Oracle side. Question: (may be dumb to you) 1. Has anybody done this and would... (3 Replies)
Discussion started by: jvmani_1
3 Replies

3. UNIX for Advanced & Expert Users

FTP issues between mainframe and UNIX

Hi All, The issue is that, we have a dataset in mianframe whose record length is 153 characters. And a batch job ftpies it to the unix server(SunOS) as a test file. But the ftpied file in unix does not have a record length of 153 chars. Each record of 153 chars gets splited into two line of... (8 Replies)
Discussion started by: hareeshkumaru
8 Replies

4. AIX

Problems with SSH/SFTP between AIX and Mainframe

Hi, I'm not sure if this has been solved in this forum already but please do help me out if possible. Basically, I've already setup a passwordless SSH connection between 2 AIX IDs (say ID-1 and ID-2) with a Mainframe server ID (say MVSID). I'm able to successfully do an SSH from the AIX server to... (1 Reply)
Discussion started by: sambeet
1 Replies

5. Shell Programming and Scripting

FTP files to target Mainframe system

Hi Experts... Greetings for the day..! I just want to FTP the files to mainframe system.. my code is not working..and also i need to put the files in a particular directory in a specific naming format... ftp -i -n ${HOST_NAME} << END_FTP user ${USER_NAME} ${PASSWORD} put ${FILE_NAME}... (3 Replies)
Discussion started by: spkandy
3 Replies

6. UNIX for Dummies Questions & Answers

FTP'ing EBCDIC Characters from Mainframe

Hi All, I am new to this site, I have a requirement where in i have to FTP a file from mainframe to Unix box. The catch here is there are few Spanish characters like N with tilde(~) and a with ` etc., all other characters are coming fine but those mentioned above are not coming in a proper... (1 Reply)
Discussion started by: harikiranr
1 Replies

7. UNIX for Advanced & Expert Users

ftp file from unix to mainframe

thanks (2 Replies)
Discussion started by: ashishabhishek
2 Replies

8. UNIX and Linux Applications

ftp from unix to Mainframe

suppose i have a file named xyz(-1) and i have to transfer(ftp) it on a Mainframe from unix,how should i do it as whenever i try to do so it says use MVS naming conventions (1 Reply)
Discussion started by: ashishabhishek
1 Replies

9. HP-UX

ftp from unix to mainframe

hi suppose i have a file named xyz(-1) and i have to transfer(ftp) it on a Mainframe from unix,how should i do it as whenever i try to do so it says use MVS naming conventions (1 Reply)
Discussion started by: ashishabhishek
1 Replies

10. Shell Programming and Scripting

mainframe FTP error

Hi when i am trying to ftp to a newly cretaed mainframe GDG for the first time,i am getting the following error... Verbose mode on. 200 Representation type is Ebcdic NonPrint 200 Port request OK. 550-SVC99 Return code=4 S99INFO=0 S99ERROR=38668 HEX=970C S99ERSN code X'00004379'). 550... (1 Reply)
Discussion started by: sam99
1 Replies
Login or Register to Ask a Question