Sun Microsystems Logo
Products and Services
 
Support and Training
 
 

Previous Previous     Contents     Index     Next Next

Changing Solaris Volume Manager Defaults

The Solaris Volume Manager configuration has the following default values:

  • 128 volumes per disk set

  • 4 disk sets

  • State database replica maximum size of 8192 blocks

The values of total volumes and number of disk sets can be changed if necessary, and the tasks in this section tell you how.

ProcedureHow to Increase the Number of Default Volumes

This task describes how to increase the number of volumes from the default value of 128. If you need to configure more than the default, you can increase this value up to 8192.


Caution! Caution - If you lower this number at any point, any volume existing between the old number and the new number might not be available, potentially resulting in data loss. If you see a message such as "md: d200: not configurable, check /kernel/drv/md.conf" you must edit the md.conf file and increase the value, as explained in this task.


  1. Check the prerequisites (Prerequisites for Troubleshooting the System).

  2. Edit the /kernel/drv/md.conf file.

  3. Change the value of the nmd field. Values up to 8192 are supported.

  4. Save your changes.

  5. Perform a reconfiguration reboot to build the volume names.

    # boot -r

Example--md.conf File

Here is a sample md.conf file that is configured for 256 volumes.

#
#ident "@(#)md.conf   1.7     94/04/04 SMI"
#
# Copyright (c) 1992, 1993, 1994 by Sun Microsystems, Inc.
#
#
#pragma ident   "@(#)md.conf    2.1     00/07/07 SMI"
#
# Copyright (c) 1992-1999 by Sun Microsystems, Inc.
# All rights reserved.
#
name="md" parent="pseudo" nmd=256 md_nsets=4;

How to Increase the Number of Default Disk Sets

This task shows you how to increase the number of disk sets from the default value of 4.


Caution! Caution - Do not decrease the number of default disk sets if you have already configured disk sets. Lowering this number could make existing disk sets unavailable or unusable.


  1. Check the prerequisites (Prerequisites for Troubleshooting the System).

  2. Edit the /kernel/drv/md.conf file.

  3. Change the value of the md_nsets field. Values up to 32 are supported.

  4. Save your changes.

  5. Perform a reconfiguration reboot to build the volume names.

    # boot -r

Example--md.conf File

Here is a sample md.conf file that is configured for five shared disk sets. The value of md_nsets is six, which results in five shared disk sets and the one local disk set.

#
#
#pragma ident   "@(#)md.conf    2.1     00/07/07 SMI"
#
# Copyright (c) 1992-1999 by Sun Microsystems, Inc.
# All rights reserved.
#
name="md" parent="pseudo" nmd=128 md_nsets=6;
# Begin MDD database info (do not edit)
...
# End MDD database info (do not edit)

Growing a File System

After a volume that contains a file system is expanded (more space is added), if that volume contains a UFS, you also need to "grow" the file system to recognize the added space. You must manually grow the file system with the growfs command. The growfs command expands the file system, even while mounted. However, write access to the file system is not possible while the growfs command is running.

An application, such as a database, that uses the raw device must have its own method to grow added space. Solaris Volume Manager does not provide this capability.

The growfs command will "write-lock" a mounted file system as it expands the file system. The length of time the file system is write-locked can be shortened by expanding the file system in stages. For instance, to expand a 1 Gbyte file system to 2 Gbytes, the file system can be grown in 16 Mbyte stages using the -s option to specify the total size of the new file system at each stage.

During the expansion, the file system is not available for write access because of write-lock. Write accesses are transparently suspended and are restarted when the growfs command unlocks the file system. Read accesses are not affected, though access times are not kept while the lock is in effect.

Background Information for Expanding Slices and Volumes


Note - Solaris Volume Manager volumes can be expanded, but not shrunk.


  • A volume, regardless if it is used for a file system, application, or database, can be expanded. So, you can expand RAID 0 (stripe and concatenation) volumes, RAID 1 (mirror) volumes, and RAID 5 volumes as well as soft partitions.

  • You can concatenate a volume that contains an existing file system while the file system is in use. Then, as long as the file system is UFS, it can be expanded (with the growfs command) to fill the larger space without interrupting read access to the data.

  • Once a file system is expanded, it cannot be shrunk, due to constraints in UFS.

  • Applications and databases that use the raw device must have their own method to "grow" the added space so that they can recognize it. Solaris Volume Manager does not provide this capability.

  • When a component is added to a RAID 5 volume, it becomes a concatenation to the device. The new component does not contain parity information. However, data on the new component is protected by the overall parity calculation that takes place for the volume.

  • You can expand a log device by adding additional components. You do not need to run the growfs command, as Solaris Volume Manager automatically recognizes the additional space on reboot.

  • Soft partitions can be expanded by adding space from the underlying volume or slice. All other volumes can be expanded by adding slices.

Previous Previous     Contents     Index     Next Next