Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1192856
  • 博文数量: 212
  • 博客积分: 10450
  • 博客等级: 上将
  • 技术积分: 1957
  • 用 户 组: 普通用户
  • 注册时间: 2006-02-23 09:00
文章分类

全部博文(212)

文章存档

2012年(1)

2011年(16)

2010年(11)

2009年(9)

2008年(22)

2007年(36)

2006年(117)

分类: 系统运维

2011-04-25 16:06:59

一台Sun Fire V880系统盘做了镜像,第一块盘c1t0d0坏了,镜像的第二块盘c1t1d0可以启动(boot disk1)。
错误用vxvm封装的盘c1t5d0更换,并重做了镜像,但镜像状态在机器重启后又不正常,vxvm没解封装还真霸道。状态如下:
root@sunv880 # metastat
d30: Mirror
    Submirror 0: d10
      State: Needs maintenance
    Submirror 1: d20
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 35656704 blocks

d10: Submirror of d30
    State: Needs maintenance
    Invoke: metareplace d30 c1t0d0s0
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t0d0s0                   0     No    Maintenance 


d20: Submirror of d30
    State: Okay        
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s0                   0     No    Okay        


d31: Mirror
    Submirror 0: d11
      State: Needs maintenance
    Submirror 1: d21
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 16780224 blocks

d11: Submirror of d31
    State: Needs maintenance
    Invoke: metareplace d31 c1t0d0s1
    Size: 16780224 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t0d0s1                   0     No    Maintenance 


d21: Submirror of d31
    State: Okay        
    Size: 16780224 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s1                   0     No    Okay        


d32: Mirror
    Submirror 0: d12
      State: Needs maintenance
    Submirror 1: d22
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 33560448 blocks

d12: Submirror of d32
    State: Needs maintenance
    Invoke: metareplace d32 c1t0d0s3
    Size: 33560448 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t0d0s3                   0     No    Maintenance 


d22: Submirror of d32
    State: Okay        
    Size: 33560448 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s3                   0     No    Okay        


d33: Mirror
    Submirror 0: d13
      State: Needs maintenance
    Submirror 1: d23
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 20972736 blocks

d13: Submirror of d33
    State: Needs maintenance
    Invoke: metareplace d33 c1t0d0s5
    Size: 20972736 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t0d0s5                   0     No    Maintenance 


d23: Submirror of d33
    State: Okay        
    Size: 20972736 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s5                   0     No    Okay        


d34: Mirror
    Submirror 0: d14
      State: Needs maintenance
    Submirror 1: d24
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 35656704 blocks

d14: Submirror of d34
    State: Needs maintenance
    Invoke: metareplace d34 c1t0d0s7
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t0d0s7                   0     No    Maintenance 


d24: Submirror of d34
    State: Okay        
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s7                   0     No    Okay  

root@sunv880 # vxdisk list
DEVICE       TYPE      DISK         GROUP        STATUS
c1t0d0s2     sliced    -            -            error
c1t1d0s2     sliced    -            -            error
c1t2d0s2     sliced    disk03       rootdg       online
c1t3d0s2     sliced    disk01       rootdg       online
c1t4d0s2     sliced    disk02       rootdg       online
c2t1d0s2     sliced    datadg01     datadg       online
c2t1d1s2     sliced    datadg02     datadg       online failing
-            -         disk04       rootdg       failed was:c1t5d0s2


root@sunv880 # vxprint -hrt

Disk group: rootdg

DG NAME         NCONFIG      NLOG     MINORS   GROUP-ID
DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE
RV NAME         RLINK_CNT    KSTATE   STATE    PRIMARY  DATAVOLS  SRL
RL NAME         RVG          KSTATE   STATE    REM_HOST REM_DG    REM_RLNK
V  NAME         RVG          KSTATE   STATE    LENGTH   READPOL   PREFPLEX UTYPE
PL NAME         VOLUME       KSTATE   STATE    LENGTH   LAYOUT    NCOL/WID MODE
SD NAME         PLEX         DISK     DISKOFFS LENGTH   [COL/]OFF DEVICE   MODE
SV NAME         PLEX         VOLNAME  NVOLLAYR LENGTH   [COL/]OFF AM/NM    MODE
DC NAME         PARENTVOL    LOGVOL
SP NAME         SNAPVOL      DCO

dg rootdg       default      default  0        1063769027.1025.sunv880

dm disk01       c1t3d0s2     sliced   10175    143328960 -
dm disk02       c1t4d0s2     sliced   10175    143328960 -
dm disk03       c1t2d0s2     sliced   10175    143328960 -
dm disk04       -            -        -        -        NODEVICE

v  volbak       -            DISABLED ACTIVE   286656512 RAID     -        raid5
pl volbak-01    volbak       DISABLED ACTIVE   286657920 RAID     3/32     RW
sd disk03-01    volbak-01    disk03   0        143328960 0/0      c1t2d0   ENA
sd disk01-01    volbak-01    disk01   0        143328960 1/0      c1t3d0   ENA
sd disk02-01    volbak-01    disk02   0        143328960 2/0      c1t4d0   ENA
pl volbak-02    volbak       DISABLED NODEVICE 10176    CONCAT    -        RW
sd disk04-01    volbak-02    disk04   0        10176    0         -        NDEV

Disk group: datadg

DG NAME         NCONFIG      NLOG     MINORS   GROUP-ID
DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE
RV NAME         RLINK_CNT    KSTATE   STATE    PRIMARY  DATAVOLS  SRL
RL NAME         RVG          KSTATE   STATE    REM_HOST REM_DG    REM_RLNK
V  NAME         RVG          KSTATE   STATE    LENGTH   READPOL   PREFPLEX UTYPE
PL NAME         VOLUME       KSTATE   STATE    LENGTH   LAYOUT    NCOL/WID MODE
SD NAME         PLEX         DISK     DISKOFFS LENGTH   [COL/]OFF DEVICE   MODE
SV NAME         PLEX         VOLNAME  NVOLLAYR LENGTH   [COL/]OFF AM/NM    MODE
DC NAME         PARENTVOL    LOGVOL
SP NAME         SNAPVOL      DCO

dg datadg       default      default  86000    1063770777.1103.sunv880

dm datadg01     c2t1d0s2     sliced   14335    494993408 -
dm datadg02     c2t1d1s2     sliced   14335    494993408 FAILING

v  vol4         -            ENABLED  ACTIVE   482344960 SELECT   -        fsgen
pl vol4-01      vol4         ENABLED  ACTIVE   482349056 CONCAT   -        RW
sd datadg01-01  vol4-01      datadg01 14336    482349056 0        c2t1d0   ENA
pl vol4-02      vol4         ENABLED  ACTIVE   482349056 CONCAT   -        RW
sd datadg02-01  vol4-02      datadg02 0        482349056 0        c2t1d1   ENA
pl vol4-03      vol4         ENABLED  ACTIVE   LOGONLY  CONCAT    -        RW
sd datadg01-02  vol4-03      datadg01 0        1056     LOG       c2t1d0   ENA

先删除坏盘的镜像,后用新盘重建系统盘镜像:
root@sunv880 #metadb -d /dev/dsk/c1t0d0s4
root@sunv880 # metadetach -f d30 d10
d30: submirror d10 is detached
root@sunv880 # metadetach -f d31 d11
d31: submirror d11 is detached
root@sunv880 # metadetach -f d32 d12
d32: submirror d12 is detached
root@sunv880 # metadetach -f d33 d13
d33: submirror d13 is detached
root@sunv880 # metadetach -f d34 d14
d34: submirror d14 is detached

root@sunv880 # metastat
d30: Mirror
    Submirror 1: d20
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 35656704 blocks

d20: Submirror of d30
    State: Okay        
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s0                   0     No    Okay        


d31: Mirror
    Submirror 1: d21
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 16780224 blocks

d21: Submirror of d31
    State: Okay        
    Size: 16780224 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s1                   0     No    Okay        


d32: Mirror
    Submirror 1: d22
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 33560448 blocks

d22: Submirror of d32
    State: Okay        
    Size: 33560448 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s3                   0     No    Okay        


d33: Mirror
    Submirror 1: d23
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 20972736 blocks

d23: Submirror of d33
    State: Okay        
    Size: 20972736 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s5                   0     No    Okay        


d34: Mirror
    Submirror 1: d24
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 35656704 blocks

d24: Submirror of d34
    State: Okay        
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s7                   0     No    Okay        


d10: Concat/Stripe
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase
        c1t0d0s0                   0     No  

d11: Concat/Stripe
    Size: 16780224 blocks
    Stripe 0:
        Device              Start Block  Dbase
        c1t0d0s1                   0     No  

d12: Concat/Stripe
    Size: 33560448 blocks
    Stripe 0:
        Device              Start Block  Dbase
        c1t0d0s3                   0     No  

d13: Concat/Stripe
    Size: 20972736 blocks
    Stripe 0:
        Device              Start Block  Dbase
        c1t0d0s5                   0     No  

d14: Concat/Stripe
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase
        c1t0d0s7                   0     No  

root@sunv880 # metaclear d10
d10: Concat/Stripe is cleared
root@sunv880 # metaclear d11
d11: Concat/Stripe is cleared
root@sunv880 # metaclear d12
d12: Concat/Stripe is cleared
root@sunv880 # metaclear d13
d13: Concat/Stripe is cleared
root@sunv880 # metaclear d14
d14: Concat/Stripe is cleared

root@sunv880 # metastat
d30: Mirror
    Submirror 1: d20
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 35656704 blocks

d20: Submirror of d30
    State: Okay        
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s0                   0     No    Okay        


d31: Mirror
    Submirror 1: d21
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 16780224 blocks

d21: Submirror of d31
    State: Okay        
    Size: 16780224 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s1                   0     No    Okay        


d32: Mirror
    Submirror 1: d22
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 33560448 blocks

d22: Submirror of d32
    State: Okay        
    Size: 33560448 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s3                   0     No    Okay        


d33: Mirror
    Submirror 1: d23
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 20972736 blocks

d23: Submirror of d33
    State: Okay        
    Size: 20972736 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s5                   0     No    Okay        


d34: Mirror
    Submirror 1: d24
      State: Okay        
    Pass: 1
    Read option: roundrobin (default)
    Write option: parallel (default)
    Size: 35656704 blocks

d24: Submirror of d34
    State: Okay        
    Size: 35656704 blocks
    Stripe 0:
        Device              Start Block  Dbase State        Hot Spare
        c1t1d0s7                   0     No    Okay  
    
root@sunv880 # luxadm remove_device -F /dev/rdsk/c1t0d0s2         删除硬盘

 WARNING!!! Please ensure that no filesystems are mounted on these device(s).
 All data on these devices should have been backed up.


The list of devices which will be removed is:
  1: Box Name:    "FCloop" slot 0
     Node WWN:    20000000870e9bbb
     Device Type:Disk device
     Device Paths:
      /dev/rdsk/c1t0d0s2

Please verify the above list of devices and
then enter 'c' or to Continue or 'q' to Quit. [Default: c]: c
stopping:  Drive in "FCloop" slot 0....Done
offlining: Drive in "FCloop" slot 0....Done

Hit after removing the device(s).

  Drive in Box Name "FCloop" slot 0
  Logical Nodes being removed under /dev/dsk/ and /dev/rdsk:
  Logical Nodes being removed under /dev/dsk/ and /dev/rdsk:
        c1t0d0s0
        c1t0d0s1
        c1t0d0s2
        c1t0d0s3
        c1t0d0s4
        c1t0d0s5
        c1t0d0s6
        c1t0d0s7

然后把坏盘拔下,换上新盘
root@sunv880 # luxadm insert_device /dev/rdsk/c1t0d0s2

Notice: /dev/rdsk/c1t0d0s2 may already be present.

root@sunv880 # devfsadm -Cv   检测新硬件
devfsadm[635]: verbose: removing node /devices/pci@8,700000:devctl.  invalid st_rdev
devfsadm[635]: verbose: mknod /devices/pci@8,700000:devctl 0l/3l/20600
devfsadm[635]: verbose: removing node /devices/pci@8,700000:devctl.  invalid st_rdev
devfsadm[635]: verbose: mknod /devices/pci@8,700000:devctl 0l/3l/20600
devfsadm[635]: verbose: removing node /devices/pci@9,700000:devctl.  invalid st_rdev
devfsadm[635]: verbose: mknod /devices/pci@9,700000:devctl 0l/3l/20600
devfsadm[635]: verbose: removing node /devices/pci@9,700000:devctl.  invalid st_rdev
devfsadm[635]: verbose: mknod /devices/pci@9,700000:devctl 0l/3l/20600
devfsadm[635]: verbose: removing node /devices/pci@9,600000:devctl.  invalid st_rdev
devfsadm[635]: verbose: mknod /devices/pci@9,600000:devctl 0l/3l/20600
devfsadm[635]: verbose: removing node /devices/pci@9,600000:devctl.  invalid st_rdev
devfsadm[635]: verbose: mknod /devices/pci@9,600000:devctl 0l/3l/20600
devfsadm[635]: verbose: removing link /dev/syscon -> ../devices/pseudo/cn@0:systty invalid contents
devfsadm[635]: verbose: symlink /dev/syscon -> ../devices/pseudo/cn@0:syscon

#format 
    确认系统认到了新盘
root@sunv880 # prtvtoc /dev/rdsk/c1t1d0s2 |fmthard -s - /dev/rdsk/c1t0d0s2  拷贝分区表
fmthard:  New volume table of contents now in place.
root@sunv880 # metadb -afc 3 /dev/dsk/c1t0d0s4
root@sunv880 # metadb
        flags           first blk       block count
     a m  p  luo        16              1034            /dev/dsk/c1t0d0s4
     a    p  luo        1050            1034            /dev/dsk/c1t0d0s4
     a    p  luo        2084            1034            /dev/dsk/c1t0d0s4
     a    p  luo        16              1034            /dev/dsk/c1t1d0s4
     a    p  luo        1050            1034            /dev/dsk/c1t1d0s4
     a    p  luo        2084            1034            /dev/dsk/c1t1d0s4
root@sunv880 # metainit d10 1 1 /dev/dsk/c1t0d0s0
d10: Concat/Stripe is setup
root@sunv880 # metainit d11 1 1 /dev/dsk/c1t0d0s1
d11: Concat/Stripe is setup
root@sunv880 # metainit d12 1 1 /dev/dsk/c1t0d0s3
d12: Concat/Stripe is setup
root@sunv880 # metainit d13 1 1 /dev/dsk/c1t0d0s5
d13: Concat/Stripe is setup
root@sunv880 # metainit d14 1 1 /dev/dsk/c1t0d0s7
d14: Concat/Stripe is setup


root@sunv880 # metattach d30 d10
d30: submirror d10 is attached
root@sunv880 # metattach d31 d11
d31: submirror d11 is attached
root@sunv880 # metattach d32 d12
d32: submirror d12 is attached
root@sunv880 # metattach d33 d13
d33: submirror d13 is attached
root@sunv880 # metattach d34 d14
d34: submirror d14 is attached

附:后面几步也可以直接用metareplace -e dx cXtXdXsX。

#installboot /usr/platform/`uname -m`/lib/fs/ufs/bootblk /dev/rdsk/c1t0d0s0
至此,修复镜像完成。接下来修复卷,用原来错误拔插的盘恢复。vxdiskadm命令先用选项4,再用选项5。

#vxdiskadm

Volume Manager Support Operations

Menu:VolumeManager/Disk

 

 1     Add or initialize one or more disks

 2     Remove a disk

 3     Remove a disk for replacement

 4     Replace a failed or removed disk

 5     Mirror volumes on a disk

 6     Move volumes from a disk

 7     Enable access to (import) a disk group

 8     Remove access to (deport) a disk group

 9     Enable (online) a disk device

 10    Disable (offline) a disk device

 11    Mark a disk as a spare for a disk group

 12    Turn off the spare flag on a disk

 13    Remove (deport) and destroy a disk group

 14    Unrelocate subdisks back to a disk

 15    Exclude a disk from hot-relocation use

 16    Make a disk available for hot-relocation use

 17    Prevent multipathing/Suppress devices from VxVM's view

 18    Allow multipathing/Unsuppress devices from VxVM's view

 19    List currently suppressed/non-multipathed devices

 20    Change the disk naming scheme

 21    Change/Display the default disk layouts

 22    Mark a disk as allocator-reserved for a disk group

 23    Turn off the allocator-reserved flag on a disk

 list  List disk information

 

 ?     Display help about menu

 ??    Display help about the menuing system

 q     Exit from menus

Select an operation to perform: 4
Remove a disk for replacement
Menu: VolumeManager/Disk/RemoveForReplace

  Use this menu operation to remove a physical disk from a disk
  group, while retaining the disk name.  This changes the state
  for the disk name to a "removed" disk.  If there are any
  initialized disks that are not part of a disk group, you will be
  given the option of using one of these disks as a replacement.

Enter disk name [,list,q,?] list

Disk group: rootdg

DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE

dm disk01       c1t3d0s2     sliced   10175    143328960 -
dm disk02       c1t4d0s2     sliced   10175    143328960 -
dm disk03       c1t2d0s2     sliced   10175    143328960 -
dm disk04       -            -        -        -        NODEVICE

Disk group: datadg

DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE

dm datadg01     c2t1d0s2     sliced   14335    494993408 -
dm datadg02     c2t1d1s2     sliced   14335    494993408 FAILING

Enter disk name [,list,q,?] disk04


  The following volumes will lose mirrors as a result of this
  operation:

        volbak

  No data on these volumes will be lost.

  The requested operation is to remove disk disk04 from disk group
  rootdg.  The disk name will be kept, along with any volumes using
  the disk, allowing replacement of the disk.

  Select "Replace a failed or removed disk" from the main menu
  when you wish to replace the disk.

Continue with operation? [y,n,q,?] (default: y) y

  Removal of disk disk04 completed successfully.

Remove another disk? [y,n,q,?] (default: n) n
Volume Manager Support Operations
Menu: VolumeManager/Disk

 1      Add or initialize one or more disks
 2      Encapsulate one or more disks
 3      Remove a disk
 4      Remove a disk for replacement
 5      Replace a failed or removed disk
 6      Mirror volumes on a disk
 7      Move volumes from a disk
 8      Enable access to (import) a disk group
 9      Remove access to (deport) a disk group
 10     Enable (online) a disk device
 11     Disable (offline) a disk device
 12     Mark a disk as a spare for a disk group
 13     Turn off the spare flag on a disk
 14     Unrelocate subdisks back to a disk
 15     Exclude a disk from hot-relocation use
 16     Make a disk available for hot-relocation use
 17     Prevent multipathing/Suppress devices from VxVM's view
 18     Allow multipathing/Unsuppress devices from VxVM's view
 19     List currently suppressed/non-multipathed devices
 20     Change the disk naming scheme
 21     Get the newly connected/zoned disks in VxVM view
 list   List disk information

 ?      Display help about menu
 ??     Display help about the menuing system
 q      Exit from menus

Select an operation to perform: 5

Replace a failed or removed disk
Menu: VolumeManager/Disk/ReplaceDisk

  Use this menu operation to specify a replacement disk for a disk
  that you removed with the "Remove a disk for replacement" menu
  operation, or that failed during use.  You will be prompted for
  a disk name to replace and a disk device to use as a replacement.
  You can choose an uninitialized disk, in which case the disk will
  be initialized, or you can choose a disk that you have already
  initialized using the Add or initialize a disk menu operation.

Select a removed or failed disk [,list,q,?] list

Disk group: rootdg

DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE

dm disk04       -            -        -        -        REMOVED

Disk group: datadg

DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE



Select a removed or failed disk [,list,q,?] disk04

Select disk device to initialize [
,list,q,?] list

DEVICE       DISK         GROUP        STATUS
c1t0d0       -            -            error
c1t1d0       -            -            error
c1t2d0       disk03       rootdg       online
c1t3d0       disk01       rootdg       online
c1t4d0       disk02       rootdg       online
c1t5d0       -            -            error
c2t1d0       datadg01     datadg       online
c2t1d1       datadg02     datadg       online failing

Select disk device to initialize [
,list,q,?] c1t5d0

  The following disk device has a valid VTOC, but does not appear to have
  been initialized for the Volume Manager.  If there is data on the disk
  that should NOT be destroyed you should encapsulate the existing disk
  partitions as volumes instead of adding the disk as a new disk.
  Output format: [Device_Name]

  c1t5d0

Encapsulate this device? [y,n,q,?] (default: y) n

  c1t5d0

Instead of encapsulating, initialize? [y,n,q,?] (default: n) y

  The requested operation is to initialize disk device c1t5d0 and
  to then use that device to replace the removed or failed disk
  disk04 in disk group rootdg.

Continue with operation? [y,n,q,?] (default: y) y

Use a default private region length for the disk?
[y,n,q,?] (default: y) y

vxbootsetup: NOTE: Root file system is not defined on a volume.

  Replacement of disk disk04 in group rootdg with disk device
  c1t5d0 completed successfully.

Replace another disk? [y,n,q,?] (default: n) n
Volume Manager Support Operations
Menu: VolumeManager/Disk

 1      Add or initialize one or more disks
 2      Encapsulate one or more disks
 3      Remove a disk
 4      Remove a disk for replacement
 5      Replace a failed or removed disk
 6      Mirror volumes on a disk
 7      Move volumes from a disk
 8      Enable access to (import) a disk group
 9      Remove access to (deport) a disk group
 10     Enable (online) a disk device
 11     Disable (offline) a disk device
 12     Mark a disk as a spare for a disk group
 13     Turn off the spare flag on a disk
 14     Unrelocate subdisks back to a disk
 15     Exclude a disk from hot-relocation use
 16     Make a disk available for hot-relocation use
 17     Prevent multipathing/Suppress devices from VxVM's view


Hit RETURN to continue.


 18     Allow multipathing/Unsuppress devices from VxVM's view
 19     List currently suppressed/non-multipathed devices
 20     Change the disk naming scheme
 21     Get the newly connected/zoned disks in VxVM view
 list   List disk information


 ?      Display help about menu
 ??     Display help about the menuing system
 q      Exit from menus

Select an operation to perform: q

Goodbye.
root@sunv880 # vxdisk list
DEVICE       TYPE      DISK         GROUP        STATUS
c1t0d0s2     sliced    -            -            error
c1t1d0s2     sliced    -            -            error
c1t2d0s2     sliced    disk03       rootdg       online
c1t3d0s2     sliced    disk01       rootdg       online
c1t4d0s2     sliced    disk02       rootdg       online
c1t5d0s2     sliced    disk04       rootdg       online
c2t1d0s2     sliced    datadg01     datadg       online
c2t1d1s2     sliced    datadg02     datadg       online failing

root@sunv880 # vxprint -hrt
Disk group: rootdg

DG NAME         NCONFIG      NLOG     MINORS   GROUP-ID
DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE
RV NAME         RLINK_CNT    KSTATE   STATE    PRIMARY  DATAVOLS  SRL
RL NAME         RVG          KSTATE   STATE    REM_HOST REM_DG    REM_RLNK
V  NAME         RVG          KSTATE   STATE    LENGTH   READPOL   PREFPLEX UTYPE
PL NAME         VOLUME       KSTATE   STATE    LENGTH   LAYOUT    NCOL/WID MODE
SD NAME         PLEX         DISK     DISKOFFS LENGTH   [COL/]OFF DEVICE   MODE
SV NAME         PLEX         VOLNAME  NVOLLAYR LENGTH   [COL/]OFF AM/NM    MODE
DC NAME         PARENTVOL    LOGVOL
SP NAME         SNAPVOL      DCO

dg rootdg       default      default  0        1063769027.1025.sunv880
dm disk01       c1t3d0s2     sliced   10175    143328960 -
dm disk02       c1t4d0s2     sliced   10175    143328960 -
dm disk03       c1t2d0s2     sliced   10175    143328960 -
dm disk04       c1t5d0s2     sliced   10175    143328960 -

v  volbak       -            ENABLED  ACTIVE   286656512 RAID     -        raid5
pl volbak-01    volbak       ENABLED  ACTIVE   286657920 RAID     3/32     RW
sd disk03-01    volbak-01    disk03   0        143328960 0/0      c1t2d0   ENA
sd disk01-01    volbak-01    disk01   0        143328960 1/0      c1t3d0   ENA
sd disk02-01    volbak-01    disk02   0        143328960 2/0      c1t4d0   ENA
pl volbak-02    volbak       ENABLED  LOG      10176    CONCAT    -        RW
sd disk04-01    volbak-02    disk04   0        10176    0         c1t5d0   ENA

Disk group: datadg

DG NAME         NCONFIG      NLOG     MINORS   GROUP-ID
DM NAME         DEVICE       TYPE     PRIVLEN  PUBLEN   STATE
RV NAME         RLINK_CNT    KSTATE   STATE    PRIMARY  DATAVOLS  SRL
RL NAME         RVG          KSTATE   STATE    REM_HOST REM_DG    REM_RLNK
V  NAME         RVG          KSTATE   STATE    LENGTH   READPOL   PREFPLEX UTYPE
PL NAME         VOLUME       KSTATE   STATE    LENGTH   LAYOUT    NCOL/WID MODE
SD NAME         PLEX         DISK     DISKOFFS LENGTH   [COL/]OFF DEVICE   MODE
SV NAME         PLEX         VOLNAME  NVOLLAYR LENGTH   [COL/]OFF AM/NM    MODE
DC NAME         PARENTVOL    LOGVOL
SP NAME         SNAPVOL      DCO

dg datadg       default      default  86000    1063770777.1103.sunv880

dm datadg01     c2t1d0s2     sliced   14335    494993408 -
dm datadg02     c2t1d1s2     sliced   14335    494993408 FAILING

v  vol4         -            ENABLED  ACTIVE   482344960 SELECT   -        fsgen
pl vol4-01      vol4         ENABLED  ACTIVE   482349056 CONCAT   -        RW
sd datadg01-01  vol4-01      datadg01 14336    482349056 0        c2t1d0   ENA
pl vol4-02      vol4         ENABLED  ACTIVE   482349056 CONCAT   -        RW
sd datadg02-01  vol4-02      datadg02 0        482349056 0        c2t1d1   ENA
pl vol4-03      vol4         ENABLED  ACTIVE   LOGONLY  CONCAT    -        RW
sd datadg01-02  vol4-03      datadg01 0        1056     LOG       c2t1d0   ENA

vxdisklist输出的c2t1d1s2有failing警告,failing警告并不一定是绝对的错误,用以下命令去除:
# vxedit -g datadg set failing=off datadg02
root@sunv880 # vxdisk list
DEVICE       TYPE      DISK         GROUP        STATUS
c1t0d0s2     sliced    -            -            error
c1t1d0s2     sliced    -            -            error
c1t2d0s2     sliced    disk03       rootdg       online
c1t3d0s2     sliced    disk01       rootdg       online
c1t4d0s2     sliced    disk02       rootdg       online
c1t5d0s2     sliced    disk04       rootdg       online
c2t1d0s2     sliced    datadg01     datadg       online
c2t1d1s2     sliced    datadg02     datadg       online
阅读(2580) | 评论(0) | 转发(1) |
给主人留下些什么吧!~~