Plex States

Plex States

Plexes are of three types :-
Complete Plex :- It has a complete copy of a volume. A volume must have at least one complete plex.
Sparse plex :- It maps only a part of the volume address space.
Log Plex:- It is dedicated to logging. It is used to speed up consistency checks and repairs after a system failure. RAID-5 and mirrored volumes typically uses a log plex.

A volume can have upto 32 plexes; however, you should never use more than 31 plexes in a single volume. VM requires one plex for automatic or temporary online operation.

A volume layout can be configured, reconfigured, resized and tuned online while the volume remains accessible

When you create a volume, all of the plexes and the volume are set to the EMPTY state
The object has a good copy of the data. This is a normal state for a stopped volume to be in. A volume that has been stopped by an administrator will see a state of DISABLED/CLEAN. We can use the vxvol start command to enable IO to the volume.
The ACTIVE state is the same as CLEAN, but the volume is or was currently started, and the volume is or was able to do I/O.
we are aiming for all objects to be ENABLED/ACTIVE.
The data in the plex is not synchronized with the data in a CLEAN plex.
This state is usually caused by taking the plex offline (I/O can still be going to the other plexes making them unsynchronized) or by a disk failure—which means the plex could not be updated when new writes came into the volume.
The OFFLINE state indicates that the administrator has issued the vxmend off command on the plex. The plex does not participate in any I/O when it is offline, so the contents become outdated if the volume is actively written to. When the administrator brings the plex back online using the vxmend on command, the plex changes to the STALE state.
No plexes have an accessible disk below them, or the disk below the plex has failed.
Same as NODEVICE, but the system administrator has requested that the device appear as if it has failed (for example, by using vxdiskadm option 4, “Remove a disk for replacement”).
IOFAIL is similar to NODEVICE, but indicates that an unrecoverable failure occurred on the device, and VxVM has not yet verified whether the disk is actually bad. (I/O to both the public and the private regions must fail to change the state from IOFAIL to NODEVICE.)
The RECOVER flag is set on a plex when the following two conditions are met:
• A failed disk has been fixed (by using vxreattach or vxdiskadm option 5, “Replace a failed or removed disk”).

• The plex was in the ACTIVE state prior to the failure. This flag indicates that even after fixing the volume, additional action may be required. The data may be lost and must be recovered from backup, or the administrator must verify that the data on the disk is current by using utilities provided by the application that uses that volume.
Plexes are involved in resynchronization activities.
Same as SYNC, except that the inter read thread to perform the synchronization has not been started yet.
Same as ACTIVE/CLEAN, but for a plex synchronized by the snapstart operation
After a reboot or a manual start of the volume, a plex in the SNAPDONE state is removed along with its subdisks.
A snapshot object that is currently being synchronized (STALE).but does not yet have a complete copy of the data.
The TEMP state flags (TEMP, TEMPRM, TEMPRMSD) usually indicate that the data was never a copy of the volume’s data, and these plexes should not be used. These temporary states indicate that the plex is currently involved in a synchronization operation with the volume.
A new license key is not necessary if you are upgrading from a previously licensed version of a Veritas product

If you do not have a license key, you can obtain one by completing a License Key Request Form and send it to Veritas Customer Support. You need output of
# hostid
# uname –i.

# vxlicense –c In VxVM 3.2.x and earlier to add licenses at any time enter .
Location of license keys are at /etc/vx/elm. To view the existing licenses: – # vxlicense –p. In VxVM 3.5 and onward we have vxlicinst and vxlicrep to install and report licenses. In VxVM 3.5 and later license keys are installed in /etc/vx/licenses/lic.

The default attribute settings for initializing disks are stored in the file, /etc/default/vxdisk, and those for encapsulating disks in /etc/default/vxencap.

Before removing a disk you may need to evacuate data from the disk to another disk in the disk in the disk group that has sufficient free space.
# vxevac –g datadg datadg02 datadg03 This will move data from datadg02 to datadg03.

To evacuate to any disk except for datadg03.
# vxevac –g datadg datadg02 !datadg03

To upgrade datadg from version 20 to version 40

# vxdg –T 40 upgrade datadg

To create a version 50 disk group # vxdg –T 50 init datadg datadg01=c0t3d0s2

Fig 1:

Fig 2:

Kernel Plex states / Touble sooting

Kernel Plex States
ENABLED The object can transfer both system I/O and user I/O.
DETACHED The object can transfer system I/O, but not user I/O (maintenance mode).
DISABLED No I/O can be transferred.

Kernel/Volume or Plex State Next Step

# vxdctl enable

# vxreattach

# vxrecover

For a FAILED disk

# vxdisk init

# vxdg -k adddisk

# vxrecover

# vxvol -f start



# vxrecover
DISABLED/STALE # vxrecover
DISABLED/ACTIVE # vxrecover -s
DISABLED/REMOVED # vxdg -k adddisk
DISABLED/RECOVERY Step 1 : vxmend -g <dgname> fix stale <plex-name>

Step 2: vxmend -g <dgname> fix clean <plex-name>

Step 3: vxvol -g <dgname> start  <volumename>

Step 4: fsck – /dev/vx/rdsk/<dgname>/<volumename>

Step 5: mount /dev/vx/dsk/<dgname>/<volumename>  /<mount point>

DETACHED/STALE Vxplex attach

Vxplex attach

  • Set the state of all plexes to STALE.
  • Set the state of the good plex to CLEAN.
  • Recover the volume with vxrecover -s.