Solstice DiskSuite 4.2.1 User's Guide

How to Create a Mirror From Unused Slices (Command Line)

The high-level steps in this procedure are:

Check the prerequisites ("Prerequisites for Creating DiskSuite Objects"), and the preliminary information ("Preliminary Information for Creating Mirrors"), before beginning. Refer to the metainit(1M) and metattach(1M) man pages for more information.

Example -- Creating a Two-Way Mirror


# metainit d51 1 1 c0t0d0s2
d51: Concat/Stripe is setup
# metainit d52 1 1 c1t0d0s2
d52: Concat/Stripe is setup
# metainit d50 -m d51
d50: Mirror is setup
# metattach d50 d52
d50: Submirror d52 is attached

This example creates a two-way mirror, d50. The metainit(1M) command creates two submirrors (d51 and d52), which are actually concatenations. The metainit -m command creates the one-way mirror from the d51 concatenation. The metattach(1M) command attaches d52, creating a two-way mirror and causing a mirror resync. (Any data on the attached submirror is overwritten by the other submirror during the resync.) The system verifies that the objects are set up.

Where to Go From Here

To prepare a newly created mirror for a file system, refer to "How to Create a File System on a Metadevice (Command Line)". An application, such as a database, that uses the raw metadevice must have its own way of recognizing the metadevice.