1、汇总restore和recover 辨析GuidelinetorestorerecoveraTru645整理表姓 名: 职业工种: 申请级别: 受理机构: 填报日期: A4打印 / 修订 / 内容可编辑Guideline to restore / recover a Tru64 5.1B Cluster from a disaster (data / storage are gone)(This procedure can also be used for storage migration) Reason of this documentThis document describes one
2、 of the possible procedures used to recover a Tru64 Unix cluster (actually beside VMS the only real one) form a total data loss lets say the whole storage and or data is gone.The required resources are the new storage hardware and not necessary but makes it easier, the local installation disk contai
3、ning a bootable Tru64 Unix operating system. And of course the actuall backups.PrerequesitesFor a sucessfull restore of the cluster the following backups in detail are required on a local tape cartridge.Backup made by vdump of the following filesystems / /usr /var /cluster/members/member1/boot_parti
4、tion,/cluster/members/member2/boot_partitionand of course the datas of your applications.For sure tar or dump would also work (yes Legato, Vertias or any other backup works as well, but you need to install the required client on your Inst. disk first)A list of # hwmgr -view devices to figure out the
5、 major, minor numbers of the disks attached to the functional cluster. By the way its allways a good idea to have an up to date sys_check output.A copy of the shell script cleanup_hwdb.sh on the local bootable Unix system disk.Booting the installation disk and wipping out the old HW databaseBoot you
6、r local disk (also known as the cluster inst disk in most cases an internal disk of cluster member 1) b dkx0 If you dont have anymore your installation disk, install the Unix to a new disk and skip the cleanup_hwdb part Copy or if already there execute the script cleanup_hwdb.sh (cleans up the devic
7、e dB on the local boot disk)# ./cleanup_hwdb.shThe system will be shutdown by the script.Boot genvmunix to single user mode this step will create a new HW database b dkx0 -fi genvmunix -fl s # mountroot (creates all the device files)# hwmgr -show scsiIdentify and write down the infos of the new Quor
8、um disk and the bootdisks.Moving the new disks to the disk names they had on the cluster:# dsfmgr -m dskx dsky# hwmgr -del comp -id xxWriting the default disk label to the new disks:# disklabel -wr dsk1 (boot-member1)# disklabel -wr dsk2 (boot-member2)# disklabel -wr dsk3 (cluster-root cluster-usr c
9、luster-var)# disklabel -wr dsk4 (Quorum-disk)Modifying the cluster_root, cluster_usr and cluster_var partition for your requirements (infos from an up to date sys_check output):Mount usr and var of your installation disk# mount /usr# mount /varSet the environmental variables required for vi# export
10、TERM=vt100# export EDITOR=vi# disklabel -e dsk3 (adjust the partition to your requirements)Creating the domains for cluster_root, cluster_usr and cluster_var mounting them and restoring the vdumps.If the domain directories already exists (on the installation disk they do) remove them first, or use t
11、he -f option.# mkfdmn /dev/disk/dsk3a cluster_root# mkfset cluster_root root# mkdir /cluster_root if not already exists# mount cluster_root#root /cluster_root# vrestore -xf /dev/ntape/tape0 -D /cluster_root# mkfdmn /dev/disk/dsknx cluster_usr# mkfset cluster_usr usr# mkdir /cluster_usr if not alread
12、y exists# mount cluster_usr#usr /cluster_usr# vrestore -xf /dev/ntape/tape0 -D /cluster_usr# mkfdmn /dev/disk/dsknx cluster_var# mkfset cluster_var var # mkdir /cluster_var if not already exists# mount cluster_var#var /cluster_var# vrestore -xf /dev/ntape/tape0 -D /cluster_varAdjusting the AdvFS dom
13、ain links if the device naming of the restored cluster isnt anymore as it was on the original cluster:# cd /cluster_root/etc/fdmns/cluster_root# rm *# ln -s /dev/disk/dsk3a# cd /cluster_root/etc/fdmns/cluster_usr# rm *# ln -s /dev/disk/dsk3d# cd /cluster_root/etc/fdmns/cluster_var# rm *# ln -s /dev/
14、disk/dsk3e# cd /cluster_root/etc/fdmns/root1_domain# rm *# ln -s /dev/disk/dsk1a# cd /cluster_root/etc/fdmns/root2_domain# rm *# ln -s /dev/disk/dsk2aCreating the boot_disks:We need to create the boot partition a: the swap partition b: and then CNX partition h: on the new boot disks. # clu_bdmgr -c
15、dsk1 1# clu_bdmgr -c dsk2 2Restoring and modifying member_boot_partition of member 1:# mkdir /root1# mount root1_domain#root /root1# vrestore -xf /dev/ntape/tape0 -D /root1Get the infos needed for the memberboot disk sysconfigtab: # file /dev/disk/dsk1h (member1 cnx partition) /dev/disk/dsk1h: block
16、 special (19/63) # file /dev/disk/dsk5h (quorum cnx partition) /dev/disk/dsk5h: block special (19/111) # file /dev/disk/dsk3a (cluster root partition) /dev/disk/dsk3a: block special (19/135) Modify /root1/etc/sysconfigtab: swapdevice=/dev/disk/dsk1bcluster_seqdisk_minor=63cluster_qdisk_minor=111 Res
17、toring and modifying member_boot_partition of member 2:# mkdir /root2# mount root2_domain#root /root2# vrestore -xf /dev/ntape/tape0 -D /root2Get the infos needed for the memberboot disk sysconfigtab:# file /dev/disk/dsk2h (member2 cnx partition) /dev/disk/dskxh: block special (19/64) # file /dev/di
18、sk/dsk5h (quorum cnx partition) /dev/disk/dskxh: block special (19/111)# file /dev/disk/dsk3a (cluster root partition) /dev/disk/dskxb: block special (19/35) Modify /root2/etc/sysconfigtab: swapdevice=/dev/disk/dsk2bcluster_seqdisk_minor=64cluster_qdisk_minor=111Adjusting the clu_bdmgr config file,
19、for the new cluster_root disk:# cat /root1/etc/clu_bdmgr.conf# clu_bdmgr configuration file# DO NOT EDIT THIS FILE:TYP:m:CFS:/dev/disk/dskxb:# vi /root1/etc/clu_bdmgr.conf (change dskxn to dsk3a)# vi /root2/etc/clu_bdmgr.conf (change dskxn to dsk3a) Dumping the new connection manager infos to the me
20、mber boot disks CNX partitions:# clu_bdmgr -h dsk1 /root1/etc/clu_bdmgr.conf# clu_bdmgr -h dsk2 /root2/etc/clu_bdmgr.conf Deleting the old member 1 specific hwdb on member 1 bootdisk and the restored cluster_root:# rm /root1/etc/dec*# rm /root1/etc/ddr*# rm /cluster_root/etc/dfsc*# rm /cluster_root/
21、etc/dec_unid_db*# rm /cluster_root/etc/dec_hwc_cdb*# rm /cluster_root/etc/dccd*# rm /cluster_root/etc/dcdd*# rm /cluster_root/cluster/members/member1/.Booted# rm /cluster_root/cluster/members/member1/etc/dfsl*# rm /cluster_root/cluster/members/member1/etc/cfginfo# rm /cluster_root/cluster/members/me
22、mber1/dev/tty0*# rm /cluster_root/cluster/members/member1/dev/lp*# rm /cluster_root/cluster/members/member1/dev/kevm*# rm /cluster_root/cluster/members/member1/dev/scp*# rm /cluster_root/cluster/members/member1/dev/disk# rm /cluster_root/cluster/members/member1/dev/rdisk# rm /cluster_root/cluster/me
23、mbers/member1/dev/ntape# rm /cluster_root/cluster/members/member1/dev/tape# rm -R /cluster_root/devices/disk# rm -R /cluster_root/devices/rdisk# rm -R /cluster_root/devices/tape# rm -R /cluster_root/devices/ntapeCopying the adjusted hwdb from the installation disk to the member 1 boot disk and the c
24、luster_root disk:# cp /etc/dfsc* /cluster_root/etc/# cp /etc/dec_unid_db* /cluster_root/etc/# cp /etc/dec_hwc_cdb* /cluster_root/etc/# cp /etc/dccd* /cluster_root/etc/# cp /etc/dcdd* /cluster_root/etc/# cp /etc/ddr* /root1/etc/# cp /etc/dec_devsw* /root1/etc/ # cp /etc/dec_hw_db* /root1/etc/# cp /et
25、c/dec_hwc_ldb* /root1/etc/# cp /etc/dec_scsi* /root1/etc/# cp /etc/dfsl* /cluster_root/cluster/members/member1/etc/# cp /etc/cfginfo /cluster_root/cluster/members/member1/etc/ Modifying the disklabels on the bootdisks for the swappartitions:If your decided swap size is larger than 8GB you may need t
26、o adjust partition b: of your new member boot disks Shutdown the system and boot the system from the member 1 boot disk1: Im sure you need to adjust your WWIDMGR config if you use Fiber storage: wwidmgr -quickset and so on # shutdown -h now b -fl is -fi genvmunix dkxnPress Return to boot default ker
27、nel genvmunix: genvmunix clubase:cluster_expected_votes=1 clubase:cluster_qdisk_votes=0Ignore some error messages about magic numbers and the not found swap partition# mountroot# dsfmgr -vFV (verifies and fixes HW dB files)# mount -a (Ignore error messages about the filesystems normally containing y
28、our application datas. # init 3Log into system:# clu_get_info# clu_quorumDeleting the old member 2 specific hwdb on member 2 bootdisk and the restored cluster_root:# mount root2_domain#root /mnt # rm /mnt/etc/dec* # rm /cluster/members/member2/.Booted # rm /cluster/members/member2/etc/dfsl* # rm /cl
29、uster/members/member2/etc/cfginfo # rm -rf /cluster/members/member2/dev/a-z* # cd /cluster/members/member2/dev/# ./MAKEDEV std Creating and moving the genesis database for member 2 to member boot disk Save boot1 cnx partition to a file# clu_bdmgr -d dsk1 /tmp/dsk1.bd Dump the file to cnx partition o
30、f member 2 # /usr/sbin/cluster/clu_partmgr -mg /tmp/dsk1.bd dsk2Copy the genesis database to member 2 bootdisk # mv /etc/dec_hwc_genesis* /mnt/etc/ Booting member 2 genvmunix # cd / # umount /mnt b -fl is -fi genvmunix dkxyPress Return to boot default kernel genvmunix: genvmunix clubase:cluster_expected_votes=1 clubase:cluster_qdisk_votes=0you may safely ignore messages about enumerate advfs devts# mountroot creates the local devices# dsfmgr -K # dsfmgr -vFV # hwmgr show scsi (verify the devices)# d (boot system to
copyright@ 2008-2022 冰豆网网站版权所有
经营许可证编号:鄂ICP备2022015515号-1