手把手一起安装RAC+DataGuard

RAC集群软件存在两大核心部分:表决磁盘、OCR. 

脚本

1、a_preusers.sh

#!/bin/bash
#Purpose:Create 6 groups named 'oinstall','dba','asmadmin','asmdba','asmoper','oper', plus 2 users named 'oracle','grid'.
#Also setting the Environment
#variable for oracle user.
#variable for grid user.
#Usage:Log on as the superuser('root'),and then execute the command:#./1preusers.sh
#Author:Asher Huang
echo "Now create 6 groups named 'oinstall','dba','asmadmin','asmdba','asmoper','oper'"
echo "Plus 2 users named 'oracle','grid',Also setting the Environment"
groupadd -g 1000 oinstall
groupadd -g 1200 asmadmin
groupadd -g 1201 asmdba
groupadd -g 1202 asmoper
useradd -u 1100 -g oinstall -G asmadmin,asmdba,asmoper -d /home/grid -s
/bin/bash -c "grid Infrastructure Owner" grid
echo "grid" | passwd --stdin grid
echo 'export PS1="`/bin/hostname -s`-> "'>> /home/grid/.bash_profile
echo "export TMP=/tmp">> /home/grid/.bash_profile
echo 'export TMPDIR=$TMP'>>/home/grid/.bash_profile
echo "export ORACLE_SID=+ASM1">> /home/grid/.bash_profile
echo "export ORACLE_BASE=/u01/app/grid">> /home/grid/.bash_profile
echo "export ORACLE_HOME=/u01/app/11.2.0/grid">> /home/grid/.bash_profile
echo "export ORACLE_TERM=xterm">> /home/grid/.bash_profile
echo "export NLS_DATE_FORMAT='yyyy/mm/dd hh24:mi:ss'" >> /home/grid/.bash_profile
echo 'export TNS_ADMIN=$ORACLE_HOME/network/admin' >> /home/grid/.bash_profile
echo 'export PATH=/usr/sbin:$PATH'>> /home/grid/.bash_profile
echo 'export PATH=$ORACLE_HOME/bin:$PATH'>> /home/grid/.bash_profile
echo 'export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib' >> /home/grid/.bash_profile
echo 'export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib' >> /home/grid/.bash_profile
echo "export EDITOR=vi" >> /home/grid/.bash_profile
echo "export LANG=en_US" >> /home/grid/.bash_profile
echo "export NLS_LANG=american_america.AL32UTF8" >> /home/grid/.bash_profile
echo "umask 022">> /home/grid/.bash_profile
groupadd -g 1300 dba
groupadd -g 1301 oper
useradd -u 1101 -g oinstall -G dba,oper,asmdba -d /home/oracle -s /bin/bash -c "Oracle Software Owner" oracle
echo "oracle" | passwd --stdin oracle
echo 'export PS1="`/bin/hostname -s`-> "' >> /home/oracle/.bash_profile
echo "export TMP=/tmp" >> /home/oracle/.bash_profile
echo 'export TMPDIR=$TMP'>>/home/oracle/.bash_profile
echo "export ORACLE_HOSTNAME=node1.localdomain">> /home/oracle/.bash_profile
echo "export ORACLE_SID=devdb1">> /home/oracle/.bash_profile
echo "export ORACLE_BASE=/u01/app/oracle">> /home/oracle/.bash_profile
echo 'export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1'>> /home/oracle/.bash_profile
echo "export ORACLE_UNQNAME=devdb">> /home/oracle/.bash_profile
echo 'export TNS_ADMIN=$ORACLE_HOME/network/admin' >> /home/oracle/.bash_profile
echo "export ORACLE_TERM=xterm">> /home/oracle/.bash_profile
echo 'export PATH=/usr/sbin:$PATH'>> /home/oracle/.bash_profile
echo 'export PATH=$ORACLE_HOME/bin:$PATH'>> /home/oracle/.bash_profile
echo 'export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib'>> /home/oracle/.bash_profile
echo 'export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib' >> /home/oracle/.bash_profile
echo "export EDITOR=vi" >> /home/oracle/.bash_profile
echo "export LANG=en_US" >> /home/oracle/.bash_profile
echo "export NLS_LANG=american_america.AL32UTF8" >> /home/oracle/.bash_profile
echo "export NLS_DATE_FORMAT='yyyy/mm/dd hh24:mi:ss'" >> /home/oracle/.bash_profile
echo "umask 022">> /home/oracle/.bash_profile
echo "The Groups and users has been created"
echo "The Environment for grid,oracle also has been set successfully"
View Code
  • 在node1上执行完此脚本,注意修改在node上执行完成此脚本之后,需要手工修改一些参数,因为脚本中的设置是基于node1上的修改.不适合node2上的参数
  • 在node2上将export ORACLE_HOSTNAME=node1.localdomain修改为export ORACLE_HOSTNAME=node2.localdomain
  • 在node2上,在oracle用户下的.bash_profile中,将ORACLE_SID=devdb1修改为ORACLE_SID=devdb2
  • 在node2上,在grid用户下的.bash_profile中,将export ORACLE_SID=+ASM1修改为export ORACLE_SID=+ASM2 

2、b_predir.sh

#!/bin/bash
#Purpose:Create the necessary directory for oracle,grid users and change the authention to oracle,grid users.
#Usage:Log on as the superuser('root'),and then execute the command:#./2predir.sh
#Author:Asher Huang
echo "Now create the necessary directory for oracle,grid users and change
the authention to oracle,grid users..."
mkdir -p /u01/app/grid
mkdir -p /u01/app/11.2.0/grid
mkdir -p /u01/app/oracle
chown -R oracle:oinstall /u01
chown -R grid:oinstall /u01/app/grid
chown -R grid:oinstall /u01/app/11.2.0
chmod -R 775 /u01
echo "The necessary directory for oracle,grid users and change the authention to oracle,grid users has been finished"
View Code 

3、c_prelimits.sh

#!/bin/bash
#Purpose:Change the /etc/security/limits.conf.
#Usage:Log on as the superuser('root'),and then execute the command:#./3prelimits.sh
#Author:Asher Huang
echo "Now modify the /etc/security/limits.conf,but backup it named /etc/security/limits.conf.bak before"
cp /etc/security/limits.conf /etc/security/limits.conf.bak
echo "oracle soft nproc 2047" >>/etc/security/limits.conf
echo "oracle hard nproc 16384" >>/etc/security/limits.conf
echo "oracle soft nofile 1024" >>/etc/security/limits.conf
echo "oracle hard nofile 65536" >>/etc/security/limits.conf
echo "grid soft nproc 2047" >>/etc/security/limits.conf
echo "grid hard nproc 16384" >>/etc/security/limits.conf
echo "grid soft nofile 1024" >>/etc/security/limits.conf
echo "grid hard nofile 65536" >>/etc/security/limits.conf
echo "Modifing the /etc/security/limits.conf has been succeed."
View Code 

4、d_prelongi.sh

#!/bin/bash
#Purpose:Modify the /etc/pam.d/login.
#Usage:Log on as the superuser('root'),and then execute the command:#./4prelimits.sh
#Author:Asher Huang
echo "Now modify the /etc/pam.d/login,but with a backup named /etc/pam.d/login.bak"
cp /etc/pam.d/login /etc/pam.d/login.bak
echo "session required /lib/security/pam_limits.so" >>/etc/pam.d/login
echo "session required pam_limits.so" >>/etc/pam.d/login
echo "Modifing the /etc/pam.d/login has been succeed."
View Code 

5、e_preprofile.sh

#!/bin/bash
#Purpose:Modify the /etc/profile.
#Usage:Log on as the superuser('root'),and then execute the command:#./5preprofile.sh
#Author:Asher Huang
echo "Now modify the /etc/profile,but with a backup named /etc/profile.bak"
cp /etc/profile /etc/profile.bak
echo 'if [ $USER = "oracle" ]||[ $USER = "grid" ]; then' >> /etc/profile
echo 'if [ $SHELL = "/bin/ksh" ]; then' >> /etc/profile
echo 'ulimit -p 16384' >> /etc/profile
echo 'ulimit -n 65536' >> /etc/profile
echo 'else' >> /etc/profile
echo 'ulimit -u 16384 -n 65536' >> /etc/profile
echo 'fi' >> /etc/profile
echo 'fi' >> /etc/profile
echo "Modifing the /etc/profile has been succeed."
View Code 

6、f_presysctl.sh

#!/bin/bash
#Purpose:Modify the /etc/sysctl.conf.
#Usage:Log on as the superuser('root'),and then execute the command:#./6presysctl.sh
#Author:Asher Huang
echo "Now modify the /etc/sysctl.conf,but with a backup named /etc/sysctl.bak"
cp /etc/sysctl.conf /etc/sysctl.conf.bak
echo "fs.aio-max-nr = 1048576" >> /etc/sysctl.conf
echo "fs.file-max = 6815744" >> /etc/sysctl.conf
echo "kernel.shmall = 2097152" >> /etc/sysctl.conf
echo "kernel.shmmax = 1054472192" >> /etc/sysctl.conf
echo "kernel.shmmni = 4096" >> /etc/sysctl.conf
echo "kernel.sem = 250 32000 100 128" >> /etc/sysctl.conf
echo "net.ipv4.ip_local_port_range = 9000 65500" >> /etc/sysctl.conf
echo "net.core.rmem_default = 262144" >> /etc/sysctl.conf
echo "net.core.rmem_max = 4194304" >> /etc/sysctl.conf
echo "net.core.wmem_default = 262144" >> /etc/sysctl.conf
echo "net.core.wmem_max = 1048586" >> /etc/sysctl.conf
echo "net.ipv4.tcp_wmem = 262144 262144 262144" >> /etc/sysctl.conf
echo "net.ipv4.tcp_rmem = 4194304 4194304 4194304" >> /etc/sysctl.conf
echo "Modifing the /etc/sysctl.conf has been succeed."
echo "Now make the changes take effect....."
sysctl -p
View Code 

双节点上配置内容

0、停止 ntp服务,11gR2新增的检查项

[root@node2 ~]# service ntpd status
ntpd is stopped
[root@node2 ~]# chkconfig ntpd off
[root@node2 ~]# cp /etc/ntp.conf /etc/ntp.conf.bak
[root@node2 ~]# rm -rf /etc/ntp.conf
View Code

两个节点都要执行

node1-> ./runcluvfy.sh stage -pre crsinst -n node1,node2 -fixup -verbose

Performing pre-checks for cluster services setup 

Checking node reachability...

Check: Node reachability from node "node1"
  Destination Node                      Reachable?              
  ------------------------------------  ------------------------
  node1                                 yes                     
  node2                                 yes                     
Result: Node reachability check passed from node "node1"


Checking user equivalence...

Check: User equivalence for user "grid"
  Node Name                             Comment                 
  ------------------------------------  ------------------------
  node2                                 passed                  
  node1                                 passed                  
Result: User equivalence check passed for user "grid"

Checking node connectivity...

Checking hosts config file...
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         passed                                            
  node1         passed                                            

Verification of the hosts config file successful


Interface information for node "node2"
 Name   IP Address      Subnet          Gateway         Def. Gateway    HW Address        MTU   
 ------ --------------- --------------- --------------- --------------- ----------------- ------
 eth0   192.168.1.192   192.168.1.0     0.0.0.0         192.168.1.1     00:0C:29:70:8F:EA 1500  
 eth1   192.168.137.12  192.168.137.0   0.0.0.0         192.168.1.1     00:0C:29:70:8F:F4 1500  


Interface information for node "node1"
 Name   IP Address      Subnet          Gateway         Def. Gateway    HW Address        MTU   
 ------ --------------- --------------- --------------- --------------- ----------------- ------
 eth0   192.168.1.191   192.168.1.0     0.0.0.0         192.168.1.1     00:0C:29:A6:E0:06 1500  
 eth1   192.168.137.11  192.168.137.0   0.0.0.0         192.168.1.1     00:0C:29:A6:E0:10 1500  


Check: Node connectivity of subnet "192.168.1.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node2:eth0                      node1:eth0                      yes             
Result: Node connectivity passed for subnet "192.168.1.0" with node(s) node2,node1


Check: TCP connectivity of subnet "192.168.1.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node1:192.168.1.191             node2:192.168.1.192             passed          
Result: TCP connectivity check passed for subnet "192.168.1.0"


Check: Node connectivity of subnet "192.168.137.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node2:eth1                      node1:eth1                      yes             
Result: Node connectivity passed for subnet "192.168.137.0" with node(s) node2,node1


Check: TCP connectivity of subnet "192.168.137.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node1:192.168.137.11            node2:192.168.137.12            passed          
Result: TCP connectivity check passed for subnet "192.168.137.0"


Interfaces found on subnet "192.168.1.0" that are likely candidates for VIP are:
node2 eth0:192.168.1.192
node1 eth0:192.168.1.191

Interfaces found on subnet "192.168.137.0" that are likely candidates for a private interconnect are:
node2 eth1:192.168.137.12
node1 eth1:192.168.137.11

Result: Node connectivity check passed


Check: Total memory 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1.96GB (2054996.0KB)      1.5GB (1572864.0KB)       passed    
  node1         1.96GB (2054996.0KB)      1.5GB (1572864.0KB)       passed    
Result: Total memory check passed

Check: Available memory 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1.82GB (1903472.0KB)      50MB (51200.0KB)          passed    
  node1         1.75GB (1838776.0KB)      50MB (51200.0KB)          passed    
Result: Available memory check passed

Check: Swap space 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         5GB (5242876.0KB)         2.94GB (3082494.0KB)      passed    
  node1         5GB (5242876.0KB)         2.94GB (3082494.0KB)      passed    
Result: Swap space check passed

Check: Free disk space for "node2:/tmp" 
  Path              Node Name     Mount point   Available     Required      Comment     
  ----------------  ------------  ------------  ------------  ------------  ------------
  /tmp              node2         /             11.4GB        1GB           passed      
Result: Free disk space check passed for "node2:/tmp"

Check: Free disk space for "node1:/tmp" 
  Path              Node Name     Mount point   Available     Required      Comment     
  ----------------  ------------  ------------  ------------  ------------  ------------
  /tmp              node1         /             7.76GB        1GB           passed      
Result: Free disk space check passed for "node1:/tmp"

Check: User existence for "grid" 
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         exists                    passed                  
  node1         exists                    passed                  
Result: User existence check passed for "grid"

Check: Group existence for "oinstall" 
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         exists                    passed                  
  node1         exists                    passed                  
Result: Group existence check passed for "oinstall"

Check: Group existence for "dba" 
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         exists                    passed                  
  node1         exists                    passed                  
Result: Group existence check passed for "dba"

Check: Membership of user "grid" in group "oinstall" [as Primary]
  Node Name         User Exists   Group Exists  User in Group  Primary       Comment     
  ----------------  ------------  ------------  ------------  ------------  ------------
  node2             yes           yes           yes           yes           passed      
  node1             yes           yes           yes           yes           passed      
Result: Membership check for user "grid" in group "oinstall" [as Primary] passed

Check: Membership of user "grid" in group "dba" 
  Node Name         User Exists   Group Exists  User in Group  Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             yes           yes           yes           passed          
  node1             yes           yes           yes           passed          
Result: Membership check for user "grid" in group "dba" passed

Check: Run level 
  Node Name     run level                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         3                         3,5                       passed    
  node1         3                         3,5                       passed    
Result: Run level check passed

Check: Hard limits for "maximum open file descriptors" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             hard          65536         65536         passed          
  node1             hard          65536         65536         passed          
Result: Hard limits check passed for "maximum open file descriptors"

Check: Soft limits for "maximum open file descriptors" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             soft          1024          1024          passed          
  node1             soft          1024          1024          passed          
Result: Soft limits check passed for "maximum open file descriptors"

Check: Hard limits for "maximum user processes" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             hard          16384         16384         passed          
  node1             hard          16384         16384         passed          
Result: Hard limits check passed for "maximum user processes"

Check: Soft limits for "maximum user processes" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             soft          2047          2047          passed          
  node1             soft          2047          2047          passed          
Result: Soft limits check passed for "maximum user processes"

Check: System architecture 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         x86_64                    x86_64                    passed    
  node1         x86_64                    x86_64                    passed    
Result: System architecture check passed

Check: Kernel version 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         2.6.39-200.24.1.el6uek.x86_64  2.6.9                     passed    
  node1         2.6.39-200.24.1.el6uek.x86_64  2.6.9                     passed    
Result: Kernel version check passed

Check: Kernel parameter for "semmsl" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         250                       250                       passed    
  node1         250                       250                       passed    
Result: Kernel parameter check passed for "semmsl"

Check: Kernel parameter for "semmns" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         32000                     32000                     passed    
  node1         32000                     32000                     passed    
Result: Kernel parameter check passed for "semmns"

Check: Kernel parameter for "semopm" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         100                       100                       passed    
  node1         100                       100                       passed    
Result: Kernel parameter check passed for "semopm"

Check: Kernel parameter for "semmni" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         128                       128                       passed    
  node1         128                       128                       passed    
Result: Kernel parameter check passed for "semmni"

Check: Kernel parameter for "shmmax" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1054472192                536870912                 passed    
  node1         1054472192                536870912                 passed    
Result: Kernel parameter check passed for "shmmax"

Check: Kernel parameter for "shmmni" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         4096                      4096                      passed    
  node1         4096                      4096                      passed    
Result: Kernel parameter check passed for "shmmni"

Check: Kernel parameter for "shmall" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         2097152                   2097152                   passed    
  node1         2097152                   2097152                   passed    
Result: Kernel parameter check passed for "shmall"

Check: Kernel parameter for "file-max" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         6815744                   6815744                   passed    
  node1         6815744                   6815744                   passed    
Result: Kernel parameter check passed for "file-max"

Check: Kernel parameter for "ip_local_port_range" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         between 9000 & 65500      between 9000 & 65500      passed    
  node1         between 9000 & 65500      between 9000 & 65500      passed    
Result: Kernel parameter check passed for "ip_local_port_range"

Check: Kernel parameter for "rmem_default" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         262144                    262144                    passed    
  node1         262144                    262144                    passed    
Result: Kernel parameter check passed for "rmem_default"

Check: Kernel parameter for "rmem_max" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         4194304                   4194304                   passed    
  node1         4194304                   4194304                   passed    
Result: Kernel parameter check passed for "rmem_max"

Check: Kernel parameter for "wmem_default" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         262144                    262144                    passed    
  node1         262144                    262144                    passed    
Result: Kernel parameter check passed for "wmem_default"

Check: Kernel parameter for "wmem_max" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1048586                   1048576                   passed    
  node1         1048586                   1048576                   passed    
Result: Kernel parameter check passed for "wmem_max"

Check: Kernel parameter for "aio-max-nr" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1048576                   1048576                   passed    
  node1         1048576                   1048576                   passed    
Result: Kernel parameter check passed for "aio-max-nr"

Check: Package existence for "make-3.80" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         make-3.81-20.el6          make-3.80                 passed    
  node1         make-3.81-20.el6          make-3.80                 passed    
Result: Package existence check passed for "make-3.80"

Check: Package existence for "binutils-2.15.92.0.2" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         binutils-2.20.51.0.2-5.34.el6  binutils-2.15.92.0.2      passed    
  node1         binutils-2.20.51.0.2-5.34.el6  binutils-2.15.92.0.2      passed    
Result: Package existence check passed for "binutils-2.15.92.0.2"

Check: Package existence for "gcc-3.4.6" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         gcc-4.4.7-3.el6           gcc-3.4.6                 passed    
  node1         gcc-4.4.7-3.el6           gcc-3.4.6                 passed    
Result: Package existence check passed for "gcc-3.4.6"

Check: Package existence for "libaio-0.3.105 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libaio-0.3.106-5 (i386)   libaio-0.3.105 (i386)     passed    
  node1         libaio-0.3.106-5 (i386)   libaio-0.3.105 (i386)     passed    
Result: Package existence check passed for "libaio-0.3.105 (i386)"

Check: Package existence for "libaio-0.3.105 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libaio-0.3.107-10.el6 (x86_64)  libaio-0.3.105 (x86_64)   passed    
  node1         libaio-0.3.107-10.el6 (x86_64)  libaio-0.3.105 (x86_64)   passed    
Result: Package existence check passed for "libaio-0.3.105 (x86_64)"

Check: Package existence for "glibc-2.3.4-2.41 (i686)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         glibc-2.12-1.107.el6 (i686)  glibc-2.3.4-2.41 (i686)   passed    
  node1         glibc-2.12-1.107.el6 (i686)  glibc-2.3.4-2.41 (i686)   passed    
Result: Package existence check passed for "glibc-2.3.4-2.41 (i686)"

Check: Package existence for "glibc-2.3.4-2.41 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         glibc-2.12-1.107.el6 (x86_64)  glibc-2.3.4-2.41 (x86_64)  passed    
  node1         glibc-2.12-1.107.el6 (x86_64)  glibc-2.3.4-2.41 (x86_64)  passed    
Result: Package existence check passed for "glibc-2.3.4-2.41 (x86_64)"

Check: Package existence for "compat-libstdc++-33-3.2.3 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         compat-libstdc++-33-3.2.3-61 (i386)  compat-libstdc++-33-3.2.3 (i386)  passed    
  node1         compat-libstdc++-33-3.2.3-61 (i386)  compat-libstdc++-33-3.2.3 (i386)  passed    
Result: Package existence check passed for "compat-libstdc++-33-3.2.3 (i386)"

Check: Package existence for "compat-libstdc++-33-3.2.3 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         compat-libstdc++-33-3.2.3-69.el6 (x86_64)  compat-libstdc++-33-3.2.3 (x86_64)  passed    
  node1         compat-libstdc++-33-3.2.3-69.el6 (x86_64)  compat-libstdc++-33-3.2.3 (x86_64)  passed    
Result: Package existence check passed for "compat-libstdc++-33-3.2.3 (x86_64)"

Check: Package existence for "elfutils-libelf-0.97 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         elfutils-libelf-0.152-1.el6 (x86_64)  elfutils-libelf-0.97 (x86_64)  passed    
  node1         elfutils-libelf-0.152-1.el6 (x86_64)  elfutils-libelf-0.97 (x86_64)  passed    
Result: Package existence check passed for "elfutils-libelf-0.97 (x86_64)"

Check: Package existence for "elfutils-libelf-devel-0.97" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         elfutils-libelf-devel-0.152-1.el6  elfutils-libelf-devel-0.97  passed    
  node1         elfutils-libelf-devel-0.152-1.el6  elfutils-libelf-devel-0.97  passed    
Result: Package existence check passed for "elfutils-libelf-devel-0.97"

Check: Package existence for "glibc-common-2.3.4" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         glibc-common-2.12-1.107.el6  glibc-common-2.3.4        passed    
  node1         glibc-common-2.12-1.107.el6  glibc-common-2.3.4        passed    
Result: Package existence check passed for "glibc-common-2.3.4"

Check: Package existence for "glibc-devel-2.3.4 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         glibc-devel-2.12-1.107.el6 (x86_64)  glibc-devel-2.3.4 (x86_64)  passed    
  node1         glibc-devel-2.12-1.107.el6 (x86_64)  glibc-devel-2.3.4 (x86_64)  passed    
Result: Package existence check passed for "glibc-devel-2.3.4 (x86_64)"

Check: Package existence for "glibc-headers-2.3.4" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         glibc-headers-2.12-1.107.el6  glibc-headers-2.3.4       passed    
  node1         glibc-headers-2.12-1.107.el6  glibc-headers-2.3.4       passed    
Result: Package existence check passed for "glibc-headers-2.3.4"

Check: Package existence for "gcc-c++-3.4.6" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         gcc-c++-4.4.7-3.el6       gcc-c++-3.4.6             passed    
  node1         gcc-c++-4.4.7-3.el6       gcc-c++-3.4.6             passed    
Result: Package existence check passed for "gcc-c++-3.4.6"

Check: Package existence for "libaio-devel-0.3.105 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libaio-devel-0.3.105-2 (i386)  libaio-devel-0.3.105 (i386)  passed    
  node1         libaio-devel-0.3.105-2 (i386)  libaio-devel-0.3.105 (i386)  passed    
Result: Package existence check passed for "libaio-devel-0.3.105 (i386)"

Check: Package existence for "libaio-devel-0.3.105 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libaio-devel-0.3.107-10.el6 (x86_64)  libaio-devel-0.3.105 (x86_64)  passed    
  node1         libaio-devel-0.3.107-10.el6 (x86_64)  libaio-devel-0.3.105 (x86_64)  passed    
Result: Package existence check passed for "libaio-devel-0.3.105 (x86_64)"

Check: Package existence for "libgcc-3.4.6 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libgcc-3.4.6-8 (i386)     libgcc-3.4.6 (i386)       passed    
  node1         libgcc-3.4.6-8 (i386)     libgcc-3.4.6 (i386)       passed    
Result: Package existence check passed for "libgcc-3.4.6 (i386)"

Check: Package existence for "libgcc-3.4.6 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libgcc-4.4.7-3.el6 (x86_64)  libgcc-3.4.6 (x86_64)     passed    
  node1         libgcc-4.4.7-3.el6 (x86_64)  libgcc-3.4.6 (x86_64)     passed    
Result: Package existence check passed for "libgcc-3.4.6 (x86_64)"

Check: Package existence for "libstdc++-3.4.6 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libstdc++-3.4.6-8 (i386)  libstdc++-3.4.6 (i386)    passed    
  node1         libstdc++-3.4.6-8 (i386)  libstdc++-3.4.6 (i386)    passed    
Result: Package existence check passed for "libstdc++-3.4.6 (i386)"

Check: Package existence for "libstdc++-3.4.6 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libstdc++-4.4.7-3.el6 (x86_64)  libstdc++-3.4.6 (x86_64)  passed    
  node1         libstdc++-4.4.7-3.el6 (x86_64)  libstdc++-3.4.6 (x86_64)  passed    
Result: Package existence check passed for "libstdc++-3.4.6 (x86_64)"

Check: Package existence for "libstdc++-devel-3.4.6 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libstdc++-devel-4.4.7-3.el6 (x86_64)  libstdc++-devel-3.4.6 (x86_64)  passed    
  node1         libstdc++-devel-4.4.7-3.el6 (x86_64)  libstdc++-devel-3.4.6 (x86_64)  passed    
Result: Package existence check passed for "libstdc++-devel-3.4.6 (x86_64)"

Check: Package existence for "sysstat-5.0.5" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         sysstat-9.0.4-20.el6      sysstat-5.0.5             passed    
  node1         sysstat-9.0.4-20.el6      sysstat-5.0.5             passed    
Result: Package existence check passed for "sysstat-5.0.5"

Check: Package existence for "unixODBC-2.2.11 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         unixODBC-2.2.11-10.el5 (i386)  unixODBC-2.2.11 (i386)    passed    
  node1         unixODBC-2.2.11-10.el5 (i386)  unixODBC-2.2.11 (i386)    passed    
Result: Package existence check passed for "unixODBC-2.2.11 (i386)"

Check: Package existence for "unixODBC-2.2.11 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         unixODBC-2.2.14-12.el6_3 (x86_64)  unixODBC-2.2.11 (x86_64)  passed    
  node1         unixODBC-2.2.14-12.el6_3 (x86_64)  unixODBC-2.2.11 (x86_64)  passed    
Result: Package existence check passed for "unixODBC-2.2.11 (x86_64)"

Check: Package existence for "unixODBC-devel-2.2.11 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         unixODBC-devel-2.2.11-2 (i386)  unixODBC-devel-2.2.11 (i386)  passed    
  node1         unixODBC-devel-2.2.11-2 (i386)  unixODBC-devel-2.2.11 (i386)  passed    
Result: Package existence check passed for "unixODBC-devel-2.2.11 (i386)"

Check: Package existence for "unixODBC-devel-2.2.11 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         unixODBC-devel-2.2.14-12.el6_3 (x86_64)  unixODBC-devel-2.2.11 (x86_64)  passed    
  node1         unixODBC-devel-2.2.14-12.el6_3 (x86_64)  unixODBC-devel-2.2.11 (x86_64)  passed    
Result: Package existence check passed for "unixODBC-devel-2.2.11 (x86_64)"

Check: Package existence for "pdksh-5.2.14" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         pdksh-5.2.14-24           pdksh-5.2.14              passed    
  node1         pdksh-5.2.14-24           pdksh-5.2.14              passed    
Result: Package existence check passed for "pdksh-5.2.14"

Check: Package existence for "expat-1.95.7 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         expat-2.0.1-11.el6_2 (x86_64)  expat-1.95.7 (x86_64)     passed    
  node1         expat-2.0.1-11.el6_2 (x86_64)  expat-1.95.7 (x86_64)     passed    
Result: Package existence check passed for "expat-1.95.7 (x86_64)"

Checking for multiple users with UID value 0
Result: Check for multiple users with UID value 0 passed 

Check: Current group ID 
Result: Current group ID check passed
Checking Core file name pattern consistency...
Core file name pattern consistency check passed.

Checking to make sure user "grid" is not in "root" group
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         does not exist            passed                  
  node1         does not exist            passed                  
Result: User "grid" is not part of "root" group. Check passed

Check default user file creation mask
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         0022                      0022                      passed    
  node1         0022                      0022                      passed    
Result: Default user file creation mask check passed

Starting Clock synchronization checks using Network Time Protocol(NTP)...

NTP Configuration file check started...
Network Time Protocol(NTP) configuration file not found on any of the nodes. Oracle Cluster Time Synchronization Service(CTSS) can be used instead of NTP for time synchronization on the cluster nodes

Result: Clock synchronization check using Network Time Protocol(NTP) passed


Pre-check for cluster services setup was successful. 
View Code

 

chkconfig ntp off(将ntp服务,在所有的运行模式下,都给停止掉.)

1、SSH对等性

对等性配置,要注意名字不能写错:authorized_keys,勿将_写成-.

1.1、先是在node1上,oracle用户下执行如下步骤:

node1-> mkdir ~/.ssh
node1-> chmod 700 ~/.ssh
node1-> ssh-keygen -t rsa
node1-> ssh-keygen -t dsa
View Code

1.2、上面四步骤,同样需要在node2上执行.

node1-> cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
node1-> cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
node1-> ssh node2 cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
node1-> ssh node2 cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
node1-> scp ~/.ssh/authorized_keys node2:~/.ssh/authorized_keys
View Code

1.3、node1节点验证:

node1-> ssh node1 date
Sun Jun 30 08:50:48 CST 2013
node1-> ssh node2 date
Sun Jun 30 08:50:57 CST 2013
node1-> ssh node1.localdomain date
Sun Jun 30 08:50:55 CST 2013
node1-> ssh node2.localdomain date
Sun Jun 30 08:51:05 CST 2013
node1-> ssh node1-priv date
Sun Jun 30 08:51:13 CST 2013
node1-> ssh node2-priv date
Sun Jun 30 08:51:23 CST 2013
node1-> ssh node1-priv.localdomain date
Sun Jun 30 08:51:23 CST 2013
node1-> ssh node2-priv.localdomain date
Sun Jun 30 08:51:33 CST 2013
View Code

1.4、将node1节点的验证步骤,同样在node2上同样执行一次.验证全部通过.

1.5、将上述四步(1.1、1.2、1.3、1.4)在两个节点的grid用户下再执行一遍.实现双节点(node1、node2)下,双用户(oracle、grid)下的SSH对等性验证.

2、共享磁盘添加成功

3、ASM磁盘配置完成

--------------

安装Grid,创建在griddg磁盘组上

安装grid infrastructure之前进行脚本验证

node1-> ./runcluvfy.sh stage -pre crsinst -n node1,node2 -fixup -verbose

Performing pre-checks for cluster services setup 

Checking node reachability...

Check: Node reachability from node "node1"
  Destination Node                      Reachable?              
  ------------------------------------  ------------------------
  node1                                 yes                     
  node2                                 yes                     
Result: Node reachability check passed from node "node1"


Checking user equivalence...

Check: User equivalence for user "grid"
  Node Name                             Comment                 
  ------------------------------------  ------------------------
  node2                                 passed                  
  node1                                 passed                  
Result: User equivalence check passed for user "grid"

Checking node connectivity...

Checking hosts config file...
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         passed                                            
  node1         passed                                            

Verification of the hosts config file successful


Interface information for node "node2"
 Name   IP Address      Subnet          Gateway         Def. Gateway    HW Address        MTU   
 ------ --------------- --------------- --------------- --------------- ----------------- ------
 eth0   192.168.1.192   192.168.1.0     0.0.0.0         192.168.1.1     00:0C:29:70:8F:EA 1500  
 eth1   192.168.137.12  192.168.137.0   0.0.0.0         192.168.1.1     00:0C:29:70:8F:F4 1500  


Interface information for node "node1"
 Name   IP Address      Subnet          Gateway         Def. Gateway    HW Address        MTU   
 ------ --------------- --------------- --------------- --------------- ----------------- ------
 eth0   192.168.1.191   192.168.1.0     0.0.0.0         192.168.1.1     00:0C:29:A6:E0:06 1500  
 eth1   192.168.137.11  192.168.137.0   0.0.0.0         192.168.1.1     00:0C:29:A6:E0:10 1500  


Check: Node connectivity of subnet "192.168.1.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node2:eth0                      node1:eth0                      yes             
Result: Node connectivity passed for subnet "192.168.1.0" with node(s) node2,node1


Check: TCP connectivity of subnet "192.168.1.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node1:192.168.1.191             node2:192.168.1.192             passed          
Result: TCP connectivity check passed for subnet "192.168.1.0"


Check: Node connectivity of subnet "192.168.137.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node2:eth1                      node1:eth1                      yes             
Result: Node connectivity passed for subnet "192.168.137.0" with node(s) node2,node1


Check: TCP connectivity of subnet "192.168.137.0"
  Source                          Destination                     Connected?      
  ------------------------------  ------------------------------  ----------------
  node1:192.168.137.11            node2:192.168.137.12            passed          
Result: TCP connectivity check passed for subnet "192.168.137.0"


Interfaces found on subnet "192.168.1.0" that are likely candidates for VIP are:
node2 eth0:192.168.1.192
node1 eth0:192.168.1.191

Interfaces found on subnet "192.168.137.0" that are likely candidates for a private interconnect are:
node2 eth1:192.168.137.12
node1 eth1:192.168.137.11

Result: Node connectivity check passed


Check: Total memory 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1.96GB (2054996.0KB)      1.5GB (1572864.0KB)       passed    
  node1         1.96GB (2054996.0KB)      1.5GB (1572864.0KB)       passed    
Result: Total memory check passed

Check: Available memory 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1.85GB (1943692.0KB)      50MB (51200.0KB)          passed    
  node1         1.77GB (1856724.0KB)      50MB (51200.0KB)          passed    
Result: Available memory check passed

Check: Swap space 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         5GB (5242876.0KB)         2.94GB (3082494.0KB)      passed    
  node1         5GB (5242876.0KB)         2.94GB (3082494.0KB)      passed    
Result: Swap space check passed

Check: Free disk space for "node2:/tmp" 
  Path              Node Name     Mount point   Available     Required      Comment     
  ----------------  ------------  ------------  ------------  ------------  ------------
  /tmp              node2         /             12.2GB        1GB           passed      
Result: Free disk space check passed for "node2:/tmp"

Check: Free disk space for "node1:/tmp" 
  Path              Node Name     Mount point   Available     Required      Comment     
  ----------------  ------------  ------------  ------------  ------------  ------------
  /tmp              node1         /             8.63GB        1GB           passed      
Result: Free disk space check passed for "node1:/tmp"

Check: User existence for "grid" 
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         exists                    passed                  
  node1         exists                    passed                  
Result: User existence check passed for "grid"

Check: Group existence for "oinstall" 
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         exists                    passed                  
  node1         exists                    passed                  
Result: Group existence check passed for "oinstall"

Check: Group existence for "dba" 
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         exists                    passed                  
  node1         exists                    passed                  
Result: Group existence check passed for "dba"

Check: Membership of user "grid" in group "oinstall" [as Primary]
  Node Name         User Exists   Group Exists  User in Group  Primary       Comment     
  ----------------  ------------  ------------  ------------  ------------  ------------
  node2             yes           yes           yes           yes           passed      
  node1             yes           yes           yes           yes           passed      
Result: Membership check for user "grid" in group "oinstall" [as Primary] passed

Check: Membership of user "grid" in group "dba" 
  Node Name         User Exists   Group Exists  User in Group  Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             yes           yes           no            failed          
  node1             yes           yes           no            failed          
Result: Membership check for user "grid" in group "dba" failed

Check: Run level 
  Node Name     run level                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         3                         3,5                       passed    
  node1         3                         3,5                       passed    
Result: Run level check passed

Check: Hard limits for "maximum open file descriptors" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             hard          65536         65536         passed          
  node1             hard          65536         65536         passed          
Result: Hard limits check passed for "maximum open file descriptors"

Check: Soft limits for "maximum open file descriptors" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             soft          1024          1024          passed          
  node1             soft          1024          1024          passed          
Result: Soft limits check passed for "maximum open file descriptors"

Check: Hard limits for "maximum user processes" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             hard          16384         16384         passed          
  node1             hard          16384         16384         passed          
Result: Hard limits check passed for "maximum user processes"

Check: Soft limits for "maximum user processes" 
  Node Name         Type          Available     Required      Comment         
  ----------------  ------------  ------------  ------------  ----------------
  node2             soft          2047          2047          passed          
  node1             soft          2047          2047          passed          
Result: Soft limits check passed for "maximum user processes"

Check: System architecture 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         x86_64                    x86_64                    passed    
  node1         x86_64                    x86_64                    passed    
Result: System architecture check passed

Check: Kernel version 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         2.6.39-200.24.1.el6uek.x86_64  2.6.9                     passed    
  node1         2.6.39-200.24.1.el6uek.x86_64  2.6.9                     passed    
Result: Kernel version check passed

Check: Kernel parameter for "semmsl" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         250                       250                       passed    
  node1         250                       250                       passed    
Result: Kernel parameter check passed for "semmsl"

Check: Kernel parameter for "semmns" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         32000                     32000                     passed    
  node1         32000                     32000                     passed    
Result: Kernel parameter check passed for "semmns"

Check: Kernel parameter for "semopm" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         100                       100                       passed    
  node1         100                       100                       passed    
Result: Kernel parameter check passed for "semopm"

Check: Kernel parameter for "semmni" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         128                       128                       passed    
  node1         128                       128                       passed    
Result: Kernel parameter check passed for "semmni"

Check: Kernel parameter for "shmmax" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1054472192                536870912                 passed    
  node1         1054472192                536870912                 passed    
Result: Kernel parameter check passed for "shmmax"

Check: Kernel parameter for "shmmni" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         4096                      4096                      passed    
  node1         4096                      4096                      passed    
Result: Kernel parameter check passed for "shmmni"

Check: Kernel parameter for "shmall" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         2097152                   2097152                   passed    
  node1         2097152                   2097152                   passed    
Result: Kernel parameter check passed for "shmall"

Check: Kernel parameter for "file-max" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         6815744                   6815744                   passed    
  node1         6815744                   6815744                   passed    
Result: Kernel parameter check passed for "file-max"

Check: Kernel parameter for "ip_local_port_range" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         between 9000 & 65500      between 9000 & 65500      passed    
  node1         between 9000 & 65500      between 9000 & 65500      passed    
Result: Kernel parameter check passed for "ip_local_port_range"

Check: Kernel parameter for "rmem_default" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         262144                    262144                    passed    
  node1         262144                    262144                    passed    
Result: Kernel parameter check passed for "rmem_default"

Check: Kernel parameter for "rmem_max" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         4194304                   4194304                   passed    
  node1         4194304                   4194304                   passed    
Result: Kernel parameter check passed for "rmem_max"

Check: Kernel parameter for "wmem_default" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         262144                    262144                    passed    
  node1         262144                    262144                    passed    
Result: Kernel parameter check passed for "wmem_default"

Check: Kernel parameter for "wmem_max" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1048586                   1048576                   passed    
  node1         1048586                   1048576                   passed    
Result: Kernel parameter check passed for "wmem_max"

Check: Kernel parameter for "aio-max-nr" 
  Node Name     Configured                Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         1048576                   1048576                   passed    
  node1         1048576                   1048576                   passed    
Result: Kernel parameter check passed for "aio-max-nr"

Check: Package existence for "make-3.80" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         make-3.81-20.el6          make-3.80                 passed    
  node1         make-3.81-20.el6          make-3.80                 passed    
Result: Package existence check passed for "make-3.80"

Check: Package existence for "binutils-2.15.92.0.2" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         binutils-2.20.51.0.2-5.34.el6  binutils-2.15.92.0.2      passed    
  node1         binutils-2.20.51.0.2-5.34.el6  binutils-2.15.92.0.2      passed    
Result: Package existence check passed for "binutils-2.15.92.0.2"

Check: Package existence for "gcc-3.4.6" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   gcc-3.4.6                 failed    
  node1         missing                   gcc-3.4.6                 failed    
Result: Package existence check failed for "gcc-3.4.6"

Check: Package existence for "libaio-0.3.105 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   libaio-0.3.105 (i386)     failed    
  node1         missing                   libaio-0.3.105 (i386)     failed    
Result: Package existence check failed for "libaio-0.3.105 (i386)"

Check: Package existence for "libaio-0.3.105 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libaio-0.3.107-10.el6 (x86_64)  libaio-0.3.105 (x86_64)   passed    
  node1         libaio-0.3.107-10.el6 (x86_64)  libaio-0.3.105 (x86_64)   passed    
Result: Package existence check passed for "libaio-0.3.105 (x86_64)"

Check: Package existence for "glibc-2.3.4-2.41 (i686)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   glibc-2.3.4-2.41 (i686)   failed    
  node1         missing                   glibc-2.3.4-2.41 (i686)   failed    
Result: Package existence check failed for "glibc-2.3.4-2.41 (i686)"

Check: Package existence for "glibc-2.3.4-2.41 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         glibc-2.12-1.80.el6 (x86_64)  glibc-2.3.4-2.41 (x86_64)  passed    
  node1         glibc-2.12-1.80.el6 (x86_64)  glibc-2.3.4-2.41 (x86_64)  passed    
Result: Package existence check passed for "glibc-2.3.4-2.41 (x86_64)"

Check: Package existence for "compat-libstdc++-33-3.2.3 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   compat-libstdc++-33-3.2.3 (i386)  failed    
  node1         missing                   compat-libstdc++-33-3.2.3 (i386)  failed    
Result: Package existence check failed for "compat-libstdc++-33-3.2.3 (i386)"

Check: Package existence for "compat-libstdc++-33-3.2.3 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   compat-libstdc++-33-3.2.3 (x86_64)  failed    
  node1         missing                   compat-libstdc++-33-3.2.3 (x86_64)  failed    
Result: Package existence check failed for "compat-libstdc++-33-3.2.3 (x86_64)"

Check: Package existence for "elfutils-libelf-0.97 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         elfutils-libelf-0.152-1.el6 (x86_64)  elfutils-libelf-0.97 (x86_64)  passed    
  node1         elfutils-libelf-0.152-1.el6 (x86_64)  elfutils-libelf-0.97 (x86_64)  passed    
Result: Package existence check passed for "elfutils-libelf-0.97 (x86_64)"

Check: Package existence for "elfutils-libelf-devel-0.97" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   elfutils-libelf-devel-0.97  failed    
  node1         missing                   elfutils-libelf-devel-0.97  failed    
Result: Package existence check failed for "elfutils-libelf-devel-0.97"

Check: Package existence for "glibc-common-2.3.4" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         glibc-common-2.12-1.80.el6  glibc-common-2.3.4        passed    
  node1         glibc-common-2.12-1.80.el6  glibc-common-2.3.4        passed    
Result: Package existence check passed for "glibc-common-2.3.4"

Check: Package existence for "glibc-devel-2.3.4 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   glibc-devel-2.3.4 (x86_64)  failed    
  node1         missing                   glibc-devel-2.3.4 (x86_64)  failed    
Result: Package existence check failed for "glibc-devel-2.3.4 (x86_64)"

Check: Package existence for "glibc-headers-2.3.4" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   glibc-headers-2.3.4       failed    
  node1         missing                   glibc-headers-2.3.4       failed    
Result: Package existence check failed for "glibc-headers-2.3.4"

Check: Package existence for "gcc-c++-3.4.6" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   gcc-c++-3.4.6             failed    
  node1         missing                   gcc-c++-3.4.6             failed    
Result: Package existence check failed for "gcc-c++-3.4.6"

Check: Package existence for "libaio-devel-0.3.105 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   libaio-devel-0.3.105 (i386)  failed    
  node1         missing                   libaio-devel-0.3.105 (i386)  failed    
Result: Package existence check failed for "libaio-devel-0.3.105 (i386)"

Check: Package existence for "libaio-devel-0.3.105 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   libaio-devel-0.3.105 (x86_64)  failed    
  node1         missing                   libaio-devel-0.3.105 (x86_64)  failed    
Result: Package existence check failed for "libaio-devel-0.3.105 (x86_64)"

Check: Package existence for "libgcc-3.4.6 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   libgcc-3.4.6 (i386)       failed    
  node1         missing                   libgcc-3.4.6 (i386)       failed    
Result: Package existence check failed for "libgcc-3.4.6 (i386)"

Check: Package existence for "libgcc-3.4.6 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libgcc-4.4.6-4.el6 (x86_64)  libgcc-3.4.6 (x86_64)     passed    
  node1         libgcc-4.4.6-4.el6 (x86_64)  libgcc-3.4.6 (x86_64)     passed    
Result: Package existence check passed for "libgcc-3.4.6 (x86_64)"

Check: Package existence for "libstdc++-3.4.6 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   libstdc++-3.4.6 (i386)    failed    
  node1         missing                   libstdc++-3.4.6 (i386)    failed    
Result: Package existence check failed for "libstdc++-3.4.6 (i386)"

Check: Package existence for "libstdc++-3.4.6 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         libstdc++-4.4.6-4.el6 (x86_64)  libstdc++-3.4.6 (x86_64)  passed    
  node1         libstdc++-4.4.6-4.el6 (x86_64)  libstdc++-3.4.6 (x86_64)  passed    
Result: Package existence check passed for "libstdc++-3.4.6 (x86_64)"

Check: Package existence for "libstdc++-devel-3.4.6 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   libstdc++-devel-3.4.6 (x86_64)  failed    
  node1         missing                   libstdc++-devel-3.4.6 (x86_64)  failed    
Result: Package existence check failed for "libstdc++-devel-3.4.6 (x86_64)"

Check: Package existence for "sysstat-5.0.5" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         sysstat-9.0.4-20.el6      sysstat-5.0.5             passed    
  node1         sysstat-9.0.4-20.el6      sysstat-5.0.5             passed    
Result: Package existence check passed for "sysstat-5.0.5"

Check: Package existence for "unixODBC-2.2.11 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   unixODBC-2.2.11 (i386)    failed    
  node1         missing                   unixODBC-2.2.11 (i386)    failed    
Result: Package existence check failed for "unixODBC-2.2.11 (i386)"

Check: Package existence for "unixODBC-2.2.11 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         unixODBC-2.2.14-11.el6 (x86_64)  unixODBC-2.2.11 (x86_64)  passed    
  node1         unixODBC-2.2.14-11.el6 (x86_64)  unixODBC-2.2.11 (x86_64)  passed    
Result: Package existence check passed for "unixODBC-2.2.11 (x86_64)"

Check: Package existence for "unixODBC-devel-2.2.11 (i386)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   unixODBC-devel-2.2.11 (i386)  failed    
  node1         missing                   unixODBC-devel-2.2.11 (i386)  failed    
Result: Package existence check failed for "unixODBC-devel-2.2.11 (i386)"

Check: Package existence for "unixODBC-devel-2.2.11 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   unixODBC-devel-2.2.11 (x86_64)  failed    
  node1         missing                   unixODBC-devel-2.2.11 (x86_64)  failed    
Result: Package existence check failed for "unixODBC-devel-2.2.11 (x86_64)"

Check: Package existence for "pdksh-5.2.14" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         missing                   pdksh-5.2.14              failed    
  node1         missing                   pdksh-5.2.14              failed    
Result: Package existence check failed for "pdksh-5.2.14"

Check: Package existence for "expat-1.95.7 (x86_64)" 
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         expat-2.0.1-11.el6_2 (x86_64)  expat-1.95.7 (x86_64)     passed    
  node1         expat-2.0.1-11.el6_2 (x86_64)  expat-1.95.7 (x86_64)     passed    
Result: Package existence check passed for "expat-1.95.7 (x86_64)"

Checking for multiple users with UID value 0
Result: Check for multiple users with UID value 0 passed 

Check: Current group ID 
Result: Current group ID check passed
Checking Core file name pattern consistency...
Core file name pattern consistency check passed.

Checking to make sure user "grid" is not in "root" group
  Node Name     Status                    Comment                 
  ------------  ------------------------  ------------------------
  node2         does not exist            passed                  
  node1         does not exist            passed                  
Result: User "grid" is not part of "root" group. Check passed

Check default user file creation mask
  Node Name     Available                 Required                  Comment   
  ------------  ------------------------  ------------------------  ----------
  node2         0022                      0022                      passed    
  node1         0022                      0022                      passed    
Result: Default user file creation mask check passed

Starting Clock synchronization checks using Network Time Protocol(NTP)...

NTP Configuration file check started...
Network Time Protocol(NTP) configuration file not found on any of the nodes. Oracle Cluster Time Synchronization Service(CTSS) can be used instead of NTP for time synchronization on the cluster nodes

Result: Clock synchronization check using Network Time Protocol(NTP) passed

Fixup information has been generated for following node(s):
node2,node1
Please run the following script on each node as "root" user to execute the fixups:
'/tmp/CVU_11.2.0.1.0_grid/runfixup.sh'

Pre-check for cluster services setup was unsuccessful on all the nodes. 
View Code

创建磁盘组,分别用来创建安装数据库的磁盘组和创建闪回区的磁盘组,ASM磁盘组的创建可以通过你ASMCA图形界面创建.

在安装grid infrastructure之前,进行验证的时候,如果出现Device Check for ASM警告信息,忽略即可;

安装oracle软件

安装数据库

--------------

OCR会自动备份

voting disk需要手工备份 

--------------

如何验证负载均衡和failover?

负载均衡是由SCAN自行分配解决的.

模拟failover,使节点中的其中一个instance给shutdown掉,然后所有的请求都会自动切换到另外运行的节点上来.

要想实验loadbalance and failover,必须安装配置scanip 

------------------------------------------------------------------------------------

DataGuard的安装与配置

>>只需要安装软件,不需要安装数据库

使用ASMCA创建ASM磁盘组.

------------------------------------------------------------------------------------

主库与备库同步

包含两部分:文件同步、数据同步 

文件同步,通过创建表空间的方式来测试;

数据同步,通过添加修改删除记录的方式来测试同步;

------------------------------------------------------------------------------------

主库与备库同步切换

SQL> show parameter fal

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
fal_client                           string
fal_server                           string
View Code 

RAC的主库,RAC的备库;在将备库切换成主库之前,需要将RAC备库中的其他所有节点关闭,只有一个节点进行相关操作.

主备切换的先后顺序:先将主库切换成备库,此时备库也是备库,这个阶段是一个群龙无首,全是备库的阶段.

DataGuard中有算中模式:最大性能、最大保护、最高可用

------------------------------------------------------------------------------------

主库切换备库,备库切换主库

将备库switchover成主库
alter database commit to switchover to primary;

将主库switchover成备库
alter database commit to switchover to physical standby with session shutdown;
View Code

------------------------------------------------------------------------------------ 

--开启

--停掉REDO APPLY(先停掉REDO APPLY,再将备库切换成主库.这样操作,少报错;)
alter database recover managed standby database cancel; 

<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<DataGuard安装与配置>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

注意:DataGuard只需要安装grid、oracle软件,不需要安装数据库.

DataGuard机器的磁盘情况:ASM共享磁盘组GRIDDG、DATA、FLASH,两外还要配置一块硬盘,用来存放主库的备份信息. 而且主库上(一般node1),也需要配置一块空闲磁盘,用来存放主库的备份信息,将来需要将主库上的备份信息ftp到DataGuard上去.

普通的磁盘(非共享磁盘),在进行格式化分区之后,需要做成文件系统,才可使用.做成文件系统的命令mkfs.ext4 /dev/sdb1进行文件系统的制作.(/dev/sdb1注意不要搞错);然后文件系统做完了之后,需要到根目录(/)下创建一个挂载点

  >#mkdir rman_backup

  >#chown -R oracle:oinstall rman_backup/

  >#mount -t ext4 /dev/sdb1 /rman_backup/

  >cat /etc/fstab  

[root@node1 ~]# cat /etc/fstab

#
# /etc/fstab
# Created by anaconda on Thu Jun 27 23:44:22 2013
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
UUID=02ff7b7b-1f51-48a5-bd19-2e0bdb071ffb /                       ext4    defaults        1 1
UUID=91e314c2-cfe2-4e7f-b8a9-b07134233679 swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   size=3000m      0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
View Code

   在/etc/fstab中添加一条记录,用来挂载新添加的磁盘,将来机器重启的话,就会自动挂载此硬盘.

 

posted @ 2013-06-21 09:25  ArcerZhang  阅读(1258)  评论(0编辑  收藏  举报