您好,欢迎访问三七文档
当前位置:首页 > 商业/管理/HR > 信息化管理 > 使用卷管理工具对sun v250做镜像冗余
云南远程v250做raid1镜像一、内容介绍V250单机对系统盘和数据盘做镜像冗余,原来做了有四张盘,0号为系统盘,145为数据盘,并做了条带为/dev/md/dsk/d20,要添加四块盘,一块做系统盘镜像,另外三块做卷d20的镜像d30。8盘磁盘名称:AVAILABLEDISKSELECTIONS:0.c0t0d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@0,01.c0t1d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@1,02.c0t2d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@2,03.c0t3d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@3,04.c0t8d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@8,05.c0t9d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@9,06.c0t10d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@a,07.c0t11d0SUN72Gcyl14087alt2hd24sec424/pci@1d,700000/scsi@4/sd@b,0卷d20d20:Submirrorofd2State:OkaySize:425835072blocks(203GB)Stripe0:(interlace:32blocks)DeviceStartBlockDbaseStateRelocHotSparec0t1d0s60NoOkayYesc0t8d0s60NoOkayYesc0t9d0s60NoOkayYes#metadbflagsfirstblkblockcountampluo168192/dev/dsk/c0t1d0s7apluo82088192/dev/dsk/c0t1d0s7apluo164008192/dev/dsk/c0t1d0s7apluo168192/dev/dsk/c0t8d0s7apluo82088192/dev/dsk/c0t8d0s7apluo164008192/dev/dsk/c0t8d0s7apluo168192/dev/dsk/c0t9d0s7apluo82088192/dev/dsk/c0t9d0s7apluo164008192/dev/dsk/c0t9d0s7二、备份分区表cp/etc/vfstab/etc/vfstab.bak三、将系统盘分区信息复制到2号盘,将1号盘分区信息复制到367号盘,,做metadb#prtvtoc/dev/rdsk/c0t0d0s2|fmthard-s-/dev/rdsk/c0t2d0s2#prtvtoc/dev/rdsk/c0t1d0s2|fmthard-s-/dev/rdsk/c0t3d0s2#prtvtoc/dev/rdsk/c0t1d0s2|fmthard-s-/dev/rdsk/c0t10d0s2#prtvtoc/dev/rdsk/c0t1d0s2|fmthard-s-/dev/rdsk/c0t11d0s2#metadb–a–f–c3c0t3d0s7c0t10d0s7c0t11d0s7四、对数据盘做镜像,并做子镜像卷#metainit-fd2–md20d2:Mirrorissetup#metainit-fd3013c0t3d0s7c0t10d0s7c0t11d0s7d30:Concat/Stripeissetup#metattachd2d30#metastatd2:MirrorSubmirror0:d20State:0%Submirror1:d30State:NeedsmaintenancePass:1Readoption:roundrobin(default)Writeoption:parallel(default)Size:425835072blocks(203GB)d20:Submirrorofd2State:okaySize:425835072blocks(203GB)Stripe0:(interlace:32blocks)DeviceStartBlockDbaseStateRelocHotSparec0t1d0s60NoOkayYesc0t8d0s60NoOkayYesc0t9d0s60NoOkayYesd30:Submirrorofd2State:NeedsmaintenanceInvoke:metasyncd2Size:425835072blocks(203GB)Stripe0:(interlace:32blocks)DeviceStartBlockDbaseStateRelocHotSparec0t3d0s60NoOkayYesc0t10d0s60NoOkayYesc0t11d0s60NoOkayYes五、对系统盘做镜像#metainit-fd4011c0t2d0s0Concat/Stripeissetup#metainit-fd4111c0t2d0s1Concat/Stripeissetup#metainit-fd4711c0t2d0s7Concat/Stripeissetup#metainit-fd5011c0t2d0s0Concat/Stripeissetup#metainit-fd5111c0t2d0s1Concat/Stripeissetup#metainit-fd5711c0t2d0s7Concat/Stripeissetup#Metainit–fd0–md40#Metainit–fd1–md41#Metainit–fd7–md47#metarootd0#vi/etc/vfstab改为...…/dev/md/dsk/d1--swap-no-/dev/md/dsk/d0/dev/md/rdsk/d0/ufs1no-/dev/md/dsk/d7/dev/md/rdsk/d7/usrufs1no-/dev/md/dsk/d2/dev/md/rdsk/d2/oracleufs-yes-……#lockfs–fa#Init6六、追加子镜像#metattachd0d50#metattachd1d51#metattachd7d57生成可自动切换的能启动镜像磁盘installboot/usr/platform/'uname-i'/lib/fs/ufs/bootblk/dev/rdsk/c1t4d0s0等待镜像同步完成查看状态#metastatd7:MirrorSubmirror0:d47State:OkaySubmirror1:d57State:OkayPass:1Readoption:roundrobin(default)Writeoption:parallel(default)Size:20484288blocks(9.8GB)d47:Submirrorofd7State:OkaySize:20484288blocks(9.8GB)Stripe0:DeviceStartBlockDbaseStateRelocHotSparec0t0d0s70NoOkayYesd57:Submirrorofd7State:OkaySize:20484288blocks(9.8GB)Stripe0:DeviceStartBlockDbaseStateRelocHotSparec0t2d0s70NoOkayYesd1:MirrorSubmirror0:d41State:OkaySubmirror1:d51State:OkayPass:1Readoption:roundrobin(default)Writeoption:parallel(default)Size:12292608blocks(5.9GB)d41:Submirrorofd1State:OkaySize:12292608blocks(5.9GB)Stripe0:DeviceStartBlockDbaseStateRelocHotSparec0t0d0s10NoOkayYesd51:Submirrorofd1State:OkaySize:12292608blocks(5.9GB)Stripe0:DeviceStartBlockDbaseStateRelocHotSparec0t2d0s10NoOkayYesd0:MirrorSubmirror0:d40State:OkaySubmirror1:d50State:OkayPass:1Readoption:roundrobin(default)Writeoption:parallel(default)Size:110572416blocks(52GB)d40:Submirrorofd0State:OkaySize:110572416blocks(52GB)Stripe0:DeviceStartBlockDbaseStateRelocHotSparec0t0d0s00NoOkayYesd50:Submirrorofd0State:OkaySize:110572416blocks(52GB)Stripe0:DeviceStartBlockDbaseStateRelocHotSparec0t2d0s00NoOkayYesd2:MirrorSubmirror0:d20State:OkaySubmirror1:d30State:OkayPass:1Readoption:roundrobin(default)Writeoption:parallel(default)Size:425835072blocks(203GB)d20:Submirrorofd2State:OkaySize:425835072blocks(203GB)Stripe0:(interlace:32blocks)DeviceStartBlockDbaseStateRelocHotSparec0t1d0s60NoOkayYesc0t8d0s60NoOkayYesc0t9d0s60NoOkayYesd30:Submirrorofd2State:OkaySize:425835072blocks(203GB)Stripe0:(interlace:32blocks)DeviceStartBlockDbaseStateRelocHotSparec0t3d0s60NoOkayYesc0t10d0s60NoOkayYesc0t11d0s60NoOkayYes六、对更换磁盘做维护假如c0t0d0坏掉,停机,取出坏磁盘。在ok下用镜像的盘启动到单用户模式下:bootdisk2–s*2号盘为系统镜像盘系统启动后插入新磁盘(format格式化)执行:metadb-dc0t0d0s7*删除metadbprtvtoc/dev/rdsk/c0t2d0s2|fmthard-s-/dev/rdsk/c0t0d0s2*给新盘创建和镜像盘一样的分区表。init0bootdisk2*镜像启动系统metareplace-ed0c0t0d0s0metareplace-ed1c0t0d0s1metareplace-ed1c0t0d0s7*恢复swap镜像注意:如果主盘swap同步有问题,就先metaoffline-fd1d41再metadetachd1d41接着重试metattachd1d41,就可以同步了查看镜像恢复进度metastat-t恢复后bootdisk
本文标题:使用卷管理工具对sun v250做镜像冗余
链接地址:https://www.777doc.com/doc-676536 .html