This chapter describes how to change DiskSuite devices, both with the DiskSuite Tool graphical interface and with the command line utilities.
Use the following to proceed directly to the section that provides step-by-step instructions using DiskSuite Tool.
Use the following to proceed directly to the section that provides step-by-step instructions using the command line interface.
How to Change a Mirror's Options (Command Line) |
How to Share a Logging Device Among File Systems (Command Line) |
After you have created a DiskSuite object, the occasion may arise where you need to change it, modify its parameters, or reconfigure it. This section describes such tasks as:
For general information on DiskSuite, see Solstice DiskSuite 4.1 Reference.
Here are the prerequisites for the steps in this chapter:
To work with "local" metadevices (metadevices not in a diskset configuration), type:
---------------
# metatool & ---------------
To work with metadevices in a diskset, make sure you are the diskset owner and type:
---------------------------------
# metatool -s diskset_name & ---------------------------------
This section describes how to save and restore the current DiskSuite configuration that you are working on.
Use this task to save uncommitted changes that appear on the Metadevice Editor canvas. This does not save a "backup" of your configuration, only uncommitted changes.
You can also choose a file name from the Files list in the Save to File window. If the file exists, you can overwrite it, or cancel and use a different file name.
Use this task to bring back to the Metadevice Editor canvas a configuration previously saved to disk. This does not restore a configuration in the sense of restoring from a backup. Instead, it opens a previously saved configuration of uncommitted changes on the canvas.
The following dialog box appears.
You can also type a file name in the Selection text field.
This section explains how to use the Metadevice State Database Information window to view and modify state database replicas.
Drag the MetaDB Object to the canvas then double-click it. The Metadevice State Database Information window appears:
Table 4-1 lists the functionality associated with the regions of the Metadevice State Database Information window.
-------------------------------------------------------------------------------------
Field Functions -------------------------------------------------------------------------------------
Status Description of the metadevice state database's status. See "How to Check the Status of State Database Replicas (DiskSuite Tool) " for a description of these values. Replica This region shows the following information and allows for manipulation manipulation. region Replicas - The number of replicas. Scrolling List - A scrolling list of the slices that contains replicas. Includes the name of the slice, the amount of space used, space available, number of replicas on the slice and the replica status. Remove - Removes the selected slices. Restore - Restores the selected slices if they are in error. Info - Displays the Slice Information window for the selected slice. Slice - Specifies a new slice to attach to the MetaDB or replace the selected slice. Replicas - Shows the number of replicas that will be created on the slice. The default is 1. Attach - Adds the slice entered in the slice field to the Replica list. Available only when a slice name is entered. Replace - Replaces the selected slice with the slice entered in the Slice field. -------------------------------------------------------------------------------------
This section explains how to use the Mirror Information window to view and modify mirror options.
Note - If you need to change the interlace value of stripe that is used as a submirror, refer to "How to Change the Interlace Value of Stripes in Mirrors (DiskSuite Tool)."
Table 4-2 describes mirror options that can be configured.
Table 4-2 Mirror Options
Option | Functions |
---|---|
Pass Number | A pass number in the range 0-9 can be assigned to a mirror. The pass (resync) number determines the order in which that mirror is resynced during a system reboot. The default is 1. Smaller pass numbers are resynced first. If 0, the resync is skipped. A 0 should be used only for mirrors that are mounted as read-only. If different mirrors have the same pass number, they are resynced concurrently. |
Read Policy | The three read options for mirrors are roundrobin, geometric,
and first. The default is roundrobin, also called balanced load.
roundrobin: All reads are made in a round robin order from all the submirrors in the mirrors. That is, the first read comes from the first submirror, the next read comes from the second submirror, and so forth. geometric: Provides faster performance on sequential reads or when you are using disks with track buffering. Geometric reads enable read operations to be divided among submirrors on the basis of a logical disk block address. For instance, with a three-way mirror the disk space on the mirror is divided into three (equally sized) logical address ranges. Reads from the three regions are then performed by separate submirrors (for example, reads to the first region are performed by the first submirror). first: Specifies reading from only the first submirror. Use only if you have a second submirror that has poor I/O characteristics. |
Write Policy | A submirror can be set for parallel or serial writes. The default is parallel; writes are dispatched to all submirrors simultaneously. The serial option specifies that writes to one submirror must complete before the next submirror write is initiated. The serial option is provided in case a submirror becomes unreadable, for example, due to a power failure. |
You can use the Mirror Information window to set options for mirrors, including read and write policy, the order in which mirrors are resynced during reboot, and if a submirror has a hot spare.
The Mirror object appears on the canvas.
The Mirror Information window appears.
Refer to Table 4-2 for a description of mirror options. After making a change to a mirror option, click Close.
After checking the prerequisites, and the preliminary information, use the metaparam(1M) command to display and change a mirror's options. Refer to Table 4-2 for a description of mirror options. For more information, refer to the metaparam(1M) man page.
--------------------------------------
# metaparam -r geometric d30 # metaparam d30 d30: mirror current parameters are: Pass: 1 Read option: geometric (-g) Write option: parallel (default) --------------------------------------
The -r option changes a mirror's read policy to geometric.
---------------------------------------
# metaparam -w serial d40 # metaparam d40 d40: mirror current parameters are: Pass: 1 Read option: roundrobin (default) Write option: serial (-S) ---------------------------------------
The -w option changes a mirror's write policy to serial.
---------------------------------------
# metaparam -p 5 d50 # metaparam d50 d50: mirror current parameters are: Pass: 5 Read option: roundrobin (default) Write option: parallel (default) ---------------------------------------
The -p option changes a mirror's pass number to five.
This section explains how to configure trans metadevices to share logging devices.
This procedure assumes you have already set up a trans metadevice with a logging device for another file system.
If necessary, click Slices to display the Slice Browser for identifying the slice used by the file system.
An unassigned and uncommitted Trans Metadevice object appears on the canvas. The metadevice name is automatically assigned.
The objec is displayed on the canvas. The new trans metadevice will share logs with this one.
Note - If an entry exists in the /etc/vfstab file for the file system, and the file system is currently mounted, DiskSuite Tool automatically updates it to use the trans metadevice's name.
Click Really Commit on the warning dialog box that appears. This creates the new trans metadevice, sharing the logging device of the existing trans metadevice.
Upon subsequent reboots, instead of checking the file systems, fsck(1M) displays message such as this for each logged file system:
-----------------------------------
/dev/md/rdsk/trans: is logging. -----------------------------------
This procedure assumes you have already set up a trans metadevice with a log for another file system.
After checking the prerequisites, and the preliminary information, use the metainit(1M) to share a log. Refer to the metainit(1M) man page for more information.
----------------------------------------------------------------------------------------------
# umount /xyzfs # metainit d64 -t c0t2d0s4 d10 d64: Trans is setup (Edit the /etc/vfstab file so that the entry for /xyzfs references the trans metadevice d64) # mount /xyzfs # metastat ... d10: Logging device for d63 d64 ... ----------------------------------------------------------------------------------------------
This example shares a logging device (d10) defined as the log for a previous trans metadevice, with a new trans metadevice (d64). The file system to be set up as the master device is /xyzfs and is using slice /dev/dsk/c0t2d0s4. metainit -t specifies the configuration is a trans metadevice. The /etc/vfstab file must be edited to change (or enter for the first time) the entry for the file system to reference the trans metadevice. For example, the following line:
---------------------------------------------------------
/dev/dsk/c0t2d0s4 /dev/rdsk/c0t2d0s4 /xyzfs ufs 2 yes - ---------------------------------------------------------
should be changed to:
-----------------------------------------------------
/dev/md/dsk/d64 /dev/md/rdsk/d64 /xyzfs ufs 2 yes - -----------------------------------------------------
The metastat command verifies that the log is being shared. Logging becomes effective for the file system when the system is rebooted.
Upon subsequent reboots, instead of checking the file system, fsck(1M) displays these messages for the two file systems:
-------------------------------
/dev/md/rdsk/d63: is logging. /dev/md/rdsk/d64: is logging. -------------------------------