.TH mmchdisk 03/31/06 mmchdisk Command .SH "Name" .PP \fBmmchdisk\fR - Changes state or parameters of one or more disks in a GPFS file system. .SH "Synopsis" .PP \fBmmchdisk\fR \fIDevice\fR {\fBsuspend\fR | \fBresume\fR | \fBstop\fR | \fBstart\fR | \fBchange\fR} \fB-d\fR "\fIDiskDesc\fR[;\fIDiskDesc\fR...]" [\fB-N\fR {\fINode\fR[,\fINode\fR...] | \fINodeFile\fR | \fINodeClass\fR}] .PP Or, .PP \fBmmchdisk\fR \fIDevice\fR {\fBresume\fR | \fBstart\fR} \fB-a\fR [\fB-N\fR {\fINode\fR[,\fINode\fR...] | \fINodeFile\fR | \fINodeClass\fR}] .SH "Description" .PP Use the \fBmmchdisk\fR command to change the state or the parameters of one or more disks in a GPFS file system. .PP The state of a disk is a combination of its status and availability, displayed with the \fBmmlsdisk\fR command. Disk status is normally either \fBready\fR or \fBsuspended\fR. A transitional status such as \fBreplacing\fR, \fBreplacement\fR, or \fBbeing emptied\fR might also appear if a disk is being deleted or replaced. A suspended disk is one that the user has decided not to place any new data on. Existing data on a suspended disk may still be read or updated. Typically, a disk is suspended prior to restriping a file system. Suspending a disk tells the \fBmmrestripefs\fR command that data is to be migrated off that disk. Disk availability is either \fBup\fR or \fBdown\fR. .PP Be sure to use \fBstop\fR before you take a disk offline for maintenance. You should also use \fBstop\fR when a disk has become temporarily inaccessible due to a disk failure that is repairable without loss of data on that disk (for example, an adapter failure or a failure of the disk electronics). .PP The \fIDisk Usage\fR (\fBdataAndMetadata\fR, \fBdataOnly\fR, \fBmetadataOnly\fR, or \fBdescOnly\fR) and \fIFailure Group\fR parameters of a disk are adjusted with the \fBchange\fR option. See the \fIGeneral Parallel File System: Concepts, Planning, and Installation Guide\fR and search for \fIrecoverability considerations\fR. The \fBmmchdisk change\fR command does not move data or metadata that resides on the disk. After changing disk parameters, in particular, \fIDisk Usage\fR, you may have to issue the \fBmmrestripefs\fR command with the \fB-r\fR option to relocate data so that it conforms to the new disk parameters. .PP The \fBmmchdisk\fR command can be issued for a mounted or unmounted file system. When maintenance is complete or the failure has been repaired, use the \fBmmchdisk\fR command with the start option. If the failure cannot be repaired without loss of data, you can use the \fBmmdeldisk\fR command. .PP Note: The \fBmmchdisk\fR command cannot be used to change the NSD servers associated with the disk. Use the \fBmmchnsd\fR command for this purpose. Similarly, the \fBmmchdisk\fR command cannot be used to change the storage pool for the disk. Use the \fBmmdeldisk\fR and \fBmmadddisk\fR commands to move a disk from one storage pool to another. .SH "Parameters" .PP .RS +3 \fB\fIDevice\fR \fR .RE .RS +9 The device name of the file system to which the disks belong. File system names need not be fully-qualified. \fBfs0\fR is as acceptable as \fB/dev/fs0\fR. .PP This must be the first parameter. .RE .PP .RS +3 \fB-d "\fIDiskDesc\fR[;\fIDiskDesc\fR... ]" \fR .RE .RS +9 A descriptor for each disk to be changed. .PP Specify only disk names when using the \fBsuspend\fR, \fBresume\fR, \fBstop\fR, or \fBstart\fR options. Delimit multiple disk names with semicolons and enclose the list in quotation marks. For example, "gpfs1nsd;gpfs2nsd" .PP When using the \fBchange\fR option, include the disk name and any new \fIDisk Usage\fR and \fIFailure Group\fR positional parameter values in the descriptor. Delimit descriptors with semicolons and enclose the list in quotation marks, for example, "gpfs1nsd:::dataOnly;gpfs2nsd:::metadataOnly:12" .PP A disk descriptor is defined as (second, third, sixth and sevents fields reserved): .sp .nf DiskName:::DiskUsage:FailureGroup::: .fi .sp .PP .RS +3 \fB\fIDiskName\fR \fR .RE .RS +9 .PP For a list of disks that belong to a particular file system, issue the \fBmmlsnsd -f\fR, the \fBmmlsfs -d\fR, or the \fBmmlsdisk\fR command. The \fBmmlsdisk\fR command will also show the current disk usage and failure group values for each of the disks. .RE .PP .RS +3 \fB\fIDiskUsage\fR \fR .RE .RS +9 If a value is not specified, the disk usage remains unchanged: .PP .RS +3 \fBdataAndMetadata \fR .RE .RS +9 Indicates that the disk contains both data and metadata. This is the default. .RE .PP .RS +3 \fBdataOnly \fR .RE .RS +9 Indicates that the disk contains data and does not contain metadata. .RE .PP .RS +3 \fBmetadataOnly \fR .RE .RS +9 Indicates that the disk contains metadata and does not contain data. .RE .PP .RS +3 \fBdescOnly \fR .RE .RS +9 Indicates that the disk contains no data and no file metadata. Such a disk is used solely to keep a copy of the file system descriptor, and can be used as a third failure group in certain disaster recovery configurations. For more information, see \fIGeneral Parallel File System: Advanced Administration\fR and search on \fISynchronous mirroring utilizing GPFS replication\fR. .RE .RE .PP .RS +3 \fB\fIFailureGroup\fR \fR .RE .RS +9 A number identifying the failure group to which this disk belongs. You can specify any value from -1 (where -1 indicates that the disk has no point of failure in common with any other disk) to 4000. If you do not specify a failure group, the value remains unchanged. GPFS uses this information during data and metadata placement to assure that no two replicas of the same block are written in such a way as to become unavailable due to a single disk failure. All disks that are attached to the same NSD server or adapter should be placed in the same failure group. .RE .RE .PP .RS +3 \fB-a \fR .RE .RS +9 Specifies to change the state of all of the disks belonging to the file system, \fIDevice\fR. This operand is valid only on the \fBresume\fR and \fBstart\fR options. .RE .PP .RS +3 \fB-N {\fINode\fR[,\fINode\fR...] | \fINodeFile\fR | \fINodeClass\fR } \fR .RE .RS +9 Specify the nodes to participate in the restripe of the file system after the state or parameters of the disks have been changed. This command supports all defined node classes. The default is \fBall\fR (all nodes in the GPFS cluster will participate in the restripe of the file system). .PP For information on how to specify node names, see \fISpecifying nodes as input to GPFS commands\fR in \fIGPFS: Administration and Programming Reference\fR. .RE .SH "Options" .PP .RS +3 \fBchange \fR .RE .RS +9 Instructs GPFS to change the \fIDisk Usage\fR parameter, the \fIFailure Group\fR parameter, or both, according to the values specified in the \fIDisk Desc\fR. .RE .PP .RS +3 \fBresume \fR .RE .RS +9 Informs GPFS that a disk previously suspended is now available for allocating new space. If the disk is currently in a stopped state, it remains stopped until you specify the \fBstart\fR option. Otherwise, normal read and write access to the disk resumes. .RE .PP .RS +3 \fBstart \fR .RE .RS +9 Informs GPFS that disks previously stopped are now accessible. This is accomplished by first changing the disk availability from \fBdown\fR to \fBrecovering\fR. The file system metadata is then scanned and any missing updates (replicated data that was changed while the disk was \fBdown\fR) are repaired. If this operation is successful, the availability is then changed to \fBup\fR. If the metadata scan fails, availability is set to \fBunrecovered\fR. This could occur if too many other disks are \fBdown\fR. The metadata scan can be re-initiated at a later time by issuing the \fBmmchdisk start\fR command again. .PP If more than one disk in the file system is down, they must all be started at the same time by issuing the \fBmmchdisk \fIDevice\fR start -a\fR command. If you start them separately and metadata is stored on any disk that remains down, the \fBmmchdisk start\fR command fails. .RE .PP .RS +3 \fBstop \fR .RE .RS +9 Instructs GPFS to stop any attempts to access the specified disks. Use this option to tell the file system manager that a disk has failed or is currently inaccessible because of maintenance. .PP A disk remains stopped until it is explicitly started by the \fBmmchdisk\fR command with the \fBstart\fR option. Restarting the GPFS Server daemon or rebooting does not restore normal access to a stopped disk. .RE .PP .RS +3 \fBsuspend \fR .RE .RS +9 Instructs GPFS to stop allocating space on the specified disk. Place a disk in this state when you are preparing to restripe the file system off this disk because of faulty performance. This is a user-initiated state that GPFS never uses without an explicit command to change disk state. Existing data on a suspended disk may still be read or updated. .PP A disk remains suspended until it is explicitly resumed. Restarting GPFS or rebooting nodes does not restore normal access to a suspended disk. .RE .SH "Exit status" .PP .PP .RS +3 \fB0 \fR .RE .RS +9 Successful completion. .RE .PP .RS +3 \fBnonzero \fR .RE .RS +9 A failure has occurred. .RE .SH "Security" .PP You must have root authority to run the \fBmmchdisk\fR command. .PP You may issue the \fBmmchdisk\fR command from any node in the GPFS cluster. .PP When using the \fBrcp\fR and \fBrsh\fR commands for remote communication, a properly configured \fB.rhosts\fR file must exist in the root user's home directory on each node in the GPFS cluster. If you have designated the use of a different remote communication program on either the \fBmmcrcluster\fR or the \fBmmchcluster\fR command, you must ensure: .RS +3 .HP 3 1. Proper authorization is granted to all nodes in the GPFS cluster. .HP 3 2. The nodes in the GPFS cluster can communicate without the use of a password, and without any extraneous messages. .RE .SH "Examples" .RS +3 .HP 3 1. To \fBsuspend\fR active disk \fBgpfs2nsd\fR, issue this command: .sp .nf mmchdisk fs0 suspend -d gpfs2nsd .fi .sp To confirm the change, issue this command: .sp .nf mmlsdisk fs0 .fi .sp The system displays information similar to: .sp .nf disk driver sector failure holds holds status storage name type size group metadata data availability pool --------- ------- ------ ------- ------- ---- ----- --------- ------- gpfs2nsd nsd 512 2 yes yes suspended up system hd3vsdn01 nsd 512 2 yes yes ready up system hd27n01 nsd 512 8 yes yes ready up system hd28n01 nsd 512 8 yes yes ready up system hd29n01 nsd 512 8 yes yes ready up system hd10vsdn09 nsd 512 4003 no yes ready up sp1\ hd11vsdn10 nsd 512 4003 no yes ready up sp1\ .fi .sp .HP 3 2. To specify that metadata should no longer be stored on disk \fBgpfs1nsd\fR, issue this command: .sp .nf mmchdisk fs0 change -d "gpfs1nsd:::dataOnly" .fi .sp To confirm the change, issue this command: .sp .nf mmlsdisk fs0 .fi .sp The system displays information similar to: .sp .nf disk driver sector failure holds holds status storage name type size group metadata data availability pool --------- ------ ------ ------- ------ ---- ----- --------- ------- hd2vsdn01 nsd 512 2 yes yes ready up system hd3vsdn01 nsd 512 2 yes yes ready up system hd27n01 nsd 512 8 yes yes ready up system gpfs1nsd nsd 512 8 no yes ready up system hd29n01 nsd 512 8 yes yes ready up system hd10vsdn09 nsd 512 4003 no yes ready up sp1 hd11vsdn10 nsd 512 4003 no yes ready up sp1 .fi .sp .RE .SH "See also" .PP Displaying GPFS disk states .PP mmadddisk Command .PP mmchnsd Command .PP mmdeldisk Command .PP mmlsdisk Command .PP mmlsnsd Command .PP mmrpldisk Command .SH "Location" .PP \fB/usr/lpp/mmfs/bin\fR .PP