Tag Archives: VTOC

Deleting a File That Is “In Use”

Let’s step away from CICS for a minute and look at an issue that comes up from time to time … You want to delete a file, perhaps an old, uncataloged version of a dataset that is always open – say, SYS1.PROCLIB. If you go to the DSLIST screen in TSO (option 3.4) and enter the dataset name and volume, and try to delete it, you will be informed that the delete failed because the dataset was in use. There is a SYS1.PROCLIB in use, but it’s not the one you are trying to delete. You know what you are doing, but z/OS doesn’t trust you, it seems. (Actually, it’s just that z/OS enqueing is by dataset, not dataset and volume.) The way around this is to “zap” the VTOC to change the name of the dataset to something else that is not in use; then you can delete it.
Continue reading

Advertisements