Before renaming a metadevice, make sure that it is not currently in use. For a file system, make sure it is not mounted or being used as swap. Other applications using the raw device, such as a database, should have their own way of stopping access to the data.
You can rename any metadevice except a metadevice that is being used as a logging device. To perform the equivalent of renaming a metadevice used as a logging device, detach the logging device then reattach a new logging device of the desired name. Or detach the logging device, rename it, then reattach it to the trans metadevice.
You cannot rename a trans metadevice while it has an attached logging device. To rename a trans metadevice, first detach the logging device.
Hot spare pools cannot be renamed once they are created.
Metadevices within a diskset can be renamed. You cannot rename metadevices from one diskset to another.
The metarename command with the -x option can "switch" metadevices that have a parent-child relationship. Refer to "Metadevice Name Switching".
You cannot rename a metadevice that is mounted or open. You cannot rename a trans metadevice that has a logging device attached.
Make sure you have met the prerequisites ("Prerequisites for Maintaining DiskSuite Objects"), and have read the preliminary information ("Preliminary Information for Renaming Metadevices").
Stop all access to the metadevice.
For example, if the metadevice contains a mounted file system, unmount it.
Display the metadevice's Info window.
Type the new metadevice name in the Device Name field then click Attach.
If you do not see the Device Name field on the Info window, then the metadevice is still in use. Make sure you have stopped access to the metadevice.
Click Close to close the Info window.
The metadevice object displays the new metadevice name.
If the metadevice is used for a file system with an entry in the /etc/vfstab file, DiskSuite Tool changes the entry to reference the new metadevice name.
Resume access to the metadevice.
For example, mount the file system.
To verify that the rename was committed, display the Configuration Log.
After checking the prerequisites ("Prerequisites for Maintaining DiskSuite Objects"), and the preliminary information ("Preliminary Information for Renaming Metadevices"), use the metarename(1M) command to rename a metadevice. Refer to the metarename(1M) man page for more information.
# umount /home # metarename d10 d100 d10: has been renamed to d100 (Edit the /etc/vfstab file so that the file system references the new metadevice) # mount /home
The metadevice d10 is renamed to metadevice d100. Because d10 contains a mounted file system, the file system must be unmounted before the rename. If the metadevice is used for a file system with an entry in the /etc/vfstab file, the entry must be changed to reference the new metadevice name. For example, the following line:
/dev/md/dsk/d10 /dev/md/rdsk/d10 /docs ufs 2 yes -
should be changed to:
/dev/md/dsk/d100 /dev/md/rdsk/d100 /docs ufs 2 yes -