当前位置:主页 > 行业动态 > 数据恢复 >

    单硬盘模拟各种raid的做法

    2011-01-08 09:43 作者:admin 来源:admin 浏览次数:

     

    单硬盘模拟各种raid的做法

          SunOS 5.8
          login: root
          Password:
          Last login: Fri Apr  1 17:25:16 from 192.168.1.10
          Sun Microsystems Inc.   SunOS 5.8       Generic Patch   February 2004
          # format
          Searching for disks...done

          AVAILABLE DISK SELECTIONS:
                 0. c0t0d0 <ST315320A cyl 29649 alt 2 hd 16 sec 63>  ST
                    /pci@1f,0/ide@d/dad@0,0
          Specify disk (enter its number):
          创建metadb数据库
          # metadb -afc 3 c0t0d0s7
          # bash
          创建串联
          bash-2.03# metainit d10 3 1 c0t0d0s4 1 c0t0d0s5 1 c0t0d0s6
          d10: Concat/Stripe is setup
          bash-2.03# metastat
          d10: Concat/Stripe
              Size: 5654400 blocks
              Stripe 0:
                  Device              Start Block  Dbase
                  c0t0d0s4                   0     No  
              Stripe 1:
                  Device              Start Block  Dbase
                  c0t0d0s5                   0     No  
              Stripe 2:
                  Device              Start Block  Dbase
                  c0t0d0s6                   0     No  
          bash-2.03# metadb 
                  flags           first blk       block count
               a        u         16              1034            /dev/dsk/c0t0d0s7
               a        u         1050            1034            /dev/dsk/c0t0d0s7
               a        u         2084            1034            /dev/dsk/c0t0d0s7

          bash-2.03# metaclear -a  
          d10: Concat/Stripe is cleared
          bash-2.03# metastat
          创建条带
          bash-2.03# metainit d10 1 3 c0t0d0s4 c0t0d0s5 c0t0d0s6
          d10: Concat/Stripe is setup
          bash-2.03# metastat
          d10: Concat/Stripe
              Size: 5654400 blocks
              Stripe 0: (interlace: 32 blocks)
                  Device              Start Block  Dbase
                  c0t0d0s4                   0     No  
                  c0t0d0s5                   0     No  
                  c0t0d0s6                   0     No  
          bash-2.03# metaclear -a
          d10: Concat/Stripe is cleared
          做Mirror
          bash-2.03# metainit d2 1 1 c0t0d0s4
          d2: Concat/Stripe is setup
          bash-2.03# metainit d3 1 1 c0t0d0s5
          d3: Concat/Stripe is setup
          bash-2.03# metainit d1 -m d2
          d1: Mirror is setup
          bash-2.03# metattach d1 d3
          d1: submirror d3 is attached
          bash-2.03# metastat
          d1: Mirror
              Submirror 0: d2
                State: Okay        
              Submirror 1: d3
                State: Resyncing   
              Resync in progress: 0 % done
              Pass: 1
              Read option: roundrobin (default)
              Write option: parallel (default)
              Size: 1884800 blocks
          d2: Submirror of d1
              State: Okay        
              Size: 1884800 blocks
              Stripe 0:
                  Device              Start Block  Dbase State        Hot Spare
                  c0t0d0s4                   0     No    Okay        

          d3: Submirror of d1
              State: Resyncing   
              Size: 1884800 blocks
              Stripe 0:
                  Device              Start Block  Dbase State        Hot Spare
                  c0t0d0s5                   0     No    Okay        
          bash-2.03# metadetach d1 d3
          d1: submirror d3 is detached
          bash-2.03# metaclear -a
          d1: Mirror is cleared
          d2: Concat/Stripe is cleared
          d3: Concat/Stripe is cleared
          bash-2.03# metastat
          做RAID5
          bash-2.03# metainit d10 -r c0t0d0s4 c0t0d0s5 c0t0d0s6 -i 20k
          d10: RAID is setup
          bash-2.03#
          bash-2.03# metastat
          d10: RAID
              State: Initializing
              Initialization in progress: 6% done
              Interlace: 40 blocks
              Size: 3764888 blocks
          Original device:
              Size: 3768720 blocks
                  Device              Start Block  Dbase State        Hot Spare
                  c0t0d0s4                 410     No    Initializing
                  c0t0d0s5                 410     No    Initializing
                  c0t0d0s6                 410     No    Initializing
          bash-2.03# metaclear -a
          d10: RAID is cleared
          做Concatenated Stripe
          bash-2.03# metainit d1 2 1 c0t0d0s4 -i 16k 2 c0t0d0s5 c0t0d0s6 -i 32k
          d1: Concat/Stripe is setup
          bash-2.03# metastat
          d1: Concat/Stripe
              Size: 5654400 blocks
              Stripe 0:
                  Device              Start Block  Dbase
                  c0t0d0s4                   0     No  
              Stripe 1: (interlace: 64 blocks)
                  Device              Start Block  Dbase
                  c0t0d0s5                   0     No  
                  c0t0d0s6                   0     No  

  • 上一篇:CHS模式与LBA换模式的转换
  • 下一篇:没有了
友情链接(IP>5000,PR>6):
Coach outlet bags NFL jerseys wholesale MLB jersey wholesale
联系方式 | 收费标准 | 上门服务 | 公司简介 | 汇款账户

回天时代有限公司

杭州公司: 杭州市文三路388号钱江科技大厦10楼1016室 0571-88218821

华东总部:上海市徐汇区漕溪北路41号汇嘉大厦12楼E室(太平洋一期12楼) 021-58358765

咨询热线:400-889-1122(全国),0512-66099871(苏州),021-58358765(上海),0571-88218821(杭州) 24小时热线:13524645444,案:浙ICP备06024533号