0% found this document useful (0 votes)
12 views4 pages

Soft Partitions

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views4 pages

Soft Partitions

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 4

Soft Partitions

As disks become larger, and disk arrays present ever larger logical devices to Solaris
systems, users need to be able to subdivide disks or logical volumes into more than eight
partitions, often to create manageable file systems or partition sizes. Solaris Volume
Manager’s soft partition feature addresses this need. Solaris Volume Manager can
support up to 8192 logical volumes per disk set (including the local, or unspecified, disk
set), but is configured for 128 (d0–d127) by
default. To increase the number of logical volumes, see “Changing Solaris Volume
Manager Defaults” on page 249.
Note – Do not increase the number of possible logical volumes far beyond the number
that you will actually use. Solaris Volume Manager creates a device node
(/dev/dsk/md/*) and associated data structures for every logical volume that is permitted
by the maximum value. These additional possible volumes can result in a substantial
performance impact.
You use soft partitions to divide a disk slice or logical volume into as many partitions as
needed. You must provide a name for each division or soft partition, just like you do for
other storage volumes, such as stripes or mirrors. A soft partition, once named, can be
accessed by applications, including file systems, as long as the soft partition is not
included in another volume. Once included in a volume, the soft partition should no
longer be directly accessed.
Soft partitions can be placed directly above a disk slice, or on top of a mirror, stripe or
RAID 5 volume. A soft partition may not be both above and below other volumes. For
example, a soft partition built on a stripe with a mirror built on the soft partition is not
allowed.
A soft partition appears to file systems and other applications to be a single contiguous
logical volume. However, the soft partition actually comprises a series of extents that
could be located at arbitrary locations on the underlying media.

Soft Partitions (Task Map)


The following task map identifies the procedures needed to manage Solaris Volume
Manager soft partitions.

Task Description Instructions


Create soft Use the Solaris Volume “How to Create a
partitions Manager GUI Soft
or the metainit command to Partition” on page
create 142
soft partitions.
Check the status Use the Solaris Volume “How to Check the
of soft Manager GUI Status
partitions or the metastat command to of a Soft Partition”
check on page
the status of soft partitions. 143
Expand soft Use the Solaris Volume “How to Expand a
partitions Manager GUI Soft
or the metattach command to Partition” on page
144
expand soft partitions.
Remove soft Use the Solaris Volume “How to Remove a
partitions Manager GUI Soft
or the metaclear command to Partition” on page
145
remove soft partitions.

Creating Soft Partitions


_ How to Create a Soft Partition

1. Check the “Configuration Guidelines for Soft Partitions” on page 138.


2. Use one of the following methods to create a soft partition:

_ From the Enhanced Storage tool within the Solaris Management Console, open the
Volumes node. Choose Action->Create Volume, then follow the instructions in the
wizard.
_ To create a soft partition, use the following form of the metainit command:
metainit [-s set] soft-partition -p [-e] component size
-s is used to specify which set is being used. If -s isn’t specified, the local (default) disk
set is used.
-e is used to specify that the entire disk should be reformatted. The format provides a
slice 0, taking most of the disk, and a slice 7 of a minimum of 4 Mbytes in size to contain
a state database replica.
soft-partition is the name of the soft partition. The name is of the form dnnn, where nnn
is a number in the range of 0 to 8192.
component is the disk, slice, or (logical) volume from which to create the soft partition.
All existing data on the component is destroyed because the soft partition headers are
written at the beginning of the component. Size is the size of the soft partition, and is
specified as a number followed by one
of the following:
_ M or m for megabytes
_ G or g for gigabytes
_ T or t for terabyte
_ B or b for blocks (sectors)
Creating a Soft Partition

# metainit d20 -p c1t3d0s2 4g


In this example, a 4 Gbyte soft partition called d20 is created on c1t3d0s2.
Steps
Example 13–1
Taking a Whole Disk for Soft Partitions
This example shows repartitioning disk c1t2d0, thus destroying any data on that disk, and
creating a new soft partition on slice 0. The command looks like the following:
metainit d7 -p -e c1t2d0 1G

Maintaining Soft Partitions


Maintaining soft partitions is no different from maintaining other logical volumes. The
following outlines the procedure.

_ How to Check the Status of a Soft Partition


1. Read the “Configuration Guidelines for Soft Partitions” on page 138.
2. Use one of the following methods to check the status of a soft partition:
_ From the Enhanced Storage tool within the Solaris Management Console, open the
Volumes node. Choose the soft partition that you want to monitor, then choose Action-
>Properties, then follow the instructions on screen. For more information, see the online
help.
_ To view the existing configuration, use the following format of the metastat command:
metastat soft-partition
soft-partition is the name of the partition you want to check. Checking the Status of a
Soft Partition
This example shows checking the status of soft partition d1, which includes two extents
and is built on the RAID 1 volume d100.
# metastat d1
d1: soft partition
component: d100
state: OKAY
size: 42674285 blocks
Extent Start Block Block Count
0 10234 40674285
1 89377263 2000000
Example 13–2
Steps
Example 13–3
Chapter 13 • Soft Partitions (Tasks)
d100: Mirror
Submirror 0: d10
State: OKAY
Read option: roundrobin (default)
Write option: parallel (default)
Size: 426742857 blocks
d10: Submirror of d100
State: OKAY
Hot spare pool: hsp002
Size: 426742857 blocks
Stripe 0: (interlace: 32 blocks)
Device Start Block Dbase State Hot Spare
c3t3d0s0 0 No Okay
_ How to Expand a Soft Partition
When no other logical volumes have been built on a soft partition, you can add space to
the soft partition. Free space is located and used to extend the partition. Existing data is
not moved.
Note – If a soft partition has been used to create another volume (for example, if it is a
component of a RAID 0 volume), the soft partition cannot be expanded. In most cases,
the same objective (providing more space for the device that contains the soft partition)
can be achieved by concatenating other volumes onto the containing device.
See “Expanding Storage Space” on page 91 for more information.
1. Read the “Configuration Guidelines for Soft Partitions” on page 138.
2. Use one of the following methods to expand a soft partition:
_ From the Enhanced Storage tool within the Solaris Management Console, open the
Volumes node. Choose the soft partition that you want to expand, then choose Action-
>Properties, then follow the instructions on screen.
_ To add space to a soft partition, use the following form of the metattach command:
metattach [-s disk-set] soft-partition size disk-set is the name of the disk set in which the
soft partition exists.
soft-partition is the name of an existing soft partition.size is the amount of space to add.

Example 13–4
Expanding a Soft Partition
This example shows how to attach space to a soft partition and then expand the file
system on it while the soft partition is online and mounted:

# mount /dev/md/dsk/d20 /home2


# metattach d20 10g
# growfs -M /home2 /dev/md/rdsk/d20

How to Remove a Soft Partition


1. Read the “Configuration Guidelines for Soft Partitions” on page 138.
2. Use one of the following methods to delete a soft partition:
_ From the Enhanced Storage tool within the Solaris Management Console, open the
Volumes node. Choose the soft partition that you want to expand, then choose Action-
>Properties, then follow the instructions on screen.
_ To delete a soft partition, use one of the following forms of the metaclear command:
metaclear [-s disk-set] component
metaclear [-s disk-set] -r soft-partition
metaclear [-s disk-set] -p component
where:
_ disk-set is the disk set in which the soft partition exists.
_ soft-partition is the soft partition to delete.
_ r specifies to recursively delete logical volumes, but not volumes on which
others depend.
_ p specifies to purge all soft partitions on the specified component, except
those soft partitions that are open.
_ component is the component from which to clear all of the soft partitions.
Removing a Soft Partition
This example shows how to delete all soft partitions on c1t4d2s0.
# metaclear -p c1t4d2s0

You might also like