Page 1 of 1

I need to FTP from MF to UNIX

Posted: Fri Jan 09, 2009 2:29 am
by vinay
Hi all
Can anybody send me a sample FTP script to migrate my dataset from MF to UNIX.Do we need to write the FTP script in a JCL script, if yes please somebody share a script of that kind.

Thanks,
Vinay

Posted: Fri Jan 09, 2009 11:20 am
by Natarajan
Hi,

we don't have to write any jcl in mainframe.

In UNIX execute the following :
$ ftp <ip address of mainframe>

then, you will see "ftp>" prompt as shown below.
ftp>

now type below commands to transfer the file from mainframe to unix.

ftp> bin (this specifies the format of the file to be downloaded).
ftp> get < ' mainframe datasetname' > <unix filename>

Note : mainframe dataset name must be in single quotes.



'

HOw to find the Ip address of the MF

Posted: Sat Jan 10, 2009 3:26 am
by vinay
Hi;
Thanks for the reply. Can you please tell me how to get the Ip address of my MF server.

Thanks
Vinay

Re: HOw to find the Ip address of the MF

Posted: Sat Jan 10, 2009 4:52 pm
by Anuj Dhawan
Hello,
vinay wrote:Can you please tell me how to get the Ip address of my MF server.
Use TSO HOMETEST to find the Mainfram IP. This IP Address can be used with FTP GET. ( to unload files from mainframe)

MF FTP 2 UNIX

Posted: Mon Jan 12, 2009 11:15 pm
by vinay
Hi Natraj

Here is the following error i get .It is asking for the ID and PWD, but what i dont understand is that whicj ID and PWD should i give. I have got the same PWD for both the Mainframe & Unix. Please suggest me what kind of ID and PWd is this asking for .

$ ftp 172.24.1.1
Connected to 172.24.1.1.
220-FTPD1 IBM FTP CS V1R9 at SYSD, 13:11:09 on 2009-01-12.
220 Connection will not time out.
Name (172.24.1.1:ab69295): ab69295
331 Send password please.
Password:
530 PASS command failed
Login failed.
ftp>

Posted: Tue Jan 13, 2009 10:21 am
by Natarajan
Use mainframe Userid and password.

It is not working

Posted: Tue Jan 13, 2009 8:52 pm
by vinay
Hi Natrajan

I tried it , but it still does not work. Can you please suggest me another way . What confuses me is i think i dont have access to do an FTP in the method you had told me so . Please suggest me in any other way you know.


Thanks
Vinay

Posted: Wed Feb 25, 2009 6:14 pm
by playboy049
I am new to this site. Here's i am sending you the solution how to send the files from MF to UNIX Through JCL.

//JOBCARD ............
//FTP EXEC PGM=FTP
//SYSPRINT DD SYSOUT=*
//OUTPUT DD SYSOUT=*,DCB=(RECFM=FB,LRECL=160,BLKSIZE=3200)
//INPUT DD DSN=TEST.CTLCARDS(MFUNIX),DISP=SHR
/*

TEST.CTLCARDS(MFUNIX)
-----------------------
xxxxxxxxxxxxxx <--- IP address of UNIX server
abcdef <-- User ID of UNIX mail box
123abc <--- Password
put 'File name'/download <--- Path that you need to keep the file
quit

I think it will work.

Please reply me If work or not.

Thanks
Playboy