The following procedure uses cloning to create a new
cluster:
1. Prepare
the new cluster nodes. (See the lesson titled “Grid Infrastructure
Installation” for details.)
- Check system requirements.
- Check network requirements.
- Install the required operating system packages.
- Set kernel parameters.
- Create groups and users.
- Create the required directories.
- Configure installation owner shell limits.
- Configure block devices for Oracle Clusterware devices.
- Configure SSH and enable user equivalency.
- Use the Cluster Verify Utility to check prerequisites.
2.
Deploy Oracle Clusterware on each of the
destination nodes.
A. Extract
the TAR file created earlier.
# mkdir –p /u01/app/11.2.0/grid
# cd /u01/app/11.2.0
# tar –zxvf /tmp/crs111060.tgz
B. Change
the ownership of files and create Oracle Inventory.
# chown –R grid:oinstall
/u01/app/11.2.0/grid
# mkdir –p /u01/app/oraInventory
# chown grid:oinstall
/u01/app/oraInventory
C. Remove
any network files from /u01/app/11.2.0/grid/network/admin.
$ rm
/u01/app/11.2.0/grid/network/admin/*
When you run the last of the preceding commands on the Grid
home, it clears setuid and setgid information from the Oracle binary. It also
clears setuid from the following binaries:
<Grid_home>/bin/extjob
<Grid_home>/bin/jssu
<Grid_home>/bin/oradism
Run the following commands to restore the cleared
information:
# chmod u+s <Grid_home>/bin/oracle
# chmod g+s <Grid_home>/bin/oracle
# chmod u+s <Grid_home>/bin/extjob
# chmod u+s <Grid_home>/bin/jssu
# chmod u+s <Grid_home>/bin/oradism
clone.pl Script
Cloning to a new cluster and cloning to extend an existing
cluster both use a PERL script. The clone.pl script is used, which:
• Can
be used on the command line
• Can
be contained in a shell script
• Accepts
many parameters as input
• Is
invoked by the PERL interpreter
# perl <Grid_home>/clone/bin/clone.pl
-silent $E01 $E02 $E03 $E04 $C01 $C02
The clone.pl script accepts four environment variables as input.
They are as follows:
Symbol
|
Variable
|
Description
|
E01
|
ORACLE_BASE
|
The location of the Oracle base
directory
|
E02
|
ORACLE_HOME
|
The location of the Oracle Grid
Infrastructure home. This directory location must exist and must be owned by
the Oracle operating system group: oinstall
|
E03
|
ORACLE_HOME_NAME
|
The name of the Oracle Grid
Infrastructure home
|
E04
|
INVENTORY_LOCATION
|
The location of the Oracle
Inventory
|
C01
|
CLUSTER_NODES
|
The short node names for the nodes
in the cluster
|
C02
|
LOCAL_NODE
|
The short name of the local node
|
3. Create
a shell script to invoke clone.pl supplying input.
#!/bin/sh
ORACLE_BASE=/u01/app/oracle
GRID_HOME=/u01/app/11.2.0/grid
THIS_NODE=`hostname -s`
E01=ORACLE_BASE=${ORACLE_BASE}
E02=ORACLE_HOME=${ORACLE_HOME}
E03=ORACLE_HOME_NAME=OraGridHome1
E04=INVENTORY_LOCATION=${ORACLE_BASE}/oraInventory
#C00="-O'-debug'"
C01="-O'\"CLUSTER_NODES={node1,node2}\"'"
C02="-O'\"LOCAL_NODE=${THIS_NODE}\"'"
perl ${GRID_HOME}/clone/bin/clone.pl -silent $E01 $E02 $E03 $E04 $C01
$C02
4.
Run the script created in step 3 on each node.
$ /tmp/my-clone-script.sh
5.
Prepare the crsconfig_params file.
6.
Run the cluvfy utility to validate the
installation.
$ cluvfy stage –post crsinst –n
all -verbose
Log Files Generated During Cloning
/u01/app/oraInventory/logs/cloneActions<timestamp>.log
/u01/app/oraInventory/logs/oraInstall<timestamp>.err
/u01/app/oraInventory/logs/oraInstall<timestamp>.out
No comments:
Post a Comment