Hi,
If you haven't found it already, you can use the pairevtwait command. (Check out the syntax in the CCI Command Reference Manual)
Use the -nowait option to report on the status of the PVOL
Use the -nowaits option to report on the status of the SVOL
Return Codes for when the -nowait option is specified: (PVOL Status)
■ 1: The status is SMPL.
■ 2: The status is COPY or RCPY.
■ 3: The status is PAIR.
■ 4: The status is PSUS.
■ 5: The status is PSUE.
■ Return Codes for when the -nowaits option is specified: (SVOL Status)
■ 1: The status is SMPL.
■ 2: The status is COPY or RCPY.
■ 3: The status is PAIR.
■ 4: The status is SSUS (Note that SVOL_PSUS appears as SSUS).
■ 5: The status is PSUE
I have used this in a clunky Windows Bat script before that sent the latest pairdisplay output file (as you have already done) as an email attachment when a certain return code was given from the pairevtwait command.