IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Batch job submission using FTP


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
arunramakrishnan

New User


Joined: 23 Mar 2004
Posts: 4

PostPosted: Tue Mar 23, 2004 4:49 pm
Reply with quote

Hi,

My requirement is to submit a batch job from the PC and get back the status of the job using ftp commands.
I was successfull in submitting a job on the mainframe using the following commands

ftp IP Address
User ID
Password
quote site filetype=jes
put jcl.txt

Then when I try to view the status of the job submitted using the command
dir
it displays the following message
No Jobs found on the Held queue

Further we tried to retrieve the status using the "get" command
i.e.
GET JOBnnnnn
but this gives the following error
Error opening local file JOBnnnnn
>JOBnnnnn: Permission denied.

Kindly help.

Thanks & Regards,
Arun
Back to top
View user's profile Send private message
bluebird

Active User


Joined: 03 Feb 2004
Posts: 127

PostPosted: Tue Mar 23, 2004 6:13 pm
Reply with quote

I believe you shoud start by :
having a jobname of youruserid + one char

it should solve your pbm.
Back to top
View user's profile Send private message
arunramakrishnan

New User


Joined: 23 Mar 2004
Posts: 4

PostPosted: Tue Mar 23, 2004 7:09 pm
Reply with quote

bluebird wrote:
I believe you shoud start by :
having a jobname of youruserid + one char

it should solve your pbm.

Hi,

Thanks for your reply but the JOBnnnnn refers to job number and I tried the GET command with the jobname but it still gives me the same error.

Regards,
Arun
Back to top
View user's profile Send private message
bluebird

Active User


Joined: 03 Feb 2004
Posts: 127

PostPosted: Tue Mar 23, 2004 8:26 pm
Reply with quote

your list does not even show any job output how do you want to retrieve anything ?
1 your job submitted via ftp should have a jobname of your userid +1 char

then the process shopuld work ok.

(it works at my shop, I can see all job with myuserid+1 char and am able to GET any of them)
Back to top
View user's profile Send private message
arunramakrishnan

New User


Joined: 23 Mar 2004
Posts: 4

PostPosted: Wed Mar 24, 2004 9:02 am
Reply with quote

Hi,

To make my point more clear here is the series of commands used by me and the results

ftp> Connected to ********.

open ********
220-FTPD1 IBM FTP CS V2R8 at S01MFP02, 13:33:22 on 2004-02-04.
220 Connection will close if idle for more than 5 minutes.
User (********:(none)):
331 Send password please.

230 FO is logged on. Working directory is "FO.".
ftp> ftp>
quote site FILETYPE=JES RECFM=F LRECL=80 BLKSIZE=80
200 Site command was accepted
ftp> put .\jcl.txt
200 Port request OK.
125 Sending Job to JES internal reader FIXrecfm 80
250-It is known to JES as JOB08662
250 Transfer completed successfully.
918 bytes sent in 0,00 seconds (918000,00 Kbytes/sec)

ftp> dir
200 Port request OK.
125 List started OK
No jobs found on Held queue

250 List completed successfully.
29 bytes received in 0,00 seconds (29000,00 Kbytes/sec)

Hope this makes the things more clear. The jobname is FOITCMD in which the first two characters are is my the user ID.

Thanks & Regards,
Arun
Back to top
View user's profile Send private message
arunramakrishnan

New User


Joined: 23 Mar 2004
Posts: 4

PostPosted: Wed Mar 24, 2004 12:16 pm
Reply with quote

bluebird wrote:
your list does not even show any job output how do you want to retrieve anything ?
1 your job submitted via ftp should have a jobname of your userid +1 char

then the process shopuld work ok.

(it works at my shop, I can see all job with myuserid+1 char and am able to GET any of them)


Thanks for your suggestion, it worked.
I found that the JESINTERFACELEVEL=1 for our system and with interface level the job name has to be the userid and 1 character. Hence it didnt show my job as it had more than one character after my user ID. To be able to use longer JOB name the JESINTERFACELEVEL should be set to 2
One additional requirement is it possible to retrieve just the return code of the job so as to understand the success of the job.
Back to top
View user's profile Send private message
bluebird

Active User


Joined: 03 Feb 2004
Posts: 127

PostPosted: Wed Mar 24, 2004 1:01 pm
Reply with quote

hello,

thanks for your info about jesintervallevel is it in jes parmlib ?

is it possible to retrieve just the return code of the job so as to understand the success of the job.

is this a question ?

in that case I don't know but will look around see if I can get anything...
Back to top
View user's profile Send private message
NairS

New User


Joined: 01 Apr 2004
Posts: 1

PostPosted: Thu Apr 01, 2004 5:17 am
Reply with quote

Hello folks.

JESINTERFACELEVEL 2 provides a lot of additional functions.

To find out what JESINTERFACELEVEL the server is at:
Logon to the FTP server
Issue "QUOTE SITE FILETYPE=JES"
Issue "QUOTE STAT"
===============================================

The requirement about retrieving the return code of a job would also get satisfied under JESINTERFACELEVEL 2
Under JESINTERFACELEVEL 2, issue "DIR"

The output can be filtered by setting variables JESJOBNAME, JESSTATUS and JESOWNER
===============================================

JESINTERFACELEVEL is set in the FTP Data file

Most of the shops have SYSFTPD DD card in the FTP started task JCL pointing to the FTP Data file
(If you do not have the DD coded, look up the IP configuration guide to find the dataset search order)

The default for JESINTERFACELEVEL is 1

DO NOT set JESINTERFACELEVEL to 2 unless you have proper spool access security in place
Back to top
View user's profile Send private message
bluebird

Active User


Joined: 03 Feb 2004
Posts: 127

PostPosted: Thu Apr 01, 2004 12:28 pm
Reply with quote

hello nairs,
thanx a lot for the info.
I'll check my FTP started task.
and do not worry, I don't think I have proper access to modify anything.

anyway thanx
Back to top
View user's profile Send private message
John Edward Areja

New User


Joined: 05 Sep 2007
Posts: 1
Location: Philippines

PostPosted: Thu Sep 06, 2007 3:25 pm
Reply with quote

Hi,


Quote:

is it possible to retrieve just the return code of the job so as to understand the success of the job.

is this a question ?

in that case I don't know but will look around see if I can get anything...


was anybody able to look for the answer to this? I was able to verify that the job was transferred successfully. But I want to know if there is a way to check if the job didn't complete. Any help would be very much appreciated. Thanks! icon_smile.gif
Back to top
View user's profile Send private message
ganeshprasanna

New User


Joined: 21 Feb 2009
Posts: 36
Location: South Portland, Maine

PostPosted: Sat Feb 21, 2009 5:09 pm
Reply with quote

Trying the same as arunramakrishnan did his above post. I found out that JESINTERFACELEVEL = 1 in my server using "QUOTE STAT" .

How do i go about changing this JESINTERFACELEVEL to 2. Is it advisable to change this?

Your help is appriciated.

Thanks,
Ganeshprasanna
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Sat Feb 21, 2009 5:46 pm
Reply with quote

Add to your FTP job:
Code:
//SYSFTPD DD *
JESINTERFACELEVEL=2
/*
However, unless your systems support group has done the JES and security changes to support this, your changes will not work. This is site dependent and you must contact your systems support people for help.
Back to top
View user's profile Send private message
ganeshprasanna

New User


Joined: 21 Feb 2009
Posts: 36
Location: South Portland, Maine

PostPosted: Sat Feb 21, 2009 5:51 pm
Reply with quote

Thank You Robert icon_smile.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts How to get a stack trace on a looping... ABENDS & Debugging 5
No new posts Calling Java method from batch COBOL ... COBOL Programming 5
No new posts Help in Automating Batch JCL jobs mon... JCL & VSAM 3
No new posts Batch install term/printer CICS 2
No new posts File Aid Batch IBM Tools 7
Search our Forums:

Back to Top