Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Need help in FTP

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics
View previous topic :: :: View next topic  
Author Message
Satheeshkumar

New User


Joined: 20 Feb 2009
Posts: 51
Location: Chennai

PostPosted: Wed Nov 11, 2009 4:00 pm    Post subject: Need help in FTP
Reply with quote

In my job FTP step ran with return code zero,

but the sysout of the FTP step throws the ERROR access is denied.

can anyone tell how i can abend the job if the ftp gets the error access is denied

250 CWD command successful.
EZA1460I Command:
EZA1736I PUT 'KO38PO.NUMKE.WDJ(0)' WNM_MNUEW_FIRST_YR_PREM_INFO_091110.TXT
EZA1701I >>> SITE FIXrecfm 264 LRECL=264 RECFM=FB BLKSIZE=27984
500 'SITE FIXrecfm 264 LRECL=264 RECFM=FB BLKSIZE=27984': command not understoo
EZA1701I >>> PORT 10,9,199,41,118,137
200 PORT command successful.
EZA1701I >>> STOR WNM_MNUEW_FIRST_YR_PREM_INFO_091110.TXT
550 WNM_MNUEW_FIRST_YR_PREM_INFO_091110.TXT: Access is denied.
EZA1460I Command:
Back to top
View user's profile Send private message

LearningDb2

New User


Joined: 19 Jun 2009
Posts: 40
Location: India

PostPosted: Wed Nov 11, 2009 4:32 pm    Post subject:
Reply with quote

Hi,
Do you use EXIT parameter in your FTP job..
This parameter is used to exit the ftp job when an error is encountered.

You can also give the non zero mvs return codes for which the job will exit.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8151
Location: East Dubuque, Illinois, USA

PostPosted: Wed Nov 11, 2009 4:48 pm    Post subject:
Reply with quote

I suspect your problem is the GDG reference in the PUT statement. Use a DD name reference instead -- if you read the Communications Server User's Guide and Command Reference manual, you will note that there are NO sample jobs that have a GDG transferred in the way you're doing. This is not conclusive but certainly indicative that PUT GDG(0) remotefilename is not supported.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4650
Location: Raleigh, NC, USA

PostPosted: Wed Nov 11, 2009 5:29 pm    Post subject: Reply to: Need help in FTP
Reply with quote

And ...

500 'SITE FIXrecfm 264 LRECL=264 RECFM=FB BLKSIZE=27984': command not understood

you guys have got to get into the habit of disabling the sending of the SITE command to servers that don't support it.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8151
Location: East Dubuque, Illinois, USA

PostPosted: Wed Nov 11, 2009 5:34 pm    Post subject:
Reply with quote

Quote:
you guys have got to get into the habit of disabling the sending of the SITE command to servers that don't support it.
I was going to mention that, Kevin, but forgot to. SENDSITE is so easy to add to the command stream.
Back to top
View user's profile Send private message
Satheeshkumar

New User


Joined: 20 Feb 2009
Posts: 51
Location: Chennai

PostPosted: Thu Nov 12, 2009 1:12 pm    Post subject:
Reply with quote

Please find the INPUT CARD for the ftp

servername.com
id
password
CD WDJ
PUT 'KO38PO.NUMKE.WDJ(0)' TEST.TXT
CLOSE
QUIT

After executing FTP step throws return code zero, sysout of the FTP step has the error message access is denied. but the file was not transfered to the server.

can anyone tell me how to abend the FTP step, when the ftp step gets the access is denied error message.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8151
Location: East Dubuque, Illinois, USA

PostPosted: Thu Nov 12, 2009 5:53 pm    Post subject:
Reply with quote

Quote:
can anyone tell me how to abend the FTP step, when the ftp step gets the access is denied error message.
Without seeing the exact JCL you are using (you can change the IP address to protect it), no.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4650
Location: Raleigh, NC, USA

PostPosted: Thu Nov 12, 2009 7:28 pm    Post subject: Re: Need help in FTP
Reply with quote

Satheeshkumar wrote:
can anyone tell how i can abend the job if the ftp gets the error access is denied


I just ran a test to see what I would take to make the same event occur. If I run the FTP program without any EXIT parameters, it ends with RC=0 regardless of what happens, which is what's supposed to happen:

4.11 FTP return codes.

By adding either PARM='(Exit' or PARM='(Exit=4' I get a non-zero return code back for the 550 FTP Error Message. Now, neither of these is going to cause a job abend as you've requested. But, you can then code a subsequent step, based on your FTP step return-code, to force the abend. Or, preferably, you can setup your schedule to indicate a job failure for the non-zero return-code.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us