Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Installing Oracle 12c RAC on Linux 6

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

1. Modify the hosts file

vi /etc/sysconfig/network-scripts/ifcfg-eth0

#Public

192.168.1.240 node1

192.168.1.241 node2

#Virtual

192.168.1.242 node1-vip

192.168.1.243 node2-vip

#Private

192.168.0.240 node1-priv

192.168.0.241 node2-priv

#SCAN

192.168.1.245 node-cluster cluster-scan

2. turn off the firewall

service iptables stop

chkconfig iptables off

setenforce 0

3. Configure SELinux for

vi /etc/selinux/config

selinux=permissive

4. add group

groupadd -g 54321 oinstall

groupadd -g 54322 dba

groupadd -g 54323 oper

groupadd -g 54325 asmdba

groupadd -g 54328 asmadmin

groupadd -g 54329 asmoper

5. add users

useradd -u 54321 -g oinstall -G dba,oper,asmdba oracle

useradd -u 54322 -g oinstall -G dba,asmdba,asmadmin,asmoper grid

passwd oracle

passwd grid

6. Configuring shell limits for Oracle users

vi /etc/security/limits.confs

add content

# Grid user

grid soft nofile 2047

grid hard nofile 65536

grid soft nproc 16384

grid hard nproc 16384

grid soft stack 10240

grid hard stack 32768

grid hard memlock 134217728

grid soft memlock 134217728

# Oracle user

oracle soft nofile 2047

oracle hard nofile 65536

oracle soft nproc 16384

oracle hard nproc 16384

oracle soft stack 10240

oracle hard stack 32768

oracle hard memlock 134217728

oracle soft memlock 134217728

7. New Installation Directory

mkdir -p /u01/app/12.1.0/grid

mkdir -p /u01/app/grid

mkdir -p /u01/app/oracle

chown -R grid:oinstall /u01

chown oracle:oinstall /u01/app/oracle

chmod -R 775 /u01/

8. Edit vi /etc/pam.d/login

session required /lib64/security/pam_limits.so

session required pam_limits.so

9. Remove NTP

/sbin/service ntpd stop

chkconfig ntpd off

mv /etc/ntp.conf /etc/ntp.conf.org

rm /var/run/ntpd.pid

/etc/init.d/avahi-daemon stop

chkconfig avahi-daemon off

10. Configure environment variables

vi .bash_profile

#grid users

ORACLE_SID=+ASM1; export ORACLE_SID

ORACLE_BASE=/u01/app/grid; export ORACLE_BASE

ORACLE_HOME=/u01/app/12.1.0/grid; export ORACLE_HOME

ORACLE_TERM=xterm; export ORACLE_TERM

PATH=$ORACLE_HOME/bin:$PATH; export PATH

LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/usr/local/lib; export LD_LIBRARY_PATH

CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib; export CLASSPATH

export TEMP=/tmp

export TMPDIR=/tmp

#oracle

ORACLE_SID=salmandb1; export ORACLE_SID

ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE

ORACLE_HOME=/u01/app/oracle/product/12.1.0/dbhome_1; export ORACLE_HOME

ORACLE_TERM=xterm; export ORACLE_TERM

PATH=$ORACLE_HOME/bin:$PATH; export PATH

LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/usr/local/lib; export LD_LIBRARY_PATH

CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib; export CLASSPATH

export TEMP=/tmp

export TMPDIR=/tmp

11. Configuration Storage ASM

for i in b c d e f g ;

do

echo "KERNEL==\"sd*\", BUS==\"scsi\", PROGRAM==\"/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/\$name\", RESULT==\"`/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/sd$i`\", NAME=\"asm-disk$i\", OWNER=\"grid\", GROUP=\"asmadmin\", MODE=\"0660\"" >> /etc/udev/rules.d/99-oracle-asmdevices.rules

done

The requested URL/sbin/start_udev was not found on this server.

Then edit: vi /etc/rc.d/rc.local

chown -h grid:asmadmin /dev/asm-diskb

chown -h grid;asmadmin /dev/asm-diskc

chown -h grid:asmadmin /dev/asm-diskd

chown -h grid:asmadmin /dev/asm-diske

chown -h grid:asmadmin /dev/asm-diskf

chown -h grid:asmadmin /dev/asm-diskg

chmod 660 /dev/asm-diskb

chmod 660 /dev/asm-diskc

chmod 660 /dev/asm-diskd

chmod 660 /dev/asm-diske

chmod 660 /dev/asm-diskf

chmod 660 /dev/asm-diskg

vi /etc/sysctl.conf

fs.file-max = 6815744

kernel.sem = 250 32000 100 128

kernel.shmmni = 4096

kernel.shmall = 4294967296

kernel.shmmax = 4398046511104

kernel.panic_on_oops = 1

net.core.rmem_default = 262144

net.core.rmem_max = 4194304

net.core.wmem_default = 262144

net.core.wmem_max = 1048576

fs.aio-max-nr = 1048576

net.ipv4.ip_local_port_range = 9000 65500

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report