Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
1
Copyright (c) 2020, Oracle. All rights reserved. Oracle Confidential.
Solaris Volume Manager (SVM): How to Mirror an Existing Soft Partition (Doc ID 1433503.1)
APPLIES TO:
Sun Solaris Volume Manager (SVM) - Version 11.9.0 to 11.10.0 [Release 11.0]
Solaris Operating System - Version 10 10/08 U6 to 10 10/08 U6 [Release 10.0]
Information in this document applies to any platform.
GOAL
Solaris Volume Manager (SVM) soft partitions can be created from RAID-1 (mirror) metadevices. This is the preferred
method as it simplifies management considerably. However, a soft partition can be created directly from a disk or LUN
slice. This article describes the method for mirroring an existing soft partition that has been created directly from a disk or
LUN slice.
SOLUTION
The practice of associating soft partitions as components of mirrors is called layering. You can layer soft partitions as part
of SVM mirror metadevices in two ways:
The first method starts with the creation of a traditional mirror metadevice based on slices. Soft partitions are then
created from the mirror. This is the recommended method. For further details, refer to Document 1417827.1 Solaris
Volume Manager (SVM): Best Practices for Creation and Implementation of Soft Partitions .
The second method is to use the soft partitions as submirrors. This approach is cumbersome, requires additional
metadevice definitions, and can complicate disk replacements. Nevertheless, the metainit command allows this
method. If you choose to mirror soft partitions this way, use the following example as a guide.
We start off with the d40 soft partition, which we want to mirror to d50.
Soft partitions cannot be used directly as submirrors. If you try to configure one as a submirror, the command will tell you
that the soft partition is invalid.
Instead, you first need to make a single metadevice out of the soft partition, followed by creation of the mirror.
Note: This approach will preserve all data on soft partition d40.
https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=82skjboz1_315&id=1433503.1 1/3
10/23/2020 Document 1433503.1
# metattach d1 d11
d1: submirror d11 is attached
#metastat
d1: Mirror
Submirror 0: d10
State: Okay
Submirror 1: d11
State: Okay
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 8388608 blocks (4.0 GB)
d10: Submirror of d1
State: Okay
Size: 8388608 blocks (4.0 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
d40 0 No Okay No
d11: Submirror of d1
State: Okay
Size: 8388608 blocks (4.0 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
d50 0 No Okay No
Before soft partitioning was introduced, metadevices were solely created from disk slices. Since disk slices need to start
and end on cylinder boundaries, a metadevice would always start and end on a cylinder boundary. Soft partitions removed
this requirement. They are defined with the smallest unit of measure on a disk, a 512-byte block. In our example above,
the start and end blocks of our soft partitions just happened to coincide with the start and end locations of the cylinder
boundaries. When this is not true, you will get an error during creation of the metadevice. For example:
There are several ways to resolve this. If data on the disk is of no concern, recreate the soft partition with a size divisible
by 512 (1 block = 512 bytes). From our above example, we should use either 3Gb or 3072Mb and proceed with the
https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=82skjboz1_315&id=1433503.1 2/3
10/23/2020 Document 1433503.1
mirroring strategy.
If data needs to be preserved, use the metattach command to add the specified number of blocks. This space is added
to the end of the soft partition. It is not necessarily contiguous with the rest of the soft partition if other soft partitions
have been defined. This is okay. (You can use growfs if desired, to expand a filesystem to take advantage of the added
space.)
You can now proceed with mirroring d20 to another similarly constructed metadevice.
https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=82skjboz1_315&id=1433503.1 3/3