• rhel6 安装 oracle11gR2初始化脚本


    说明:此文档为在redhat linux 64bit 上安装oracle11g的初始化shell脚本,执行此脚本成功后即可执行./runInstaller安装。对上一个脚本主要是改变依赖包的安装,详情参考官方文档:http://docs.oracle.com/cd/E11882_01/install.112/e24326/toc.htm#BABIBGFA

    #!/bin/bash
    ################################################################################
    # Description:此脚本为rrhel6环境安装oracle 11g的系统准备工作,需要配置好yum源,
    # 主机名,网络等基本信息
    # 添加的oracle用户默认密码为oracle
    # Author:snaid
    # Email:snaid_x@163.com
    ################################################################################
    #difine oracle_sid
    read -p "Please input your oracle sid that will be install:" ora_sid
    #modify system version
    #echo "Red Hat Enterprise Linux Server release 4.8 (Tikanga)" > /etc/redhat-release
    #install depdent packge
    for i in binutils compat-libcap1 compat-libstdc++-33* gcc gcc-c++ glibc glibc.i686 
    glibc-devel glibc-devel.i686 ksh libgcc libgcc.i686 libstdc++.x86_64 libstdc++.i686 
    libstdc++-devel.i686 libstdc++-devel.x86_64 libaio.x86_64 libaio.i686 
    libaio-devel.i686 libaio-devel.x86_64 make sysstat glibc-devel.i686 
    elfutils-libelf-devel.i686
    do yum -y install $i 2>/dev/null ; done #modify kernel parameter printf "kernel.shmall = 2097152 kernel.shmmax = 2147483648 kernel.shmmni = 4096 kernel.sem = 250 32000 100 128 fs.file-max = 6815744
    fs.aio-max-nr = 1048576 net.ipv4.ip_local_port_range
    = 9000 65000 net.core.rmem_default = 1048576 net.core.rmem_max = 4194304 net.core.wmem_default = 262144 net.core.wmem_max = 1048576 ">> /etc/sysctl.conf /sbin/sysctl -p #adduser /usr/sbin/groupadd -g 1000 oinstall /usr/sbin/groupadd -g 1001 dba /usr/sbin/useradd -u 1000 -g oinstall -G dba oracle echo "oracle"| passwd oracle --stdin > /dev/null 2>&1 #build oracle directory mkdir -p /u01/app/oracle chown -R oracle.oinstall /u01 #oracle environment variable echo export ORACLE_BASE=/u01/app/oracle >> /home/oracle/.bash_profile echo export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1 >> /home/oracle/.bash_profile echo export ORACLE_SID=$ora_sid >> /home/oracle/.bash_profile echo export PATH=$PATH:$HOME/bin:$ORACLE_HOME/bin >> /home/oracle/.bash_profile echo export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib >> /home/oracle/.bash_profile source /home/oracle/.bash_profile #oracle's ulimit printf "oracle soft nproc 2047 oracle hard nproc 16384 oracle soft nofile 1024 oracle hard nofile 65536 " >> /etc/security/limits.conf echo "Please make sure your hostname and host file configure ok."
  • 相关阅读:
    Java读写.properties文件实例,解决中文乱码问题
    web项目的getContextPath()
    PWC6345: There is an error in invoking javac. A full JDK (not just JRE) is required
    Eclipse安装与配置
    Linux基础整理 + 注释
    git命令集合
    遍历List集合的三种方法
    使用jqueryUI和corethink实现的类似百度的搜索提示
    corethink功能模块探索开发(十八)前台页面插入jit前端数据可视化库
    corethink功能模块探索开发(十七)opencmf.php 配置文件
  • 原文地址:https://www.cnblogs.com/snaid/p/3408535.html
Copyright © 2020-2023  润新知