×
Create a new article
Write your page title here:
We currently have 3,189 articles on s23. Type your article name above or create one of the articles listed here!



    s23
    3,189Articles

    Replacing A Meta Disk (Solaris disk suite)

    A note[edit]

    Just a quick note to say that if you are replacing a failed disk with Sol9/10 and disk suite, you should detach and clear any submirrors on the disk that are not in 'needs maintenance state', otherwise disksuite will get in a mess wrt the serial numbers on the disks at some point in the future.

    Replace A disk[edit]

    If a disk has gone down and been replaced with a new one...

    the broken disk status would like this:

    # metastat d90
     
    d90: Mirror
       Submirror 0: d91
         State: Needs maintenance 
       Submirror 1: d92
         State: Okay         
       Pass: 1
       Read option: roundrobin (default)
       Write option: parallel (default)
       Size: 430007232 blocks
     
    d91: Submirror of d90
       State: Needs maintenance 
       Invoke: metareplace d90 c3t10d0s0 <new device>
       Size: 430007232 blocks
       Stripe 0: (interlace: 2048 blocks)
           Device      Start Block  Dbase State        Hot Spare
           c3t8d0s0           0     No    Okay         
           c3t9d0s0           0     No    Okay         
           c3t10d0s0          0     No    Maintenance  
     
    d92: Submirror of d90
        State: Okay         
        Size: 430007232 blocks
        Stripe 0: (interlace: 2048 blocks)
            Device      Start Block  Dbase State        Hot Spare
            c4t8d0s0           0     No    Okay         
            c4t9d0s0           0     No    Okay         
            c4t10d0s0          0     No    Okay   
    

    You should also check the metadb placement, eg:

    # usr/sbin/metadb
           flags           first blk       block count
        a m  p  luo        16              8192            /dev/dsk/c1t0d0s7
        a    p  luo        8208            8192            /dev/dsk/c1t0d0s7
        a    p  luo        16400           8192            /dev/dsk/c1t0d0s7
        a    p  luo        16              8192            /dev/dsk/c1t1d0s7
        a    p  luo        8208            8192            /dev/dsk/c1t1d0s7
        a    p  luo        16400           8192            /dev/dsk/c1t1d0s7
    

    There should be 3 copies of the metadb on each disk ideally, the flags will be different on a failing disk (if the disk is totally failing), use 'metadb -i' to see descriptions.

    Remove metadb's on the faulty disk before removing the disk, eg.

    # metadb -d /dev/dsk/c1t1d0s7
    


    Installing the new Disk[edit]

    label the disk[edit]

    use format to label the disk

    partition the disk[edit]
    # prtvtoc /dev/rdsk/c3t10d0s2
    

    this show the current partitions

    you can copy the structure form a similar disk ie:

    # prtvtoc /dev/rdsk/c4t10d0s2 | fmthard -s - /dev/rdsk/c3t10d0s2
    

    check the new structure

    # prtvtoc /dev/rdsk/c3t10d0s2
    * /dev/rdsk/c3t10d0s2 partition map
    *
    * Dimensions:
    *     512 bytes/sector
    *     424 sectors/track
    *      24 tracks/cylinder
    *   10176 sectors/cylinder
    *   14089 cylinders
    *   14087 accessible cylinders
    *
    * Flags:
    *   1: unmountable
    *  10: read-only
    *
    *                           First     Sector    Last
    * Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
           0      0    00      10176 143339136 143349311
           2      5    01          0 143349312 143349311
           7      0    00          0     10176     10175
    

    Enable the new disk[edit]

    # metareplace -e d90 c3t10d0s0     
    d90: device c3t10d0s0 is enabled
    

    If metadb replicas already existed on the disk then replace them eg.

    # metadb -a -c 3 /dev/dsk/c1t1d0s0
    

    check the status[edit]

    the rebuild could take some time

    # metastat d90
    d90: Mirror
        Submirror 0: d91
          State: Resyncing    
        Submirror 1: d92
          State: Okay         
        Resync in progress: 0 % done
        Pass: 1
        Read option: roundrobin (default)
        Write option: parallel (default)
        Size: 430007232 blocks
    
    d91: Submirror of d90
        State: Resyncing    
        Size: 430007232 blocks
        Stripe 0: (interlace: 2048 blocks)
            Device      Start Block  Dbase State        Hot Spare
            c3t8d0s0           0     No    Okay         
            c3t9d0s0           0     No    Okay         
            c3t10d0s0          0     No    Resyncing    
    
    
    d92: Submirror of d90
        State: Okay         
        Size: 430007232 blocks
        Stripe 0: (interlace: 2048 blocks)
            Device      Start Block  Dbase State        Hot Spare
            c4t8d0s0           0     No    Okay         
            c4t9d0s0           0     No    Okay         
            c4t10d0s0          0     No    Okay
    
    Cookies help us deliver our services. By using our services, you agree to our use of cookies.
    Cookies help us deliver our services. By using our services, you agree to our use of cookies.