How to remove a volume with a Data Change Object (DCO) log using the vxassist option

book

Article ID: 100016218

calendar_today

Updated On:

Description

Error Message

vxvm:vxassist: ERROR: Cannot delete volume

Resolution


In some cases, there are customers that are morefamiliar using the vxassist option rather than vxedit option when removingvolumes. However, if a volume has an associated Data Change Object (DCO) log,the DCO log has to be removed first before you can totally remove the volumeusing vxassist option. Below you will find example which demonstrates thatprocedure.

EXAMPLE:

1. Below is a mirrored volume called "testvol"with DCO log
# vxprint -htg testdg
~
dgtestdg      default      default  45000    1071010400.1072.strfst1.veritas.com

dmdisk01       c1t0d0s2     sliced  2555     35538624 -
dm disk02      c1t1d0s2     sliced   2299     35536068-

v  testvol      -            ENABLED  ACTIVE  40960    SELECT    -        fsgen
pltestvol-01   testvol      ENABLED  ACTIVE  43452    CONCAT    -        RW
sddisk01-01    testvol-01   disk01  0        43452    0        c1t0d0   ENA
pl testvol-02  testvol      ENABLED  ACTIVE  43452    CONCAT    -        RW
sddisk02-01    testvol-02   disk02  0        43452    0        c1t1d0   ENA
dctestvol_dco  testvol      testvol_dcl
v  testvol_dcl  -            ENABLED  ACTIVE  132      SELECT    -        gen
pltestvol_dcl-01 testvol_dcl ENABLED ACTIVE  132      CONCAT    -        RW
sddisk01-02    testvol_dcl-01 disk0143452    132      0        c1t0d0   ENA
pl testvol_dcl-02 testvol_dcl ENABLED ACTIVE  132      CONCAT    -        RW
sddisk02-02    testvol_dcl-02 disk0243452    132      0        c1t1d0   ENA


2. Tried removing the volume "testvol" usingvxassist option, but it errors out:
# vxassist -g testdg remove volumetestvol
vxvm:vxassist: ERROR:  Cannot delete volumetestvol


3. The workaround is to remove the DCO log first, then re-runvxassist command to remove volume "testvol":
# vxassist -g testdg remove log  testvol logtype=dco
# vxprint -rhtg testdg
~
dgtestdg      default      default  45000    1071010400.1072.strfst1.veritas.com

dmdisk01       c1t0d0s2     sliced  2555     35538624 -
dm disk02      c1t1d0s2     sliced   2299     35536068-

v  testvol      -            ENABLED  ACTIVE  40960    SELECT    -        fsgen
pltestvol-01   testvol      ENABLED  ACTIVE  43452    CONCAT    -        RW
sddisk01-01    testvol-01   disk01  0        43452    0        c1t0d0   ENA
pl testvol-02  testvol      ENABLED  ACTIVE  43452    CONCAT    -        RW
sddisk02-01    testvol-02   disk02  0        43452    0        c1t1d0   ENA

# vxassist -g testdg remove volumetestvol
# vxprint -rhtg testdg
~
dgtestdg      default      default  45000    1071010400.1072.strfst1.veritas.com

dmdisk01       c1t0d0s2     sliced  2555     35538624 -
dm disk02      c1t1d0s2     sliced   2299     35536068-


 
 

 

Issue/Introduction

How to remove a volume with a Data Change Object (DCO) log using the vxassist option