zoukankan      html  css  js  c++  java
  • Oracle 11g软件安装

         一 软件环境
    • CentOS-6.5-x86_64
    • p13390677_112040_Linux-x86-64
    • 主机名称设置为sz.pri.com,IP为192.168.1.106

         二 主机设置

    内存要求
    安装Oracle 11g,内存至少是1GB,建议在2GB以上。
    磁盘空间要求
    企业版
      • 软件文件空间4.7GB
      • 数据文件空间1.7GB
    标准版
      • 软件文件空间4.6GB
      • 数据文件空间1.5GB
    设置主机名称
    [root@sz ~]# more /etc/hosts
    127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
    ::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
    192.168.1.106 sz.pri.com
    [root@strong ~]# more /etc/sysconfig/network
    NETWORKING=yes
    HOSTNAME=sz.pri.com
    配置网络地址
    [root@sz ~]# more /etc/sysconfig/network-scripts/ifcfg-eth0
    TYPE=Ethernet
    BOOTPROTO=none
    DEFROUTE=yes
    IPV4_FAILURE_FATAL=yes
    IPV6INIT=no
    NAME=eth0
    UUID=24a8cd87-567c-4247-937a-705e7d705328
    ONBOOT=yes
    IPADDR=192.168.1.106
    PREFIX=24
    GATEWAY=192.168.1.1
    DNS1=192.168.1.1
    LAST_CONNECT=1504533914
    [root@sz ~]# service network restart
    Shutting down loopback interface: [ OK ]
    Bringing up loopback interface: [ OK ]
    Bringing up interface eth0: Active connection state: activated
    Active connection path: /org/freedesktop/NetworkManager/ActiveConnection/4
    [ OK ]
    配置本地YUM源
    配置本地YUM源,为安装Oracle 11g所需的rpm做准备
    [root@sz ~]# umount /dev/cdrom
    [root@sz ~]# mount /dev/cdrom /mnt/
    mount: block device /dev/sr0 is write-protected, mounting read-only
    [root@sz ~]# cd /etc/yum.repos.d/
    [root@sz yum.repos.d]# ls
    CentOS-Base.repo CentOS-Debuginfo.repo CentOS-Media.repo CentOS-Vault.repo
    [root@sz yum.repos.d]# mv CentOS-Base.repo CentOS-Base.repo.bak
    [root@sz yum.repos.d]# vim CentOS-Media.repo
    
    # CentOS-Media.repo
    #
    # This repo can be used with mounted DVD media, verify the mount point for
    # CentOS-6. You can use this repo and yum to install items directly off the
    # DVD ISO that we release.
    #
    # To use this repo, put in your DVD and use it with the other repos too:
    # yum --enablerepo=c6-media [command]
    #
    # or for ONLY the media repo, do this:
    #
    # yum --disablerepo=* --enablerepo=c6-media [command]
    
    [c6-media]
    name=CentOS-$releasever - Media
    baseurl=file:///mnt/
    gpgcheck=1
    enabled=1
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6
    [root@sz yum.repos.d]# yum clean all
    Loaded plugins: fastestmirror, refresh-packagekit, security
    Cleaning repos: c6-media
    Cleaning up Everything
    Cleaning up list of fastest mirrors
    [root@sz yum.repos.d]# yum list
    安装xterm和xclock
    [root@sz yum.repos.d]# yum install xterm
    [root@sz yum.repos.d]# yum install xclock
    安装Oracle 11g所需的Package
    下面的Packages时安装Oracle 11g所需的,利用yum install 进行安装。
    binutils-2.20.51.0.2-5.11.el6 (x86_64)
    compat-libcap1-1.10-1 (x86_64)
    compat-libstdc++-33-3.2.3-69.el6 (x86_64)
    compat-libstdc++-33-3.2.3-69.el6.i686
    gcc-4.4.4-13.el6 (x86_64)
    gcc-c++-4.4.4-13.el6 (x86_64)
    glibc-2.12-1.7.el6 (i686)
    glibc-2.12-1.7.el6 (x86_64)
    glibc-devel-2.12-1.7.el6 (x86_64)
    glibc-devel-2.12-1.7.el6.i686
    ksh
    libgcc-4.4.4-13.el6 (i686)
    libgcc-4.4.4-13.el6 (x86_64)
    libstdc++-4.4.4-13.el6 (x86_64)
    libstdc++-4.4.4-13.el6.i686
    libstdc++-devel-4.4.4-13.el6 (x86_64)
    libstdc++-devel-4.4.4-13.el6.i686
    libaio-0.3.107-10.el6 (x86_64)
    libaio-0.3.107-10.el6.i686
    libaio-devel-0.3.107-10.el6 (x86_64)
    libaio-devel-0.3.107-10.el6.i686
    make-3.81-19.el6
    sysstat-9.0.4-11.el6 (x86_64)
     
    elfutils-libelf-devel-0.125
    或者利用下面的方式进行安装:
    yum -y install binutils compat-libcap1 compat-libstdc* gcc gcc-c++* glibc glibc-devel ksh libgcc libstdc libaio libaio-devel make elfutils-libelf-devel sysstat
    创建Oracle用户和组
    [root@sz yum.repos.d]# groupadd oinstall
    [root@sz yum.repos.d]# groupadd dba
    [root@sz yum.repos.d]# groupadd oper
    [root@sz yum.repos.d]# useradd -g oinstall -G dba,oper oracle
    [root@sz yum.repos.d]# passwd oracle
    Changing password for user oracle.
    New password:
    BAD PASSWORD: it is based on a dictionary word
    BAD PASSWORD: is too simple
    Retype new password:
    passwd: all authentication tokens updated successfully.
    [root@sz yum.repos.d]#
    配置内核参数
    [root@sz yum.repos.d]# vim /etc/sysctl.conf
    fs.aio-max-nr = 1048576
    fs.file-max = 6815744
    kernel.shmmni = 4096
    kernel.sem = 250 32000 100 128
    net.ipv4.ip_local_port_range = 9000 65500
    net.core.rmem_default = 262144
    net.core.rmem_max = 4194304
    net.core.wmem_default = 262144
    net.core.wmem_max = 1048576
    [root@sz yum.repos.d]# sysctl -p ##使上面的命令生效
    [root@sz yum.repos.d]# vim /etc/security/limits.conf
    oracle          soft    nproc  2047
    oracle          hard    nproc  16384
    oracle          soft    nofile  1024
    oracle          hard    nofile  65536
    创建目录
    [root@sz yum.repos.d]# mkdir /u01/app/
    [root@sz yum.repos.d]# chown -R oracle:oinstall /u01/
    [root@sz yum.repos.d]# chmod -R 775 /u01/
    配置Oracle用户环境变量
    [oracle@sz ~]$ vim ./.bash_profile
    ORACLE_BASE=/u01/app/oracle
    ORACLE_SID=szpri
    export ORACLE_BASE ORACLE_SID
    [oracle@sz ~]$ . ./.bash_profile
    [oracle@sz ~]$ echo $ORACLE_SID
    szpri
    解压缩Oracle软件
    [oracle@sz ~]$ mkdir /u01/soft/
    [oracle@sz ~]$ cd /u01/soft/
    [oracle@sz soft]$ ls
    p13390677_112040_Linux-x86-64_1of7.zip  p13390677_112040_Linux-x86-64_2of7.zip
    [oracle@sz soft]$ unzip p13390677_112040_Linux-x86-64_1of7.zip
    [oracle@sz soft]$ unzip p13390677_112040_Linux-x86-64_2of7.zip

    三 Oracle软件安装


    切换到下面目录进行安装
    [oracle@sz soft]$ cd database/
    [oracle@sz database]$ ls
    install readme.html response rpm runInstaller sshsetup stage welcome.html
    [oracle@sz database]$ ./runInstaller
    安装详细步骤
    1、配置安全更新页,输入Email和My Oracle Support Password,在此去掉勾选,点击Next;
          
    2、在下载软件更新页,选择Skip software updates,并点击Next进入下一页;
          
    3、在选择安装选项页,有三种选项,在此我选择Install database software only,并点击Next进入下一页;
          
    4、在网格安装选项页,保持默认选项,我们选择单实例数据库安装,并点击Next进入下一页;
          
    5、在语言选项页,选择English,并点击Next进入下一页;
          
    6、在数据库版本选项页,选择Enterprise Edition,并点击Next进入下一页;
          
    7、在安装位置选项页,保持默认选项,并点击Next进入下一页;
          
    8、在创建库选项页,保持默认选项,并点击Next进入下一页;
          
    9、在操作系统组选项页,保持默认选项,并点击Next进入下一页;
          
    10、在先决条件检查页进行检查,检查结束并点击Next进入下一页;
          
          先决条件检查出现一个不通过的,可以去网上下载对应的Package,该Package对数据库的使用没太大影响,可忽略。
    This is a prerequisite condition to test whether the package "pdksh-5.2.14" is available on the system. (more details)
    Expected Value
     : pdksh-5.2.14
    Actual Value
     : missing
    11、在概要页,显示一些与安装相关的信息,点击Install进行安装;
          
    12、在安装产品页,进行软件的安装,安装结束后,出现执行配置脚本页;
          
          按照上面的提示,执行对应的脚本:
    [root@sz ~]# /u01/app/oraInventory/orainstRoot.sh
    Changing permissions of /u01/app/oraInventory.
    Adding read,write permissions for group.
    Removing read,write,execute permissions for world.

    Changing groupname of /u01/app/oraInventory to oinstall.
    The execution of the script is complete.
    [root@sz ~]# /u01/app/oracle/product/11.2.0/dbhome_1/root.sh
    Performing root user operation for Oracle 11g

    The following environment variables are set as:
    ORACLE_OWNER= oracle
    ORACLE_HOME= /u01/app/oracle/product/11.2.0/dbhome_1

    Enter the full pathname of the local bin directory: [/usr/local/bin]:
    Copying dbhome to /usr/local/bin ...
    Copying oraenv to /usr/local/bin ...
    Copying coraenv to /usr/local/bin ...

    Creating /etc/oratab file...
    Entries will be added to the /etc/oratab file as needed by
    Database Configuration Assistant when a database is created
    Finished running generic part of root script.
    Now product-specific root actions will be performed.
    Finished product-specific root actions.
    [root@sz ~]#

    13、上述步骤完成后,点击Close安装结束;

    14、修改环境变量设置,完成最终数据库软件的安装。
    [oracle@sz ~]$ vim ./.bash_profile
    ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1
    PATH=$ORACLE_HOME/bin:$PATH
    export ORACLE_HOME PATH



  • 相关阅读:
    UnityEngine中Animator相关类的说明
    MecanimControl插件随笔
    Mecanim Control
    Unity3D
    Unity Mecanim在大型mmo中的应用
    Unity3D 性能优化
    Unity3D 图形优化
    U3D开发性能优化笔记(待增加版本.x)
    通过JS语句判断WEB网站的访问端是电脑还是手机
    jquery 鼠标事件汇总
  • 原文地址:https://www.cnblogs.com/alen-liu-sz/p/12975721.html
Copyright © 2011-2022 走看看