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

How to copy z/OS dataset to USS file


IBM Mainframe Forums -> TSO/ISPF
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
chaoj

Active User


Joined: 03 Jun 2010
Posts: 103
Location: Dalian

PostPosted: Thu Jul 26, 2012 7:25 pm
Reply with quote

I'm trying to copy z/OS dataset to USS file using the JCL below
but get a error

JCL
Code:

//COPYSTEP EXEC PGM=IKJEFT01                         
//INMVS DD DSN=EV6946.USS.TO.MVS,DISP=OLD             
//OUTHFS DD PATH='/SYSTEM/tmp/EV605H.GV55.DS.SLD9998'
//SYSTSPRT DD SYSOUT=*                               
//SYSPRINT DD SYSOUT=*                               
//SYSTSIN DD *                                       
OCOPY INDD(INMVS) OUTDD(OUTHFS) TEXT                 
/*                                                   


Error
Code:

READY                                                                           
OCOPY INDD(INMVS) OUTDD(OUTHFS) TEXT                                           
RETURN CODE 0000006F, REASON CODE 00000004.  AN ERROR OCCURRED DURING THE OPENING OF HFS FILE /SYSTEM/tmp/EV605H.GV55.DS.SLD9998.
READY                                                                           
END                                                                             


I read the sample below
publib.boulder.ibm.com/infocenter/zos/v1r13/index.jsp?topic=%2Fcom.ibm.zos.r13.bpxa500%2Ftsoocopy.htm

could anyone tell me what's wrong with my code ?
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: Thu Jul 26, 2012 7:39 pm
Reply with quote

The 6F return code is given as "Permission is denied" in the Unix System Services MAC manual. The user id the job ran under does not have write access to at least one of the directory levels in your path name, or the file already exists and the user id cannot write to that file.
Back to top
View user's profile Send private message
chaoj

Active User


Joined: 03 Jun 2010
Posts: 103
Location: Dalian

PostPosted: Fri Jul 27, 2012 7:27 am
Reply with quote

Robert Sample wrote:
The 6F return code is given as "Permission is denied" in the Unix System Services MAC manual. The user id the job ran under does not have write access to at least one of the directory levels in your path name, or the file already exists and the user id cannot write to that file.


Thank you Robert !

I add a Permission Parm and create file in DD like below , it worked !

Code:

//COPYSTEP EXEC PGM=IKJEFT01                                 
//INMVS DD DSN=EV6946.USS.TO.MVS,DISP=OLD                   
//OUTHFS DD PATH='/SYSTEM/tmp/EV6946.MVS.TO.USS2',           
//         PATHOPTS=(OCREAT,OWRONLY),PATHMODE=(SIRUSR,SIWUSR)
//SYSTSPRT DD SYSOUT=*                                       
//SYSPRINT DD SYSOUT=*                                       
//SYSTSIN DD *                                               
OCOPY INDD(INMVS) OUTDD(OUTHFS) BINARY CONVERT(NO)           
/*                                                           
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 -> TSO/ISPF

 


Similar Topics
Topic Forum Replies
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts Need help for File Aid JCL to extract... Compuware & Other Tools 23
Search our Forums:

Back to Top