1. Introduction to Administering Oracle Solaris Cluster
2. Oracle Solaris Cluster and RBAC
3. Shutting Down and Booting a Cluster
4. Data Replication Approaches
5. Administering Global Devices, Disk-Path Monitoring, and Cluster File Systems
7. Administering Cluster Interconnects and Public Networks
10. Configuring Control of CPU Usage
11. Patching Oracle Solaris Cluster Software and Firmware
12. Backing Up and Restoring a Cluster
How to Find File System Names to Back Up
How to Determine the Number of Tapes Needed for a Full Backup
How to Back Up the Root (/) File System
How to Perform Online Backups for Mirrors (Solaris Volume Manager)
How to Perform Online Backups for Volumes (Veritas Volume Manager)
How to Back Up the Cluster Configuration
How to Restore Individual Files Interactively (Solaris Volume Manager)
How to Restore the Root (/) File System (Solaris Volume Manager)
How to Restore a Root (/) File System That Was on a Solaris Volume Manager Volume
How to Restore a Nonencapsulated Root (/) File System (Veritas Volume Manager)
How to Restore an Encapsulated Root (/) File System (Veritas Volume Manager)
13. Administering Oracle Solaris Cluster With the Graphical User Interfaces
The ufsrestore(1M) command copies files to disk, relative to the current working directory, from backups created by using the ufsdump(1M) command. You can use ufsrestore to reload an entire file system hierarchy from a level 0 dump and incremental dumps that follow it, or to restore one or more single files from any dump tape. If ufsrestore is run as superuser or assumed an equivalent role, files are restored with their original owner, last modification time, and mode (permissions).
Before you start to restore files or file systems, you need to know the following information.
Which tapes you need
The raw device name on which you are restoring the file system
The type of tape drive you are using
The device name (local or remote) for the tape drive
The partition scheme of any failed disk, because the partitions and file systems must be exactly duplicated on the replacement disk
Table 12-2 Task Map: Restoring Cluster Files
|
Use this procedure to restore one or more individual files. Ensure that the cluster is running without errors before performing the restore procedure.
# clresourcegroup offline resource-group
# ufsrestore
Use this procedure to restore the root (/) file systems to a new disk, such as after replacing a bad root disk. The node being restored should not be booted. Ensure that the cluster is running without errors before performing the restore procedure.
Note - Because you must partition the new disk by using the same format as the failed disk, identify the partitioning scheme before you begin this procedure, and recreate file systems as appropriate.
The phys-schost# prompt reflects a global-cluster prompt. Perform this procedure on a global cluster.
This procedure provides the long forms of the Oracle Solaris Cluster commands. Most commands also have short forms. Except for the long and short forms of the command names, the commands are identical.
Use a node other than the node that you are restoring.
Run this command from a node in the metaset other than the node that you are removing. Because the recovering node is offline, the system will display an RPC: Rpcbind failure - RPC: Timed out error. Ignore this error and continue to the next step.
# metaset -s setname -f -d -h nodelist
Specifies the disk set name.
Deletes the last host from the disk set.
Deletes from the disk set.
Specifies the name of the node to delete from the disk set.
To restore the root and /usr file systems, follow the procedure in Chapter 26, Restoring UFS Files and File Systems (Tasks), in System Administration Guide: Devices and File Systems. Omit the step in the Oracle Solaris OS procedure to reboot the system.
Note - Ensure that you create the /global/.devices/node@nodeid file system.
# reboot
# cldevice repair rootdisk
# metadb -c copies -af raw-disk-device
Specifies the number of replicas to create.
Raw disk device on which to create replicas.
Adds replicas.
phys-schost-2# metaset -s setname -a -h nodelist
Creates and adds the host to the disk set.
The node is rebooted into cluster mode. The cluster is ready to use.
Example 12-6 Restoring the Root (/) File System (Solaris Volume Manager)
The following example shows the root (/) file system restored to the node phys-schost-1 from the tape device /dev/rmt/0. The metaset command is run from another node in the cluster, phys-schost-2, to remove and later add back node phys-schost-1 to the disk set schost-1. All other commands are run from phys-schost-1 . A new boot block is created on /dev/rdsk/c0t0d0s0, and three state database replicas are recreated on /dev/rdsk/c0t0d0s4 .
[Become superuser or assume a role that provides solaris.cluster.modify RBAC authorization on a cluster node other than the node to be restored.] [Remove the node from the metaset:] phys-schost-2# metaset -s schost-1 -f -d -h phys-schost-1 [Replace the failed disk and boot the node:] Restore the root (/) and /usr file system using the procedure in the Solaris system administration documentation [Reboot:] # reboot [Replace the disk ID:] # cldevice repair /dev/dsk/c0t0d0 [Re-create state database replicas:] # metadb -c 3 -af /dev/rdsk/c0t0d0s4 [Add the node back to the metaset:] phys-schost-2# metaset -s schost-1 -a -h phys-schost-1
Use this procedure to restore a root (/) file system that was on a Solaris Volume Manager volume when the backups were performed. Perform this procedure under circumstances such as when a root disk is corrupted and replaced with a new disk. The node being restored should not be booted. Ensure that the cluster is running without errors before performing the restore procedure.
Note - Because you must partition the new disk by using the same format as the failed disk, identify the partitioning scheme before you begin this procedure, and recreate file systems as appropriate.
The phys-schost# prompt reflects a global-cluster prompt. Perform this procedure on a global cluster.
This procedure provides the long forms of the Oracle Solaris Cluster commands. Most commands also have short forms. Except for the long and short forms of the command names, the commands are identical.
Use a node other than the node that you are restoring.
# metaset -s setname -d -h hostname
Specifies the metaset name.
Deletes the last host from the disk set.
Deletes from the metaset.
Specifies the name of the node to delete from the metaset.
Specifies the name of the host.
Specifies the name of the mediator host to add or delete from the disk set.
# metaset -ssetname-d -m hostname
Refer to disk replacement procedures in the documentation that shipped with your server.
If you are using the Oracle Solaris OS CD, note the following:
SPARC: Type:
ok boot cdrom -s
x86:Insert the CD into the system's CD drive and boot the system by shutting it down and then turning it off and on. In the Current Boot Parameters screen, type b or i.
<<< Current Boot Parameters >>> Boot path: /pci@0,0/pci8086,2545@3/pci8086,1460@1d/pci8086,341a@ 7,1/sd@0,0:a Boot args: Type b [file-name] [boot-flags] <ENTER> to boot with options or i <ENTER> to enter boot interpreter or <ENTER> to boot with defaults <<< timeout in 5 seconds >>> Select (b)oot or (i)nterpreter: b -s
If you are using a Solaris JumpStart server, note the following:
SPARC: Type:
ok boot net -s
x86:Insert the CD into the system's CD drive and boot the system by shutting it down and then turning it off and on. In the Current Boot Parameters screen, type b or i.
<<< Current Boot Parameters >>> Boot path: /pci@0,0/pci8086,2545@3/pci8086,1460@1d/pci8086,341a@ 7,1/sd@0,0:a Boot args: Type b [file-name] [boot-flags] <ENTER> to boot with options or i <ENTER> to enter boot interpreter or <ENTER> to boot with defaults <<< timeout in 5 seconds >>> Select (b)oot or (i)nterpreter: b -s
Re-create the original partitioning scheme that was on the failed disk.
Re-create the original file systems that were on the failed disk.
Note - Ensure that you create the /global/.devices/node@nodeid file system.
# mount device temp-mountpoint
# cd temp-mountpoint # ufsrestore rvf dump-device # rm restoresymtable
# /usr/sbin/installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk raw-disk-device
* Begin MDD root info (do not edit) forceload: misc/md_trans forceload: misc/md_raid forceload: misc/md_mirror forceload: misc/md_hotspares forceload: misc/md_stripe forceload: drv/pcipsy forceload: drv/glm forceload: drv/sd rootdev:/pseudo/md@0:0,10,blk * End MDD root info (do not edit)
Example: Change from— /dev/md/dsk/d10 /dev/md/rdsk/d10 / ufs 1 no - Change to— /dev/dsk/c0t0d0s0 /dev/rdsk/c0t0d0s0 / ufs 1 no -
# cd / # umount temp-mountpoint # fsck raw-disk-device
# reboot
# cldevice repair rootdisk
# metadb -c copies -af raw-disk-device
Specifies the number of replicas to create.
Creates initial state database replicas on the named raw disk device.
phys-schost-2# metaset -s setname -a -h nodelist
Adds (creates) the metaset.
Set up the volume/mirror for root ( /) according to the documentation.
The node is rebooted into cluster mode.
phys-schost-2# metaset -s setname -a -m hostname
Example 12-7 Restoring a Root (/) File System That Was on a Solaris Volume Manager Volume
The following example shows the root (/) file system restored to the node phys-schost-1 from the tape device /dev/rmt/0. The metaset command is run from another node in the cluster, phys-schost-2, to remove and later add back node phys-schost-1 to the metaset schost-1. All other commands are run from phys-schost-1 . A new boot block is created on /dev/rdsk/c0t0d0s0, and three state database replicas are recreated on /dev/rdsk/c0t0d0s4 .
[Become superuser or assume a role that provides solaris.cluster.modify RBAC authorization on a cluster node with access to the metaset, other than the node to be restored.] [Remove the node from the metaset:] phys-schost-2# metaset -s schost-1 -d -h phys-schost-1 [Replace the failed disk and boot the node:]
Boot the node from the Oracle Solaris OS CD:
SPARC: Type:
ok boot cdrom -s
x86:Insert the CD into the system's CD drive and boot the system by shutting it down and then turning it off and on. In the Current Boot Parameters screen, type b or i.
<<< Current Boot Parameters >>> Boot path: /pci@0,0/pci8086,2545@3/pci8086,1460@1d/pci8086,341a@7,1/ sd@0,0:a Boot args: Type b [file-name] [boot-flags] <ENTER> to boot with options or i <ENTER> to enter boot interpreter or <ENTER> to boot with defaults <<< timeout in 5 seconds >>> Select (b)oot or (i)nterpreter: b -s
[Use format and newfs to recreate partitions and file systems .] [Mount the root file system on a temporary mount point:] # mount /dev/dsk/c0t0d0s0 /a [Restore the root file system:] # cd /a # ufsrestore rvf /dev/rmt/0 # rm restoresymtable [Install a new boot block:] # /usr/sbin/installboot /usr/platform/`uname \ -i`/lib/fs/ufs/bootblk /dev/rdsk/c0t0d0s0 [Remove the lines in / temp-mountpoint/etc/system file for MDD root information: ] * Begin MDD root info (do not edit) forceload: misc/md_trans forceload: misc/md_raid forceload: misc/md_mirror forceload: misc/md_hotspares forceload: misc/md_stripe forceload: drv/pcipsy forceload: drv/glm forceload: drv/sd rootdev:/pseudo/md@0:0,10,blk * End MDD root info (do not edit) [Edit the /temp-mountpoint/etc/vfstab file] Example: Change from— /dev/md/dsk/d10 /dev/md/rdsk/d10 / ufs 1 no - Change to— /dev/dsk/c0t0d0s0 /dev/rdsk/c0t0d0s0 /usr ufs 1 no - [Unmount the temporary file system and check the raw disk device:] # cd / # umount /a # fsck /dev/rdsk/c0t0d0s0 [Reboot:] # reboot [Replace the disk ID:] # cldevice repair /dev/rdsk/c0t0d0 [Re-create state database replicas:] # metadb -c 3 -af /dev/rdsk/c0t0d0s4 [Add the node back to the metaset:] phys-schost-2# metaset -s schost-1 -a -h phys-schost-1
Use this procedure to restore a nonencapsulated root (/) file system to a node. The node being restored should not be booted. Ensure the cluster is running without errors before performing the restore procedure.
Note - Because you must partition the new disk using the same format as the failed disk, identify the partitioning scheme before you begin this procedure, and recreate file systems as appropriate.
The phys-schost# prompt reflects a global-cluster prompt. Perform this procedure on a global cluster.
This procedure provides the long forms of the Oracle Solaris Cluster commands. Most commands also have short forms. Except for the long and short forms of the command names, the commands are identical.
Refer to disk replacement procedures in the documentation that shipped with your server.
If you are using the Oracle Solaris OS CD, at the OpenBoot PROM ok prompt, type the following command:
ok boot cdrom -s
If you are using a Solaris JumpStart server, at the OpenBoot PROM ok prompt, type the following command:
ok boot net -s
Re-create the original partitioning scheme that was on the failed disk.
Re-create the original file systems that were on the failed disk.
Note - Ensure that you create the /global/.devices/node@nodeid file system.
# mount device temp-mountpoint
# cd temp-mountpoint # ufsrestore rvf dump-device # rm restoresymtable # cd / # umount temp-mountpoint # fsck raw-disk-device
The file system is now restored.
# /usr/sbin/installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk raw-disk-device
# reboot
# cldevice repair /dev/rdsk/disk-device
The node reboots into cluster mode. The cluster is ready to use.
Example 12-8 Restoring a Nonencapsulated Root (/) File System (Veritas Volume Manager)
The following example shows a nonencapsulated root (/) file system that is restored to the node phys-schost-1 from the tape device /dev/rmt/0.
[Replace the failed disk and boot the node:]
Boot the node from the Oracle Solaris OS CD. At the OpenBoot PROM ok prompt, type the following command:
ok boot cdrom -s ... [Use format and newfs to create partitions and file systems] [Mount the root file system on a temporary mount point:] # mount /dev/dsk/c0t0d0s0 /a [Restore the root file system:] # cd /a # ufsrestore rvf /dev/rmt/0 # rm restoresymtable # cd / # umount /a # fsck /dev/rdsk/c0t0d0s0 [Install a new boot block:] # /usr/sbin/installboot /usr/platform/`uname \ -i`/lib/fs/ufs/bootblk /dev/rdsk/c0t0d0s0 [Reboot:] # reboot [Update the disk ID:] # cldevice repair /dev/rdsk/c0t0d0
Use this procedure to restore an encapsulated root (/) file system to a node. The node being restored should not be booted. Ensure the cluster is running with errors before performing the restore procedure.
Note - Because you must partition the new disk using the same format as the failed disk, identify the partitioning scheme before you begin this procedure, and recreate file systems as appropriate.
The phys-schost# prompt reflects a global-cluster prompt. Perform this procedure on a global cluster.
This procedure provides the long forms of the Oracle Solaris Cluster commands. Most commands also have short forms. Except for the long and short forms of the command names, the commands are identical.
Refer to disk replacement procedures in the documentation that shipped with your server.
If you are using the Oracle Solaris OS CD, at the OpenBoot PROM ok prompt, type the following command:
ok boot cdrom -s
If you are using a Solaris JumpStart server, at the OpenBoot PROM ok prompt, type the following command:
ok boot net -s
Re-create the original partitioning scheme that was on the failed disk.
Re-create the original file systems that were on the failed disk.
Note - Ensure that you create the /global/.devices/ node@nodeid file system.
# mount device temp-mountpoint
# cd temp-mountpoint # ufsrestore rvf dump-device # rm restoresymtable
This file puts the node in VxVM installation mode at the next reboot.
# touch \ /temp-mountpoint/etc/vx/reconfig.d/state.d/install-db
* rootdev:/pseudo/vxio@0:0 * set vxio:vol_rootdev_is_volume=1
Example: Change from— /dev/vx/dsk/rootdg/rootvol /dev/vx/rdsk/rootdg/rootvol / ufs 1 no - Change to— /dev/dsk/c0t0d0s0 /dev/rdsk/c0t0d0s0 / ufs 1 no -
# cd / # umount temp-mountpoint # fsck raw-disk-device
# /usr/sbin/installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk raw-disk-device
# reboot
# cldevice repair /dev/rdsk/c0t0d0
Unmount the global devices file system on the cluster node.
# umount /global/.devices/node@nodeid
Re-minor the rootdg disk group on the cluster node.
# vxdg reminor rootdg 100
# shutdown -g0 -i6 -y
Example 12-9 Restoring an Encapsulated root (/) File System (Veritas Volume Manager)
The following example shows an encapsulated root (/) file system restored to the node phys-schost-1 from the tape device /dev/rmt/0.
[Replace the failed disk and boot the node:]
Boot the node from the Oracle Solaris OS CD. At the OpenBoot PROM ok prompt, type the following command:
ok boot cdrom -s ... [Use format and newfs to create partitions and file systems] [Mount the root file system on a temporary mount point:] # mount /dev/dsk/c0t0d0s0 /a [Restore the root file system:] # cd /a # ufsrestore rvf /dev/rmt/0 # rm restoresymtable [Create an empty install-db file:] # touch /a/etc/vx/reconfig.d/state.d/install-db [Edit /etc/system on the temporary file system and remove or comment out the following entries:] # rootdev:/pseudo/vxio@0:0 # set vxio:vol_rootdev_is_volume=1 [Edit /etc/vfstab on the temporary file system:] Example: Change from— /dev/vx/dsk/rootdg/rootvol /dev/vx/rdsk/rootdg/rootvol / ufs 1 no- Change to— /dev/dsk/c0t0d0s0 /dev/rdsk/c0t0d0s0 / ufs 1 no - [Unmount the temporary file system, then check the file system:] # cd / # umount /a # fsck /dev/rdsk/c0t0d0s0 [Install a new boot block:] # /usr/sbin/installboot /usr/platform/`uname \ -i`/lib/fs/ufs/bootblk /dev/rdsk/c0t0d0s0 [Reboot:] # reboot [Update the disk ID:] # cldevice repair /dev/rdsk/c0t0d0 [Encapsulate the disk::] # vxinstall Choose to encapsulate the root disk. [If a conflict in minor number occurs, reminor the rootdg disk group:] # umount /global/.devices/node@nodeid # vxdg reminor rootdg 100 # shutdown -g0 -i6 -y
See Also
For instructions about how to mirror the encapsulated root disk, see the Oracle Solaris Cluster Software Installation Guide.