If you are running multiple z/VSE system, you may share data between those systems. z/VSE provides DASD sharing through a lock file for that purpose, which is provided by the lock manager in the Supervisor. That's my topic for today.
The beginning of the 1980's I was responsible for the lock manger function. That also led me to my first international trip for IBM to Amsterdam (Netherlands) in 1984. I had to give a education session about lock management to the VSE Supervisor Level 2 team, which was located there at that time. By the way Amsterdam is one of my favorite cities since then. It's worth a trip.
Now a few words about DASD sharing: In an application you may lock a resource - defined by the DTL (Define the Lock) macro - e.g. to be locked for exclusive use. That is you may synchronize access to a specific code path or access to data on a disk. You may lock resources locally within one z/VSE system, or you may lock a resource across systems. In the latter case you have to define a lock file during IPL via the DLF command. Disks you want to share need to have the SHR parameter on the IPL ADD statement. My recommendation: Do not allocate the lock file on the system disks DOSRES or SYSWK1. For a SCSI disk such a DLF command would be rejected. I would allocate it on a small disk with just the lock file on it, but that is your choice. All systems that want to participate in sharing need to have access to that lock file and a corresponding IPL DLF statement. If an application locks a resource, the CPU id of that system, the resource name and the lock option (e.g. exclusive lock) are written to the lock file. That is you have to ensure, that CPU ids are unique for all z/VSE systems that access the lock file. I/O to the lock file is controlled by the reserve / release channel commands (exclusive access to the lock file - and to the corresponding disk).
If you are running your z/VSE systems in z/VM guests you have to define the lock file on (mini-) disks with multiple write (MWV). You may also allocate the lock file on a z/VM virtual disk.
The system disks (DOSRES or SYSWK1) should not be shared. If you put the SHR parameter to the IPL ADD statement of those system disks the message "0I23I DASD ON 007 NOT PHYSICALLY SHARABLE" will be written to the console. The SHR option is not reset, however. A lock error message may occur later dependent on your environment..
More information on DASD sharing is in the z/VSE Guide to System Function, which can be downloaded from our documentation web page.
Today is a public holiday in the United States (Independence Day) and at the 2014 FIFA World Cup we are looking forward to the soccer game France vs. Germany.
Enjoy the game and your (long) weekend.
Etiquetas: 
sharing
lock_file
dasd_sharing
vse