star帶你玩轉Oracle_2_安裝oracle 10g on Redhat 6.8_orastar
1、實驗目標
問題:由於部分新購伺服器,只支援安裝linux 6.X
矛盾:應用服務只支援Oracle 10g,而Oracle 10g官方只支援 Linux 4
迷茫:Linux 6.X安裝Oracle 10g過程中會遇到較多異常
破解:現整理《安裝oracle 10g on Redhat 6.8》,幫助大家快速安裝Oracle 10g。
2、環境介紹
作業系統 : Redhat 6.8
資料庫版本: Oracle 10.2.0.1>>升級到Oracle 10.2.0.5
虛擬機器 : VMware-workstation-full-11.1.2.61471.1437365244
3、講師介紹
安裝過程如有疑問,歡迎新增微信諮詢。
4、軟體下載
連結: 密碼:ok1o
5、環境搭建
環境搭建部分請參考star之前的文章 《star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC》
Redhat 6.8作業系統_安裝 : http://blog.itpub.net/31442014/viewspace-2138822/
6、作業系統配置
6.1 修改/etc/hosts
root執行指令碼-
cat >> /etc/hosts <<EOF
-
#Public
-
192.168.1.121 oracle10g
- EOF
6.2 修改/etc/redhat-release
Red Hat Enterprise Linux Server release 4.0 (Santiago) 將6.8修改為4.0
6.3 配置YUM
6.3.1 首次掛載報錯
[root@oracle10g ~]# mount /dev/cdrom /mnt
mount: you must specify the filesystem type
6.3.2 處理報錯方法
[root@htdb1 ~]# mount /dev/cdrom /mnt
mount: block device /dev/sr0 is write-protected, mounting read-only
#vi /etc/yum.repos.d/rhel-source.repo --說明: 先清空該檔案,再新增以下內容。 有同學反應,yum無法正常安裝rpm包,因為沒有正常該檔案造成。
[rhel-oracle-lib]
name=oracle
baseurl=file:///mnt
enabled=1
gpgcheck=0
#yum clean all
#yum list |head
6.4 安裝RPM包
root執行指令碼
-
yum install -y binutils compat-db control-center gcc gcc-c++ glibc glibc-common libstdc++ libstdc++-devel make pdksh sysstat
-
-
yum install libXp-1.0.2-2.1.el6.i686.rpm
-
yum install libXp-devel.i686
-
yum install glibc-devel-2.12-1.192.el6.i686.rpm
-
-
[root@oracle10g ~]# cd /mnt/Packages/
-
[root@oracle10g Packages]# rpm -ivh --force libXp-1.0.2-2.1.el6.i686.rpm
-
[root@oracle10g Packages]# yum install –y libXt.i686
-
[root@oracle10g Packages]# yum install –y libXtst.i686
-
[root@oracle10g Packages]# yum install -y libgcc-4.4.7-17.el6.i686.rpm
-
[root@oracle10g soft]# rpm -ivh pdksh-5.2.14-30.x86_64.rpm
-
[root@oracle10g Packages]# yum install -y binutils-devel-2.20.51.0.2-5.44.el6.x86_64.rpm
-
[root@oracle10g Packages]# yum install -y binutils-devel-2.20.51.0.2-5.44.el6.i686.rpm
- [root@oracle10g Packages]# yum install -y compat-libstdc++-33-3.2.3-69.el6.x86_64.rpm [root@oracle10g Packages]# yum install -y compat-libstdc++-33-3.2.3-69.el6.i686.rpm
6.5 關閉防火牆及selinux
root執行指令碼
-
/sbin/iptables -F; /sbin/ip6tables -F
-
/sbin/chkconfig iptables off; /sbin/chkconfig ip6tables off
-
-
/bin/sed -i s/SELINUX=enforcing/SELINUX=disabled/ /etc/selinux/config
- /usr/sbin/setenforce 0
6.6 修改/etc/sysctl.conf引數
cat >> /etc/sysctl.conf
<<EOF
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024
65000
net.core.rmem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_max = 262144
EOF
6.7 修改/etc/security/limits.conf引數
root執行指令碼
cat >> /etc/security/limits.conf
<<EOF
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
EOF
6.8 修改/etc/pam.d/login引數(root執行指令碼)
cat >> /etc/pam.d/login <<EOF
#for oracle
session required pam_limits.so
EOF
6.9 修改/etc/profile引數
root執行指令碼
cat >> /etc/profile <<EOF
#for oracle
if [ \$USER = "oracle" ] || [
\$USER = "grid" ]; then
if [ \$SHELL = "/bin/ksh" ];
then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
fi
EOF
6.10 建立使用者
/usr/sbin/groupadd oinstall
/usr/sbin/groupadd dba
/usr/sbin/useradd -g oinstall -G dba oracle
/bin/echo "oracle"
|/usr/bin/passwd --stdin oracle
6.11 建立目錄
root執行指令碼
mkdir -p /u01/app/oracle
chown -R oracle:oinstall
/u01/app/oracle
chmod -R 775 /u01/app/oracle
6.12 修改環境變數
root執行指令碼
ORACLE使用者:
cat >> /home/oracle/.bash_profile
<<EOF
export ORACLE_BASE=/u01/app/oracle
export
ORACLE_HOME=\$ORACLE_BASE/product/11.2.0/db_1
export ORACLE_SID=oracle10g
export
NLS_LANG=AMERICAN_AMERICA.AL32UTF8
export
LD_LIBRARY_PATH=\$ORACLE_HOME/lib
export
PATH=\$ORACLE_HOME/OPatch:\$ORACLE_HOME/bin:\$PATH
umask=022
EOF
6.13 修改hugetlb_shm_group
將oracle的dba組的gid寫入/proc/sys/vm/hugetld_shm_group檔案中
[root@oracle10g Packages]# id oracle
uid=500(oracle) gid=500(oinstall) groups=500(oinstall),501(dba)
[root@oracle10g Packages]# cat /proc/sys/vm/hugetlb_shm_group
0
[root@oracle10g Packages]# echo vm.hugetlb_shm_group=500 >> /etc/sysctl.conf
[root@oracle10g Packages]# sysctl -p
7、上傳解壓安裝檔案
建立軟體上傳目錄
[root@oracle10g u01]# mkdir -p /u01/soft
[root@oracle10g u01]# chown -R oracle:oinstall /u01/soft
檢視上傳軟體
[oracle@oracle10g soft]$ ls -ltr
total 1961236
-rw-r--r--. 1 oracle oinstall 758433170 May 17 11:17 10201_database_linux_x86_64.cpio.gz
-rw-r--r--. 1 oracle oinstall 1249857866 May 17 11:19 p8202632_10205_Linux-x86-64.zip
解壓安裝檔案
1. gunzip 10201_database_linux_x86_64.cpio.gz
得到10201_database_linux_x86_64.cpio檔案
2. cpio -idmv <10201_database_linux_x86_64.cpio
8、重啟資料庫伺服器
安裝資料庫前重啟資料庫伺服器
reboot
9、安裝10.2.0.1
以oracle賬號登陸作業系統(不要使用su oracle或su – oracle,直接使用oracle登陸)
[oracle@oracle10g soft]$ export DISPLAY=192.168.1.11:0.0
[oracle@oracle10g database]$ ./runInstaller9.1 問題解決'collector' ins_emdb.mk:
Exception String: Error in invoking target 'collector' of makefile '/u01/app/oracle/product/11.2.0/db_1/sysman/lib/ins_emdb.mk'
1. The
popup error concerning the linking of target "collector" at about 83%
of the linking process of the 10.2.0.1 base-release install should be ignored.
2. Apply 10.2.0.4 or 10.2.0.5 patchset
參考文件:
Install Of 10.2.0.1 On SLES 11 X86-64 Fails with Error:"Error In Invoking Target 'Collector' Of Makefile '$ORACLE_HOME/sysman/lib/ins_emdb.mk'" (Doc ID 957982.1)
分別使用root賬號,執行以下指令碼
10、升級10.2.0.5
[root@oracle10g soft]# chown oracle:oinstall p8202632_10205_Linux-x86-64.zip
[oracle@oracle10g soft]$ unzip p8202632_10205_Linux-x86-64.zip
[oracle@oracle10g soft]$ cd Disk1/
[oracle@oracle10g Disk1]$ ls
install patch_note.htm response runInstaller stage
[oracle@oracle10g Disk1]$ ./runInstaller使用root賬號,執行以下指令碼
點選exit
11、建立例項
請參考star同學以下文件,
http://blog.itpub.net/31442014/viewspace-2138838/ 21、建立資料庫例項恭喜大家,順利在linux 6 上安裝oracle 10G。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/31442014/viewspace-2139266/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- star帶你玩轉postgre資料庫_1_postgre安裝資料庫
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(1/8)-orastarOracleAST
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(2/8)-orastarOracleAST
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(3/8)-orastarOracleAST
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(4/8)-orastaOracleAST
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(5/8)-orastaOracleAST
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(6/8)-orastaOracleAST
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(7/8)-orastaOracleAST
- star帶你玩轉Oracle-零基礎openfiler共享儲存安裝Oracle 11G RAC-(8/8)-orastaOracleAST
- Redhat AS 4安裝Oracle 10g 10.2.0.3.0RedhatOracle 10g
- RedHat 5.1上安裝Oracle 10g 注意事項RedhatOracle 10g
- redhat as5 安裝 oracle 10g注意事項RedhatOracle 10g
- oracle 10G RAC for redhat as5.3 安裝說明Oracle 10gRedhat
- (轉)redhat下安裝oracle,設定redhat核心引數RedhatOracle
- Redhat 5.4 + ASM + RAW+ Oracle 10g RAC 安裝文件RedhatASMOracle 10g
- RedHat Enterprice Linux 5.4 下安裝Oracle 10gRedhatLinuxOracle 10g
- 在RedHat LInux5上安裝Oracle 10g dbRedhatLinuxOracle 10g
- 公司環境redhat as5 安裝Oracle 10g的文件RedhatOracle 10g
- 在RedHat Linux下安裝惠普磁帶機(轉)RedhatLinux
- 在Redhat 9上安裝 Oracle 817心(轉)RedhatOracle
- 【轉】redhat 5 安裝oracle10g方法RedhatOracle
- 帶你重新“玩轉”FlutterFlutter
- 三步帶你玩轉前端裝飾器前端
- oracle 10g rac for linux redhat 5.3 安裝常見問題Oracle 10gLinuxRedhat
- Oracle 10g for Redhat Enterprise Server 5資料庫安裝Oracle 10gRedhatServer資料庫
- 在RedHat EL AS 3上安裝Oracle9.2.0(轉)RedhatOracle
- RedHat7.0下Oracle 8.1.6安裝例項(轉)RedhatOracle
- [轉]win7安裝和解除安裝oracle 10GWin7Oracle
- RedHat9.0操作的oracle9i安裝(轉)RedhatOracle
- [轉]redhat AS 5安裝ORACLE10g客戶端RedhatOracle客戶端
- oracle 10g rac 安裝好文章(轉)Oracle 10g
- 安裝Oracle 10g 的艱難之旅(轉)Oracle 10g
- Oracle 10g for Solaris x86安裝(轉)Oracle 10g
- 新霸哥帶你輕鬆玩轉Oracle資料庫Oracle資料庫
- 在redhat5.6上安裝oracle 10g(簡單基礎步驟)RedhatOracle 10g
- CryptAssist-帶你玩轉幣圈
- redhat自帶apache2.0和tomcat4.1的安裝(轉)RedhatApacheTomcat
- Redhat+Oracle+SAP Netweaver 安裝RedhatOracle