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 Usergroups Profile Log in to check your private messages Log in
 

 

How to copy z/OS dataset to USS file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
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    Post subject: How to copy z/OS dataset to USS file
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
http://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: 7936
Location: Bellevue, IA

PostPosted: Thu Jul 26, 2012 7:39 pm    Post subject: Reply to: How to copy z/OS dataset to USS file
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    Post subject: Re: Reply to: How to copy z/OS dataset to USS file
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    IBMMAINFRAMES.com Support Forums -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 5 Tue Jan 17, 2017 4:26 pm
No new posts HALDB data refresh/copy from producti... vineetanand2007 IMS DB/DC 1 Mon Jan 02, 2017 11:16 am
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts syncsort: copy lines after the keyword shreya19 SYNCSORT 7 Fri Dec 02, 2016 9:47 am
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm


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