System information
92 Sharing and maintaining SLES 10 SP2 Linux under z/VM
'CP IPL' iplDisk
Else Do /* user is interactive -> prompt */
Say 'Do you want to IPL Linux from DASD' iplDisk'? y/n'
Parse Upper Pull answer .
If (answer = 'Y') Then
'CP IPL' iplDisk
End
Exit
1.11.7 RO2GOLD EXEC
The RO2GLD EXEC copies the disks that will become the read-only root system from S10ROGLD
to the 1xxx disks of S10GOLD:
/* Copy Linux from read-only ID to Gold ID */
'pipe cp link s10gold2 21b7 21b7 rr'
'pipe cp 10000 q links 21b7 |',
'split /,/|',
'strip|',
'strip /,/|',
'strip|',
'count lines |',
'var howmany |',
'console|',
'stem names.'
'cp det 21b7'
If (howmany > 1 ) Then Do
Say 'WARNING WARNING WARNING WARNING!'
Say 'You have Linux guests currently reading the S10GOLD'
Say 'disks. Running this script would cause problems!'
Say 'WARNING WARNING WARNING WARNING!'
Exit 1
End
/* Copy Linux from read-only ID to Gold ID */
Address 'COMMAND'
source = 'S10ROGLD'
target = 'S10GOLD'
ro_addrs = '01B0 01B1 01B4 01B5 01B6 01B7 01B8'
rw_addrs = '21B0 21B1 21B4 21B5 21B6 21B7 21B8'
Say ' '
Say 'Checking that source and target user IDs are logged off'
Call CheckLoggedOff source
Call CheckLoggedOff target
Say ' '
Say 'Do you want to copy disks from S10ROGLD to S10GOLD? y/n'
Parse Upper Pull answer .
If (answer \= 'Y') Then Exit 1
/* link target disks R/W */
Do a = 1 to Words(rw_addrs)
addr = Word(rw_addrs,a)
'CP LINK' target addr addr 'MR'
If (rc \= 0) Then Call CleanUp 100+a
End
/* link source disks R/O */