_mnt (Filesystems)
Secondary Site VCS Configuration File:
include "types.cf"
include "ClusterMonitorConfigType.cf"
include "Db2udbTypes.cf"
include "VVRTypes.cf"
cluster e3clus177 (
UserNames = { admin = ajkCjeJgkFkkIskEjh }
ClusterAddress = "10.10.231.191"
Administrators = { admin }
CredRenewFrequency = 0
CounterInterval = 5
)
system sunsrv01-dr (
)
system sunsrv02-dr (
)
group CCAvail (
SystemList = { sunsrv01-dr = 0, sunsrv02-dr = 1 }
AutoStartList = { sunsrv01-dr, sunsrv02-dr }
)
ClusterMonitorConfig CCAvail_ClusterConfig (
MSAddress = "10.11.198.53"
ClusterId = 1183482234
VCSLoggingLevel = TAG_A
Logging = "/opt/VRTSccacm/conf/k2_logging.properties"
ClusterMonitorVersion = "4.1.2272.1"
)
Process CCAvail_ClusterMonitor (
PathName = "/opt/VRTSccacm/bin/ClusterMonitor"
Arguments = "-config"
)
CCAvail_ClusterMonitor requires CCAvail_ClusterConfig
group db2inst_grp (
SystemList = { sunsrv01-dr = 0, sunsrv02-dr = 1 }
Enabled @sunsrv01-dr = 0
Enabled @sunsrv02-dr = 0
AutoStart = 0
)
Application adsm_db2inst (
Enabled = 0
Critical = 0
User = root
StartProgram = "/bcp/db2inst/tsm/adsmcad.db start"
StopProgram = "/bcp/db2inst/tsm/adsmcad.db stop"
MonitorProcesses = {
"/usr/bin/dsmcad -optfile=/bcp/db2inst/tsm/dsm.opt.db2inst" }
)
Db2udb db2inst_db (
Enabled = 0
Critical = 0
DB2InstOwner = db2inst
DB2InstHome = "/db2/db2inst"
MonScript = "/opt/VRTSvcs/bin/Db2udb/SqlTest.pl"
)
DiskGroup db2dgB_dg (
Enabled = 0
DiskGroup = db2dgB
)
IP db2inst_ip (
Enabled = 0
Device = ce1
Address = "10.10.231.191"
)
Mount db2dgB_bkup_mnt (
Enabled = 0
MountPoint = "/backup/db2inst"
BlockDevice = "/dev/vx/dsk/db2dgB/bkp"
FSType = vxfs
FsckOpt = "-y"
)
Mount db2inst_bcp_mnt (
Enabled = 0
MountPoint = "/bcp/db2inst"
BlockDevice = "/dev/vx/dsk/db2dg/bcp"
FSType = vxfs
MountOpt = rw
FsckOpt = "-y"
)
Mount db2inst_db2_mnt (
Enabled = 0
MountPoint = "/db2/db2inst"
BlockDevice = "/dev/vx/dsk/db2dg/db2"
FSType = vxfs
MountOpt = rw
FsckOpt = "-y"
)
Mount db2inst_db_mnt (
Enabled = 0
MountPoint = "/db/db2inst/PEMMP00P/NODE0000"
BlockDevice = "/dev/vx/dsk/db2dg/db"
FSType = vxfs
MountOpt = rw
FsckOpt = "-y"
)
Mount db2inst_dba_mnt (
Enabled = 0
MountPoint = "/dba/db2inst"
BlockDevice = "/dev/vx/dsk/db2dg/dba"
FSType = vxfs
MountOpt = rw
FsckOpt = "-y"
)
Mount db2inst_lg1_mnt (
Enabled = 0
MountPoint = "/db/db2inst/log1"
BlockDevice = "/dev/vx/dsk/db2dg/lg1"
FSType = vxfs
MountOpt = rw
FsckOpt = "-y"
)
Mount db2inst_tp01_mnt (
Enabled = 0
MountPoint = "/db/db2inst/PEMMP00P/tempspace01/NODE0000"
BlockDevice = "/dev/vx/dsk/db2dg/tp01"
FSType = vxfs
MountOpt = rw
FsckOpt = "-y"
)
NIC db2inst_ce1 (
Enabled = 0
Device = ce1
NetworkType = ether
)
RVGPrimary db2dg_rvg_primary (
Enabled = 0
Critical = 0
RvgResourceName = db2dgAgent
)
requires group db2inst_vvr online local firm
adsm_db2inst requires db2inst_bcp_mnt
db2dgB_bkup_mnt requires db2dgB_dg
db2inst_bcp_mnt requires db2dg_rvg_primary
db2inst_db requires db2inst_bcp_mnt
db2inst_db requires db2inst_db2_mnt
db2inst_db requires db2inst_db_mnt
db2inst_db requires db2inst_dba_mnt
db2inst_db requires db2inst_ip
db2inst_db requires db2inst_lg1_mnt
db2inst_db requires db2inst_tp01_mnt
db2inst_db2_mnt requires db2dg_rvg_primary
db2inst_db_mnt requires db2dg_rvg_primary
db2inst_dba_mnt requires db2dg_rvg_primary
db2inst_ip requires db2inst_ce1
db2inst_lg1_mnt requires db2dg_rvg_primary
db2inst_tp01_mnt requires db2dg_rvg_primary
group db2inst_vvr (
SystemList = { sunsrv01-dr = 0, sunsrv02-dr = 1 }
)
DiskGroup db2dg_dg (
DiskGroup = db2dg
)
IP vvrip (
Device = ce5
Address = "10.12.94.191"
NetMask = "255.255.254.0"
)
NIC vvrnic (
Device = ce5
NetworkType = ether
)
RVG db2dgAgent (
Critical = 0
RVG = db2dg_rvg
DiskGroup = db2dg
)
db2dgAgent requires db2dg_dg
vvrip requires vvrnic
group snap_db2inst_grp (
SystemList = { sunsrv01-dr = 0, sunsrv02-dr = 1 }
AutoStart = 0
)
Db2udb snap_db2inst_db (
Critical = 0
DB2InstOwner = db2inst
DB2InstHome = "/db2/db2inst"
MonScript = "/opt/VRTSvcs/bin/Db2udb/SqlTest.pl"
)
DiskGroup snap_db2dgB_dg (
DiskGroup = db2dgB
)
IP snap_db2inst_ip (
Device = ce1
Address = "10.10.231.191"
)
Mount snap_db2dgB_bkup_mnt (
MountPoint = "/backup/db2inst"
BlockDevice = "/dev/vx/dsk/db2dgB/bkp"
FSType = vxfs
FsckOpt = "-y"
)
Mount snap_db2inst_bcp_mnt (
MountPoint = "/bcp/db2inst"
BlockDevice = "/dev/vx/dsk/db2dg/bcp_snapvol"
FSType = vxfs
FsckOpt = "-y"
)
Mount snap_db2inst_db2_mnt (
MountPoint = "/db2/db2inst"
BlockDevice = "/dev/vx/dsk/db2dg/db2_snapvol"
FSType = vxfs
FsckOpt = "-y"
)
Mount snap_db2inst_db_mnt (
MountPoint = "/db/db2inst/PEMMP00P/NODE0000"
BlockDevice = "/dev/vx/dsk/db2dg/db_snapvol"
FSType = vxfs
FsckOpt = "-y"
)
Mount snap_db2inst_dba_mnt (
MountPoint = "/dba/db2inst"
BlockDevice = "/dev/vx/dsk/db2dg/dba_snapvol"
FSType = vxfs
FsckOpt = "-y"
)
Mount snap_db2inst_lg1_mnt (
MountPoint = "/db/db2inst/log1"
BlockDevice = "/dev/vx/dsk/db2dg/lg1_snapvol"
FSType = vxfs
FsckOpt = "-y"
)
Mount snap_db2inst_tp01_mnt (
MountPoint = "/db/db2inst/PEMMP00P/tempspace01/NODE0000"
BlockDevice = "/dev/vx/dsk/db2dg/tp01_snapvol"
FSType = vxfs
FsckOpt = "-y"
)
NIC snap_db2inst_ce1 (
Device = ce1
NetworkType = ether
)
requires group db2inst_vvr online local firm
snap_db2dgB_bkup_mnt requires snap_db2dgB_dg
snap_db2inst_db requires snap_db2inst_bcp_mnt
snap_db2inst_db requires snap_db2inst_db2_mnt
snap_db2inst_db requires snap_db2inst_db_mnt
snap_db2inst_db requires snap_db2inst_dba_mnt
snap_db2inst_db requires snap_db2inst_lg1_mnt
snap_db2inst_db requires snap_db2inst_tp01_mnt
snap_db2inst_ip requires snap_db2inst_ce1
Bring up VCS engine and bring up the vvr service group in the Secondary Site
Start VCS on both nodes
sunsrv01-dr:# hastart
sunsrv02-dr:# hastart
Bring up the VVR Service Group on one node
sunsrv01-dr:# hagrp –online db2inst_vvr –sys sunsrv01-dr
Bring up VCS engine and bring up the vvr service group in the Primary Site
Start VCS on both nodes
sunsrv01:# hastart
sunsrv02:# hastart
Bring up the VVR Service Group on one node
sunsrv01:# hagrp –online db2inst_vvr –sys sunsrv01
Bring up the Application Service Group
sunsrv01:# hagrp –online db2inst_grp –sys sunsrv01
Check the Rlink and RVG status
Make sure that the flags are attached and connected. If for some reason links were detached or disconnected, check to make sure that the communications between the primary site and the secondary site are working fine. You should be able to ping, ssh, or telnet from each site thru the VIPs. If communications are good, you may restart VVR (see next step for restarting VVR engine).
sunsrv01:# vxprint -Pl
Disk group: db2dg
Rlink: rlk_db2instdr-vipvr_db2dg_rvg
info: timeout=500 packet_size=8400 rid=0.2007
latency_high_mark=10000 latency_low_mark=9950
bandwidth_limit=none
state: state=ACTIVE
synchronous=off latencyprot=off srlprot=autodcm
assoc: rvg=db2dg_rvg
remote_host=db2instdr-vipvr IP_addr=10.12.94.191 port=4145
remote_dg=db2dg
remote_dg_dgid=1182230506.2373.sunsrv01-dr
remote_rvg_version=21
remote_rlink=rlk_db2inste3-vipvr_db2dg_rvg
remote_rlink_rid=0.2127
local_host=db2inste3-vipvr IP_addr=10.11.196.191 port=4145
protocol: UDP/IP
flags: write enabled attached consistent cant_sync connected asynchronous autosync
sunsrv01:# vradmin -l printrvg
Replicated Data Set: db2dg_rvg
Primary:
HostName: db2inste3-vipvr
RvgName: db2dg_rvg
DgName: db2dg
datavol_cnt: 6
srl: db2dg_srl
RLinks:
name=rlk_db2instdr-vipvr_db2dg_rvg, detached=off, synchronous=off
Secondary:
HostName: db2instdr-vipvr
RvgName: db2dg_rvg
DgName: db2dg
datavol_cnt: 6
srl: db2dg_srl
RLinks:
name=rlk_db2inste3-vipvr_db2dg_rvg, detached=off, synchronous=off
Restart VVR engine (if the link is detached or disconnected)
This is only required if you see the links between primary and secondary as detached or disconnected. If you think that the communication between the two is working fine, then run the following commands in the primary site:
sunsrv01:# vxstart_vvr stop
sunsrv01:# vxstart_vvr start
Then, check the status again.
sunsrv01:# vxprint -Pl
Start the replication
Initiate the command from the primary site.
sunsrv01:# vradmin -g db2dg -a startrep db2dg_rvg db2instdr-vipvr
Message from Primary:
VxVM VVR vxrlink WARNING V-5-1-3359 Attaching rlink to non-empty rvg.
Autosync will be performed.
VxVM VVR vxrlink INFO V-5-1-3614 Secondary data volumes detected with rvg db2dg_rvg as parent:
VxVM VVR vxrlink INFO V-5-1-6183 bcp: len=585105408 primary_datavol=bcp
VxVM VVR vxrlink INFO V-5-1-6183 db: len=1172343808 primary_datavol=db
VxVM VVR vxrlink INFO V-5-1-6183 db2: len=8388608 primary_datavol=db2
VxVM VVR vxrlink INFO V-5-1-6183 dba: len=98566144 primary_datavol=dba
VxVM VVR vxrlink INFO V-5-1-6183 lg1: len=396361728 primary_datavol=lg1
VxVM VVR vxrlink INFO V-5-1-6183 tp01: len=192937984 primary_datavol=tp01
VxVM VVR vxrlink INFO V-5-1-3365 Autosync operation has started
Usage:
vradmin -g <diskgroup> -a startrep <RVGname> <secondaryhost>
Where:
<diskgroup> | is the VxVM diskgroup name |
<RVGname> | is the name for the RVG, usually <diskgroupname>_rvg |
<secondaryhost> | is the hostname of the Secondary Site. Check the /etc/hosts file. |
Check the Replication status
Initiate the command from the primary site. You can tell if it’s syncing by looking at the number of bytes remaining. If it changes, then it’s working.
sunsrv01:# vxrlink -g db2dg -i 2 status rlk_db2instdr-vipvr_db2dg_rvg
Fri Jun 22 00:01:37 MST 2007
VxVM VVR vxrlink INFO V-5-1-4464 Rlink rlk_db2instdr-vipvr_db2dg_rvg is in AUTOSYNC. 1226649984 Kbytes remaining.
VxVM VVR vxrlink INFO V-5-1-4464 Rlink rlk_db2instdr-vipvr_db2dg_rvg is in AUTOSYNC. 1226644224 Kbytes remaining.
VxVM VVR vxrlink INFO V-5-1-4464 Rlink rlk_db2instdr-vipvr_db2dg_rvg is in AUTOSYNC. 1226638464 Kbytes remaining.
VxVM VVR vxrlink INFO V-5-1-4464 Rlink rlk_db2instdr-vipvr_db2dg_rvg is in AUTOSYNC. 1226632128 Kbytes remaining.
VxVM VVR vxrlink INFO V-5-1-4464 Rlink rlk_db2instdr-vipvr_db2dg_rvg is in AUTOSYNC. 1226626368 Kbytes remaining.
Another way to check is to use the vradmin repstatus command. The key bits of information here are Data status and Replication status.
sunsrv01:# vradmin -g db2dg repstatus db2dg_rvg
Replicated Data Set: db2dg_rvg
Primary:
Host name: db2inste3-vipvr
RVG name: db2dg_rvg
DG name: db2dg
RVG state: enabled for I/O
Data volumes: 6
SRL name: db2dg_srl
SRL size: 952.84 G
Total secondaries: 1
Secondary:
Host name: db2instdr-vipvr
RVG name: db2dg_rvg
DG name: db2dg
Data status: consistent, up-to-date
Replication status: replicating (connected)
Current mode: asynchronous
Logging to: SRL
Timestamp Information: N/A
Mount the Replicated Volumes
When replication is 100% complete, you may check the volumes on the secondary site by mounting the filesystems. But first, you need to check the status of replication.
sunsrv01:# vxrlink -g db2dg -i 2 status rlk_db2instdr-vipvr_db2dg_rvgThu Jun 28 08:54:42 MST 2007
VxVM VVR vxrlink INFO V-5-1-4467 Rlink rlk_db2instdr-vipvr_db2dg_rvg is up to date
Use VCS to mount the replicated Volumes
sunsrv01-dr:# hagrp –online db2inst_grp –sys sunsrv01-dr
Display the filesystems and compare them with the primary.
sunsrv01-dr:# df -k | grep db2dg
/dev/vx/dsk/db2dg/db2 4194304 78059 3859030 2% /db2/db2inst
/dev/vx/dsk/db2dg/bcp 292552704 1527508 272836173 1% /bcp/db2inst
/dev/vx/dsk/db2dg/dba 49283072 28555 46176114 1% /dba/db2inst
/dev/vx/dsk/db2dg/db 586171904 1733538 547911037 1% /db/db2inst/PEMMP00P/NODE0000
/dev/vx/dsk/db2dg/tp01 96468992 40176 90402086 1% /db/db2inst/PEMMP00P/tempspace01/NODE0000
/dev/vx/dsk/db2dg/lg1 198180864 1779853 184126012 1% /db/db2inst/log1
sunsrv01:# df -k | grep db2dg
/dev/vx/dsk/db2dg/db2 4194304 78059 3859030 2% /db2/db2inst
/dev/vx/dsk/db2dg/bcp 292552704 1527508 272836173 1% /bcp/db2inst
/dev/vx/dsk/db2dg/dba 49283072 28555 46176114 1% /dba/db2inst
/dev/vx/dsk/db2dg/db 586171904 1733538 547911037 1% /db/db2inst/PEMMP00P/NODE0000
/dev/vx/dsk/db2dg/tp01 96468992 40176 90402086 1% /db/db2inst/PEMMP00P/tempspace01/NODE0000
/dev/vx/dsk/db2dg/lg1 198180864 1779853 184126012 1% /db/db2inst/log1
This is the best time to test VCS for switching the service group.
sunsrv01-dr:# hagrp –switch db2inst_grp –to sunsrv02-dr
Prepare the Replicated Volumes for Snapshot in the secondary site
First, display the volume information
sunsrv02-dr:# vxprint -ht bcp
Disk group: db2dg
v bcp db2dg_rvg ENABLED ACTIVE 585105408 SELECT - fsgen
pl bcp-01 bcp ENABLED ACTIVE 585108480 CONCAT - RW
sd db2dg214-01 bcp-03 db2dg214 5376 285473280 0 EMC0_219 ENA
sd db2dg215-01 bcp-03 db2dg215 5376 285473280 285473280 EMC0_220 ENA
sd db2dg219-01 bcp-03 db2dg219 5376 14161920 570946560 EMC0_224 ENA
pl bcp-02 bcp ENABLED ACTIVE LOGONLY CONCAT - RW
sd db2dg95-06 bcp-02 db2dg95 0 512 LOG EMC0_154 ENA
Prepare the volume for snapshot by adding a DCO log. The same disks is used for DCO and DCM logs.
sunsrv02-dr:# vxsnap -g db2dg prepare bcp ndcomirs=1 alloc=db2dg95
VxVM vxsnap INFO V-5-1-9270 Volume is under RVG, setting drl=no.
Display the volume information to see the changes. Note that the DCO volume has been added with two logs.
sunsrv02-dr:# vxprint -ht bcp
Disk group: db2dg
v bcp db2dg_rvg ENABLED ACTIVE 585105408 SELECT - fsgen
pl bcp-01 bcp ENABLED ACTIVE 585108480 CONCAT - RW
sd db2dg214-01 bcp-03 db2dg214 5376 285473280 0 EMC0_219 ENA
sd db2dg215-01 bcp-03 db2dg215 5376 285473280 285473280 EMC0_220 ENA
sd db2dg219-01 bcp-03 db2dg219 5376 14161920 570946560 EMC0_224 ENA
pl bcp-02 bcp ENABLED ACTIVE LOGONLY CONCAT - RW
sd db2dg95-06 bcp-02 db2dg95 0 512 LOG EMC0_154 ENA
dc bcp_dco bcp bcp_dcl
v bcp_dcl - ENABLED ACTIVE 40368 SELECT - gen
pl bcp_dcl-01 bcp_dcl ENABLED ACTIVE 40368 CONCAT - RW
sd db2dg95-07 bcp_dcl-01 db2dg95 960 40368 0 EMC0_154 ENA
Run the same steps on the rest of the volumes
sunsrv02-dr:# vxsnap -g db2dg prepare db ndcomirs=1 alloc=db2dg95
VxVM vxsnap INFO V-5-1-9270 Volume is under RVG, setting drl=no.
sunsrv02-dr:# vxsnap -g db2dg prepare dba ndcomirs=1 alloc=db2dg95
VxVM vxsnap INFO V-5-1-9270 Volume is under RVG, setting drl=no.
sunsrv02-dr:# vxsnap -g db2dg prepare db2 ndcomirs=1 alloc=db2dg95
VxVM vxsnap INFO V-5-1-9270 Volume is under RVG, setting drl=no.
sunsrv02-dr:# vxsnap -g db2dg prepare lg1 ndcomirs=1 alloc=db2dg95
VxVM vxsnap INFO V-5-1-9270 Volume is under RVG, setting drl=no.
sunsrv02-dr:# vxsnap -g db2dg prepare tp01 ndcomirs=1 alloc=db2dg95
VxVM vxsnap INFO V-5-1-9270 Volume is under RVG, setting drl=no.
Create the SNAP Volumes in the secondary site
sunsrv02-dr:# vxassist -g db2dg make bcp_snapvol 585105408 layout=concat
sunsrv02-dr:# vxassist -g db2dg make db_snapvol 1172343808 layout=concat
sunsrv02-dr:# vxassist -g db2dg make dba_snapvol 98566144 layout=concat
sunsrv02-dr:# vxassist -g db2dg make db2_snapvol 8388608 layout=concat
sunsrv02-dr:# vxassist -g db2dg make db2_snapvol 8388608 layout=concat
sunsrv02-dr:# vxassist -g db2dg make lg1_snapvol 396361728 layout=concat
sunsrv02-dr:# vxassist -g db2dg make tp01_snapvol 192937984 layout=concat
Prepare the SNAP Volumes
Identify the region size of the main volumes. The region size must be the same for both the main volume and the snap volume.
sunsrv02-dr:# for DCONAME in `vxprint -tg db2dg | grep "^dc" | awk '{ print $2 }'`
> do
> echo "$DCONAME\t\c"
> vxprint -g db2dg -F%regionsz $DCONAME
> done
bcp_dco 128
db_dco 128
dba_dco 128
db2_dco 128
lg1_dco 128
tp01_dco 128
Display the volume information
sunsrv02-dr:# vxprint -ht bcp_snapvol
Disk group: db2dg
v bcp_snapvol fsgen ENABLED 585105408 - ACTIVE - -
pl bcp_snapvol-01 bcp_snapvol ENABLED 585105600 - ACTIVE - -
sd db2dg114-01 bcp_snapvol-01 ENABLED 35726400 0 - - -
sd db2dg106-01 bcp_snapvol-01 ENABLED 35681280 35726400 - - -
sd db2dg101-01 bcp_snapvol-01 ENABLED 35681280 71407680 - - -
sd db2dg102-01 bcp_snapvol-01 ENABLED 35681280 107088960 - - -
sd db2dg103-01 bcp_snapvol-01 ENABLED 35681280 142770240 - - -
sd db2dg104-01 bcp_snapvol-01 ENABLED 35681280 178451520 - - -
sd db2dg105-01 bcp_snapvol-01 ENABLED 35681280 214132800 - - -
sd db2dg107-01 bcp_snapvol-01 ENABLED 35681280 249814080 - - -
sd db2dg108-01 bcp_snapvol-01 ENABLED 35681280 285495360 - - -
sd db2dg109-01 bcp_snapvol-01 ENABLED 13844160 321176640 - - -
sd db2dg110-01 bcp_snapvol-01 ENABLED 35726400 335020800 - - -
sd db2dg111-01 bcp_snapvol-01 ENABLED 35726400 370747200 - - -
sd db2dg112-01 bcp_snapvol-01 ENABLED 35726400 406473600 - - -
sd db2dg113-01 bcp_snapvol-01 ENABLED 35726400 442200000 - - -
sd db2dg115-01 bcp_snapvol-01 ENABLED 35726400 477926400 - - -
sd db2dg116-01 bcp_snapvol-01 ENABLED 35726400 513652800 - - -
sd db2dg117-01 bcp_snapvol-01 ENABLED 35726400 549379200 - - -
Prepare the snapshot volume by adding a DCO log and the same region size as the main volume. The same disks is used for DCO and DCM logs.
sunsrv02-dr:# vxsnap -g db2dg prepare bcp_snapvol ndcomirs=1 regionsize=128 \
alloc=db2dg95
Display the volume information to see the changes. Note that the DCO volume has been added.
sunsrv02-dr:# vxprint -ht bcp_snapvol
Disk group: db2dg
v bcp_snapvol fsgen ENABLED 585105408 - ACTIVE - -
pl bcp_snapvol-01 bcp_snapvol ENABLED 585105600 - ACTIVE - -
sd db2dg114-01 bcp_snapvol-01 ENABLED 35726400 0 - - -
sd db2dg106-01 bcp_snapvol-01 ENABLED 35681280 35726400 - - -
sd db2dg101-01 bcp_snapvol-01 ENABLED 35681280 71407680 - - -
sd db2dg102-01 bcp_snapvol-01 ENABLED 35681280 107088960 - - -
sd db2dg103-01 bcp_snapvol-01 ENABLED 35681280 142770240 - - -
sd db2dg104-01 bcp_snapvol-01 ENABLED 35681280 178451520 - - -
sd db2dg105-01 bcp_snapvol-01 ENABLED 35681280 214132800 - - -
sd db2dg107-01 bcp_snapvol-01 ENABLED 35681280 249814080 - - -
sd db2dg108-01 bcp_snapvol-01 ENABLED 35681280 285495360 - - -
sd db2dg109-01 bcp_snapvol-01 ENABLED 13844160 321176640 - - -
sd db2dg110-01 bcp_snapvol-01 ENABLED 35726400 335020800 - - -
sd db2dg111-01 bcp_snapvol-01 ENABLED 35726400 370747200 - - -
sd db2dg112-01 bcp_snapvol-01 ENABLED 35726400 406473600 - - -
sd db2dg113-01 bcp_snapvol-01 ENABLED 35726400 442200000 - - -
sd db2dg115-01 bcp_snapvol-01 ENABLED 35726400 477926400 - - -
sd db2dg116-01 bcp_snapvol-01 ENABLED 35726400 513652800 - - -
sd db2dg117-01 bcp_snapvol-01 ENABLED 35726400 549379200 - - -
dc bcp_snapvol_dco bcp_snapvol - - - - - -
v bcp_snapvol_dcl gen ENABLED 40368 - ACTIVE - -
pl bcp_snapvol_dcl-01 bcp_snapvol_dcl ENABLED 40368 - ACTIVE - -
sd db2dg95-01 bcp_snapvol_dcl-01 ENABLED 40368 0 - - -
Run the same steps on the rest of the volumes
sunsrv02-dr:# vxsnap -g db2dg prepare db_snapvol ndcomirs=1 regionsize=128 \
alloc=db2dg95
sunsrv02-dr:# vxsnap -g db2dg prepare dba_snapvol ndcomirs=1 regionsize=128 \
alloc=db2dg95
sunsrv02-dr:# vxsnap -g db2dg prepare db2_snapvol ndcomirs=1 regionsize=128 \
alloc=db2dg95
sunsrv02-dr:# vxsnap -g db2dg prepare lg1_snapvol ndcomirs=1 regionsize=128 \
alloc=db2dg95
sunsrv02-dr:# vxsnap -g db2dg prepare tp01_snapvol ndcomirs=1 regionsize=128 \
alloc=db2dg95
Verify the region sizes are the same
sunsrv02-dr:# for DCONAME in `vxprint -tg db2dg | grep "^dc" | awk '{ print $2 }'`
> do
> echo "$DCONAME\t\c"
> vxprint -g db2dg -F%regionsz $DCONAME
> done
bcp_dco 128
bcp_snapvol_dco 128
db_dco 128
db_snapvol_dco 128
dba_dco 128
dba_snapvol_dco 128
db2_dco 128
db2_snapvol_dco 128
lg1_dco 128
lg1_snapvol_dco 128
tp01_dco 128
tp01_snapvol_dco 128
Run a point-in-time snapshot
Verify the RLINK and RVG are active and up to date. Run this command from the primary site.
sunsrv01:# vxrlink -g db2dg -i 2 status rlk_db2instdr-vipvr_db2dg_rvg
Thu Jun 28 08:54:42 MST 2007
VxVM VVR vxrlink INFO V-5-1-4467 Rlink rlk_db2instdr-vipvr_db2dg_rvg is up to date
sunsrv02-dr:# vxprint -Pl
Disk group: db2dg
Rlink: rlk_db2inste3-vipvr_db2dg_rvg
info: timeout=500 packet_size=8400 rid=0.2127
latency_high_mark=10000 latency_low_mark=9950
bandwidth_limit=none
state: state=ACTIVE
synchronous=off latencyprot=off srlprot=autodcm
assoc: rvg=db2dg_rvg
remote_host=db2inste3-vipvr IP_addr=10.11.196.191 port=4145
remote_dg=db2dg
remote_dg_dgid=1138140445.1393.sunsrv01
remote_rvg_version=21
remote_rlink=rlk_db2instdr-vipvr_db2dg_rvg
remote_rlink_rid=0.2007
local_host=db2instdr-vipvr IP_addr=10.12.94.191 port=4145
protocol: UDP/IP
flags: write enabled attached consistent connected
Start the Snap Copy
sunsrv02-dr:# vxsnap -g db2dg make source=bcp/snapvol=bcp_snapvol \
source=db/snapvol=db_snapvol source=dba/snapvol=dba_snapvol \
source=db2/snapvol=db2_snapvol source=lg1/snapvol=lg1_snapvol \
source=tp01/snapvol=tp01_snapvol
Display the sync status
sunsrv02-dr:# vxtask list
TASKID PTID TYPE/STATE PCT PROGRESS
168 SNAPSYNC/R 00.07% 0/585105408/430080 SNAPSYNC bcp_snapvol db2dg
170 SNAPSYNC/R 00.05% 0/1172343808/567296 SNAPSYNC db_snapvol db2dg
172 SNAPSYNC/R 00.46% 0/98566144/452608 SNAPSYNC dba_snapvol db2dg
174 SNAPSYNC/R 04.30% 0/8388608/360448 SNAPSYNC db2_snapvol db2dg
176 SNAPSYNC/R 00.16% 0/396361728/641024 SNAPSYNC lg1_snapvol db2dg
178 SNAPSYNC/R 00.18% 0/192937984/346112 SNAPSYNC tp01_snapvol db2dg
sunsrv02-dr:# vxsnap -g db2dg print
NAME SNAPOBJECT TYPE PARENT SNAPSHOT %DIRTY %VALID
bcp -- volume -- -- -- 100.00
bcp_snapvol_snp volume -- bcp_snapvol 0.00 --
db -- volume -- -- -- 100.00
db_snapvol_snp volume -- db_snapvol 0.00 --
dba -- volume -- -- -- 100.00
dba_snapvol_snp volume -- dba_snapvol 0.00 --
db2 -- volume -- -- -- 100.00
db2_snapvol_snp volume -- db2_snapvol 0.00 --
lg1 -- volume -- -- -- 100.00
lg1_snapvol_snp volume -- lg1_snapvol 0.00 --
tp01 -- volume -- -- -- 100.00
tp01_snapvol_snp volume -- tp01_snapvol 0.00 --
bcp_snapvol bcp_snp volume bcp -- 0.00 0.11
db_snapvol db_snp volume db -- 0.00 0.02
dba_snapvol dba_snp volume dba -- 0.00 0.77
db2_snapvol db2_snp volume db2 -- 0.00 9.13
lg1_snapvol lg1_snp volume lg1 -- 0.00 0.09
tp01_snapvol tp01_snp volume tp01 -- 0.00 0.10
Mount the SNAP Volumes
When the Sync is complete, bring up the snap service group in VCS to verify all changes. But first, unmount the filesystems on replicated volumes. In this particular server, the replicated volumes and the snap volumes use the same mountpoints.
sunsrv02-dr:# umount ` mount | grep '/dev/vx/dsk/db2dg/' | awk '{ print $1 }'`
sunsrv02-dr:# vxtask list
TASKID PTID TYPE/STATE PCT PROGRESS
sunsrv02-dr:# hastatus -sum
-- SYSTEM STATE
-- System State Frozen
A sunsrv01-dr RUNNING 0
A sunsrv02-dr RUNNING 0
-- GROUP STATE
-- Group System Probed AutoDisabled State
B CCAvail sunsrv01-dr Y N ONLINE
B CCAvail sunsrv02-dr Y N OFFLINE
B db2inst_grp sunsrv01-dr Y N OFFLINE
B db2inst_grp sunsrv02-dr Y N OFFLINE
B db2inst_vvr sunsrv01-dr Y N OFFLINE
B db2inst_vvr sunsrv02-dr Y N ONLINE
B snap_db2inst_grp sunsrv01-dr Y N OFFLINE
B snap_db2inst_grp sunsrv02-dr Y N OFFLINE
sunsrv02-dr:# hagrp -online snap_db2inst_grp -sys sunsrv02-dr
sunsrv02-dr:# hastatus -sum
-- SYSTEM STATE
-- System State Frozen
A sunsrv01-dr RUNNING 0
A sunsrv02-dr RUNNING 0
-- GROUP STATE
-- Group System Probed AutoDisabled State
B CCAvail sunsrv01-dr Y N ONLINE
B CCAvail sunsrv02-dr Y N OFFLINE
B db2inst_grp sunsrv01-dr Y N OFFLINE
B db2inst_grp sunsrv02-dr Y N OFFLINE
B db2inst_vvr sunsrv01-dr Y N OFFLINE
B db2inst_vvr sunsrv02-dr Y N ONLINE
B snap_db2inst_grp sunsrv01-dr Y N OFFLINE
B snap_db2inst_grp sunsrv02-dr Y N ONLINE
Verify the filesystems and compare the sizes with the primary site.
sunsrv02-dr:# df -k | grep snapvol
/dev/vx/dsk/db2dg/db2_snapvol 4194304 78059 3859030 2% /db2/db2inst
/dev/vx/dsk/db2dg/bcp_snapvol 292552704 1527508 272836173 1% /bcp/db2inst
/dev/vx/dsk/db2dg/dba_snapvol 49283072 28555 46176114 1% /dba/db2inst
/dev/vx/dsk/db2dg/db_snapvol 586171904 1733538 547911037 1% /db/db2inst/PEMMP00P/NODE0000
/dev/vx/dsk/db2dg/tp01_snapvol 96468992 40176 90402086 1% /db/db2inst/PEMMP00P/tempspace01/NODE0000
/dev/vx/dsk/db2dg/lg1_snapvol 198180864 1779853 184126012 1% /db/db2inst/log1
sunsrv01:# df -k | grep db2dg
/dev/vx/dsk/db2dg/db2 4194304 78059 3859030 2% /db2/db2inst
/dev/vx/dsk/db2dg/bcp 292552704 1527508 272836173 1% /bcp/db2inst
/dev/vx/dsk/db2dg/dba 49283072 28555 46176114 1% /dba/db2inst
/dev/vx/dsk/db2dg/db 586171904 1733538 547911037 1% /db/db2inst/PEMMP00P/NODE0000
/dev/vx/dsk/db2dg/tp01 96468992 40176 90402086 1% /db/db2inst/PEMMP00P/tempspace01/NODE0000
/dev/vx/dsk/db2dg/lg1 198180864 1779853 184126012 1% /db/db2inst/log1