centos6 下安装 Oracle 11g

默北 Oracle614,0083字数 2309阅读7分41秒阅读模式

配置VNC Server

# yum install tigervnc-server
# yum groupinstall  "General Purpose Desktop" "Desktop Platform"
# yum install xorg-x11-server-utils

配置VNC server

# vim /etc/sysconfig/vncservers 
VNCSERVERS="2:root"
VNCSERVERARGS[2]="-geometry 1440x900"
# vncpasswd  设置vnc用户root的密码
# vim ~/.vnc/xstartup
#!/bin/sh

[ -r /etc/sysconfig/i18n ] && . /etc/sysconfig/i18n
export LANG
export SYSFONT
vncconfig -iconic &
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
OS=`uname -s`
if [ $OS = 'Linux' ]; then
 case "$WINDOWMANAGER" in
 *gnome*)
 if [ -e /etc/SuSE-release ]; then
 PATH=$PATH:/opt/gnome/bin
 export PATH
 fi
 ;;
 esac
fi
if [ -x /etc/X11/xinit/xinitrc ]; then
 exec /etc/X11/xinit/xinitrc
fi
if [ -f /etc/X11/xinit/xinitrc ]; then
 exec sh /etc/X11/xinit/xinitrc
fi
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
#xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
#twm &    这两行要注释掉,否则黑屏

exec gnome-session &

# /etc/init.d/vncserver restart  重启服务

验证VNC

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

安装Oracle

依赖包文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

Oracle依赖太多的包,具体的可以参见下Oracle安装文档。我们可以通过Oracle的yum仓库来解决这些依赖关系。文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

下载Oracle公开yum文件文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

RHEL/CentOs 6.x
# cd /etc/yum.repos.d
# wget https://public-yum.oracle.com/public-yum-ol6.repo
# wget https://public-yum.oracle.com/RPM-GPG-KEY-oracle-ol6 -O /etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
RHEL/CentOs 5.x
# cd /etc/yum.repos.d
# wget https://public-yum.oracle.com/public-yum-el5.repo
# wget https://public-yum.oracle.com/RPM-GPG-KEY-oracle-el5 -O /etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
RHEL/CentOs 4.x
# cd /etc/yum.repos.d
# wget https://public-yum.oracle.com/public-yum-el4.repo
# wget https://public-yum.oracle.com/RPM-GPG-KEY-oracle-el4 -O /usr/share/rhn/RPM-GPG-KEY-oracle

安装必需的包:文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

# yum install oracle-rdbms-server-11gR2-preinstall

设置环境变量文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

# vim /etc/hosts
10.0.121.232  ttlsa_db1

# groupadd oinstall
# groupadd dba
# useradd -g oinstall -G dba oracle
# passwd oracle
# vim /etc/security/limits.conf 
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
oracle soft stack 10240

# su - oracle
# vim .bash_profile
export ORACLE_BASE=/data/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1
export ORACLE_SID=orcl
export ORACLE_OWNER=oracle
export PATH=$PATH:$ORACLE_HOME/bin:$HOME/bin

# mkdir /data/app
# chown -R oracle:oinstall /data/app

开始安装文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle
文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

 文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

 文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

# wget ftp://ftp.pbone.net/mirror/www.whiteboxlinux.org/whitebox/4/en/os/x86_64/WhiteBox/RPMS/pdksh-5.2.14-30.x86_64.rpm
# rpm -ivh pdksh-5.2.14-30.x86_64.rpm

大部分是过时的包,可以忽略掉。不过有个包pdksh要安装。show succeeded看看这些包有没安装。文章源自运维生存时间-https://www.ttlsa.com/oracle/centos6-install-oracle-11g/

oracle

保存Response File, 静默安装时候有用。

oracle

oracle

oracle

oracle

设置SYS用户密码

oracle

运行下面的脚本

oracle

oracle

oracle

web界面

oracle

 

至此Oracle 11g安装完成。

weinxin
我的微信
微信公众号
扫一扫关注运维生存时间公众号,获取最新技术文章~
默北
  • 本文由 发表于 25/08/2014 06:00:16
  • 转载请务必保留本文链接:https://www.ttlsa.com/oracle/centos6-install-oracle-11g/
评论  6  访客  6
    • Dream
      Dream 9

      xstartup文件 记得加执行权限

      • haha
        haha 2

        猴赛雷啊 ,不错

          • 默北
            默北

            @ haha comment” />

              • haha
                haha 2

                @ 默北 comment” /> comment” /> comment” />

                  • 默北
                    默北

                    @ haha 粤语都会说

                • 运维生存时间
                  运维生存时间 7

                  @ haha 小杨是吧

              评论已关闭!