您好,登錄后才能下訂單哦!
費(fèi)勁周折啊,之前在RedHat5.9上安裝過(guò),當(dāng)時(shí)非常順利的安裝下來(lái)了 ,結(jié)果這一次沒(méi)想到啊。。。。所以將安裝的過(guò)程寫(xiě)下來(lái),讓大家避免重蹈覆轍。
安裝前,什么都不敢也得把所需要的安裝包一次性安裝上去。很重要,不然后面總是報(bào)錯(cuò)。還有在安裝之前我就有一個(gè)疑問(wèn),安裝oracle還需要安裝java虛擬機(jī)嗎?開(kāi)始一直以為報(bào)些莫名其妙的錯(cuò)誤,難道和jdk有關(guān)系。后來(lái)查資料發(fā)現(xiàn)oracle公司自從oracle8i的版本開(kāi)始,就已經(jīng)將jdk集成到數(shù)據(jù)庫(kù)中去了,不用單獨(dú)在進(jìn)行安裝jdk了。
安裝開(kāi)始:
yum install binutils
yum install compat-libcap1
yum install compat-libstdc++(x86_64)
yum install compat-libstdc++(i686)
yum install gcc
yum install gcc-c++
yum install glibc(x86_64)
yum install glibc(i686)
yum install glibc-devel(x86_64)
yum install glibc-devel(i686)
yum install ksh
yum install libgcc(x86_64)
yum install libgcc(i686)
yum install libstdc++(x86_64)
yum install libstdc++(i686)
yum install libstdc++-devel(x86_64)
yum install libstdc++-devel(i686)
yum install libaio(x86_64)
yum install libaio(i686)
yum install libaio-devel(x86_64)
yum install libaio-devel(i686)
yum install make
yum install sysstat
yum install libXp(x86_64)
yum isntall libXp(i686)
yum -y install binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-devel glibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat
1、建立賬戶(hù)和群組
groupadd dba
groupadd oinstall
useradd -m -g oinstall -G dba oracle
passwd oracle
2、內(nèi)核優(yōu)化參數(shù)
vi /etc/sysctl.conf
kernel.shmall = 4294967296
kernel.shmmax = 68719476736
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default=4194304
net.core.rmem_max=4194304
net.core.wmem_default=262144
net.core.wmem_max=262144
3、資源限制
vi /etc/security/limits.conf
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
4、讓limits.conf里面添加的內(nèi)容可以生效
vi /etc/pam.d/login
session required /lib64/security/pam_limits.so
session required pam_limits.so
5、系統(tǒng)環(huán)境
vi /etc/profile
if [ $USER = "oracle" ]; then
if [ $SHELL = "/bin/ksh" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
fi
6、創(chuàng)建目錄
mkdir /app/oracle -pv
mkdir /app/oracle/10.2/
chown -R oracle:dba /app/oracle
7、IP映射
vi /etc/hosts
192.168.2.27 DB1.centos.org
127.0.0.1 localhost
8、oracle用戶(hù)環(huán)境變量
vi /home/oracle/.bash_profile
export TMP=/tmp
export TMPDIR=$TMP
export ORACLE_BASE=/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/10.2/db_1
export ORACLE_SID=orcl
export ORACLE_TERM=xterm
export PATH=/usr/sbin:$PATH
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib:$ORACLE_HOME/network/jlib
export DISPLAY=:0.0
export NLS_LANG="SIMPLIFIED CHINESE_CHINA".ZHS16GBK
9、上傳后解壓命令
gunzip 10201_database_linux_x86_64.cpio.gz
cpio -idmv <10201_database_linux_x86_64.cpio
10、解壓完事后,更改database目錄的屬性
chown -R oracle.oinstall database/
chmod -R 755 database/
安裝過(guò)程會(huì)報(bào)錯(cuò)了:
ORA-27125
解決方法:在/etc/sysctl.conf中添加一個(gè)參數(shù)
vm.hugetlb_shm_group = dba的組號(hào)(id oracle會(huì)得到需要的參數(shù)值)
安裝完成后,在/app/oracle/product/10.2/db_1/bin/relink all
去解決oracle的第一個(gè)報(bào)錯(cuò)。emk.的錯(cuò)誤。
免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如果涉及侵權(quán)請(qǐng)聯(lián)系站長(zhǎng)郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。