Oracle 圖形化以及命令列安裝

來源:互聯網
上載者:User

Oracle 圖形化以及命令列安裝
Oracle 安裝相關版本說明

不同版本的Oracle需要安裝在特定的系統版本之上。
如Oracle 11gR2的11.2.0.1.0需要安裝在CentOS 5.X以及RHLE 5.X

硬體要求
Physical Memory >= 1GSwap Space  >= 2G (available)Temporary Space >= 400MB
依賴庫的安裝
yum -y install binutils compat-libstdc++ compat-libstdc++-33 elfutils-libelf-devel gcc gcc-c++ glibc-devel glibc-headers ksh libaio-devel libstdc++-devel make sysstat unixODBC-devel binutils-* compat-libstdc++* elfutils-libelf* glibc* gcc-* libaio* libgcc* libstdc++* make* sysstat*  unixODBC*rpm -e kshyum install pdksh
相關參數設定

vi /etc/sysctl.conf

# Oracle Configurationkernel.shmall = 2097152kernel.shmmax = 2147483648kernel.shmmni = 4096# semaphors: semmsl, semmns, semopm, semmnikernel.sem = 250 32000 100 128net.core.rmem_default=262144net.core.wmem_default=262144fs.file-max = 6815744net.ipv4.ip_local_port_range = 9000 65500net.core.rmem_max = 4194304net.core.wmem_max = 1048576# Oracle Configuration Endecho "1048576" >/proc/sys/fs/aio-max-nr
Oracle使用者

首先建立Oracle使用者,在該使用者下進行安裝
建立步驟(需要具有root許可權):

$/usr/sbin/groupadd oinstall$/usr/sbin/groupadd dba$useradd –g oinstall -G dba -d /home/oracle -r oracle$mkdir -p /home/oracle$chown oracle:dba /home/oracle$passwd oracle

使用id命令查看使用者資訊
$id oracle
輸出:
uid=504(oracle) gid=500(oinstall) groups=500(oinstall),501(dba)
其中具體id資料可以不一樣

Oracle安裝

註:Oracle檢查條件中:hard limit for maximum open file descriptors is set to at least 65536可以忽略

後續根據安裝步驟進行即可

listener.ora配置
SID_LIST_LISTENER =  (SID_LIST =    (SID_DESC =      (SID_NAME = PLSExtProc)      (ORACLE_HOME = /bank/oracle/oracle10g/product/10.2.0)      (PROGRAM = extproc)    )    (SID_DESC =      (GLOBAL DBNAME = orcl)       (SID_NAME = orcl)    )  )LISTENER =  (DESCRIPTION_LIST =    (DESCRIPTION =      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))      (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))    )  )
命令列安裝初始化配置配置db_install.rsp檔案安裝
./runInstaller -responseFile /home/oracle/database/response/db_install.rsp -silent -showProgress
Q&A
  • 問題:[FATAL] [INS-32037] The operating system group specified for central inventory (oraInventory) ownership is invalid.
    解決:
    設定具有寫oraInventory許可權的組
    UNIX_GROUP_NAME=oinstall
    INVENTORY_LOCATION=/home/oracle/oraInventory
  • 問題:[FATAL] [INS-35071] Global database name cannot be left blank.
    解決:ORACLE_HOSTNAME=oracle1
  • [FATAL] [INS-35071] Global database name cannot be left blank.
    解決如:oracle.install.db.config.starterdb.globalDBName=oracle.sunyard
    *問題: [FATAL] [INS-35175] No value given for the allocated memory of the database
    解決:oracle.install.db.config.starterdb.memoryLimit=512
    [FATAL] [INS-30501] Automatic Storage Management software is not configured on this system.
    配置Oracle儲存方式
  • 問題:[FATAL] [INS-30004] The ADMIN password entered is invalid.
    解決:密碼不能帶@
  • [FATAL] [INS-35341] User is not a member of the following chosen OS groups
    解決:
    oracle.install.db.DBA_GROUP=dba
    oracle.install.db.OPER_GROUP=oinstall

  • 問題:sqlplus: error while loading shared libraries: libsqlplus.so: cannot open shared object file: No such file or directory
    解決:設定如下設定檔

    # .bash_profileif [ -f ~/.bashrc ]; then        . ~/.bashrcfi# for oracle iPATH=$PATH:$HOME/bin#oracle add export ORACLE_BASE=/home/oracle/app/oracleexport ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1export ORACLE_SID=orclexport PATH=$ORACLE_HOME/bin:$PATHexport LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH
  • 問題:ORA-xxxxx: Message xxx not found; no message file for product=RDBMS, facility=ORA
    解決:沒有正確設定ORACLE_HOME路徑,如app/oracle,需要設定為/home/oracle/app/oracle
  • 問題:sqlplus: error while loading shared libraries: /home/oracle/app/oracle/product/11.2.0/dbhome_1/lib/libclntsh.so.11.1: cannot restore segment prot after reloc: Permission denied

    /etc/sysconfig/selinux 中改為SELINUX=disabled chcon -t texrel_shlib_t $ORACLE_HOME/lib/*.so

參考:
Oracle文檔中的Oracle RAC先決條件部分:
http://docs.oracle.com/cd/B28359_01/nav/portal_6.htm
Oracle版本以及對應安裝系統:
http://docs.oracle.com/cd/E11882_01/relnotes.112/e23558/toc.htm#CHDHCEFI

CentOS和RedHat發行版與Linux核心版本的對應關係:

部分操作參考:



http://www.tldp.org/LDP/solrhe/Securing-Optimizing-Linux-RH-Edition-v1.3/chap6sec72.html

Oracle 11g 在RedHat Linux 5.8_x64平台的安裝手冊

Linux-6-64下安裝Oracle 12C筆記

在CentOS 6.4下安裝Oracle 11gR2(x64)

Oracle 11gR2 在VMWare虛擬機器中安裝步驟

Debian 下 安裝 Oracle 11g XE R2

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.