在Debian 上安裝 Oracle 11gR2

來源:互聯網
上載者:User

大家好!

今天總監要我幫忙安裝Oracle資料庫,當我登入上去發現和平時的不太一樣,原來是debian系統,這個還真沒安裝過oracle,趕快去官方文檔尋找安裝手冊,居然沒有,只能按照linux的安裝啦!

1.安裝vncserver

root@db100:/etc/apt#apt-get install vnc4server

如果報:E: Unable to locate package  vnc4server 錯誤,

則執行root@db100:/etc/apt#apt-get update後,

重新執行root@db100:/etc/apt#apt-get install vnc4server

輸入vnc密碼:終端輸入  vncpasswd  ,提示輸入密碼即可

配置vncserver自動啟動:

vi /etc/init.d/vncserver

#! /bin/sh
export USER="root"
export PATH="/usr/local/bin:/usr/bin:/bin:/usr/bin/X11"
NAME=vncstart
start()
{
    su - $USER -c"vncserver :5"
}
stop()
{
    su - $USER -c"vncserver -clean -kill :1"
}
case "$1" in
    start)
        echo -n "Starting Xvnc: "
        start
        ;;
    stop)
        echo -n "Stopping Xvnc "
        stop
        ;;
    restart)
        echo -n "Restarting Xvnc "
        stop
        start
        ;;
****)
        echo "Usage: /etc/init.d/$NAME {start|stop|restart}"
        exit 1
        ;;
esac
exit 0

 

儲存,設定為可執行,並加入到服務列表

chmod +x /etc/init.d/vncserver
update-rc.d vncserver defaults 98

 

2.安裝rpm,unzip等oracle需要的包

root@db100:/etc/apt# apt-get install unzip  rpm gawk

 

3.建立oracle使用者和組

 addgroup oinstall
 addgroup dba
 addgroup nobody
 useradd -g oinstall -G dba -p oracle -s /bin/bash -d /home/oracle -m oracle
 usermod -g nobody nobody

  • 1
  • 2
  • 3
  • 下一頁

相關文章

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.