z/OS DFSMSdfp Advanced Services
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Renaming a Data Set That Might be in Use

z/OS DFSMSdfp Advanced Services
SC23-6861-01

You can rename a data set that is allocated to the current address space but it cannot be open.

In general, you cannot rename a data set whose name is the same as any data set that is allocated to another address space in the same system or in the scope of the SYSDSN enqueue. The system bypasses this restriction if all of the following are true:
  • Your program sets on a certain bit in the CAMLST macro expansion. You can code this instruction: OI listname+2,X'10'.
  • You have at least read authority to the RACF® facility class named STGADMIN.DPDSRN.olddsname, where olddsname is up to 23 characters of the existing data set name. You can use a generic class name such as STGADMIN.DPDSRN.SYS2.*. IBM® recommends that no one have authority to STGADMIN.DPDSRN.* because it is too broad.
  • The data set is not SMS-managed.

Alternatively, you can use the data set rename option of PDF. If you attempt to rename a non-SMS-managed, non-VSAM data set, the data set name is in use and you have the appropriate RACF facility class authority, then PDF asks whether you wish to proceed because you know that the data set is not actually open. Let the rename proceed only if you know the data set being renamed is not open on any system.

Attention: This option should be used with extreme caution. Very few people should have RACF authority to STGADMIN.DPDSRN.olddsname. Do not use this option unless you know the data set is not open on any system. After the data set is renamed, someone could delete it in a different address space. If someone has it open by the old name, new data sets will appear at those places on the disk. This would be a security violation that the system does not detect.

The data set rename function writes a type 18 SMF record to provide information to storage administrators, system programmers, and auditors. The record contains an indicator of whether it was successful due to the use of this duplicate name override function. If you request the option in the CAMLST macro expansion but the data set name is not in use, then the SMF indicator will not be on.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014