手動安裝oracle軟件 刪軟件

更多博文請關注:沒有傘的孩子必須努力奔跑(www.xuchanggang.cn)html


1.手工刪除oracle軟件:
刪除/etc/ora*
刪除軟件安裝目錄下的全部文件,我這裏是:/u01/app/oracle/*
刪除/usr/local/bin/*

2.命令行下安裝oracle軟件:
(1).編寫應答文件,通常下載的數據庫解壓包中,有應答文件的模板,咱們這裏修改一下便可
數據庫

[oracle@stu135 database]$ pwd     # 個人數據庫解壓後在/tmp/database目錄下
/tmp/database
[oracle@stu135 database]$ ls     #  response目錄爲應答文件所在目錄,進入
doc  install  response  runInstaller  stage  welcome.html
[oracle@stu135 database]$ cd response/
[oracle@stu135 response]$ ls
custom.rsp  dbca.rsp  emca.rsp  enterprise.rsp  netca.rsp  standard.rsp
[oracle@stu135 response]$ cp enterprise.rsp /tmp/database/ent.rsp   # 複製應答文件,並更名
[oracle@stu135 response]$ vim /tmp/database/ent.rsp   # 編輯應答文件
#  主要修改以下參數,其餘參數暫時默認【咱們這裏的安裝,是你們瞭解有這種方法】
UNIX_GROUP_NAME= "oinstall"   # 組名,這個組時咱們本身建的
FROM_LOCATION="/tmp/database/stage/products.xml"    # 指定products.xml路徑,絕對路徑
ORACLE_HOME="/u01/app/oracle/product/10.2.0/db_2"    # 指定oracle產品的安裝目錄
ORACLE_HOME_NAME= "oracle_home2"     # 指定這個數據庫產品的名字,即軟件的名字,方便之後刪除
ORACLE_HOSTNAME= "xcg.xuchanggang.cn"   # 指定本身機器的主機名
COMPONENT_LANGUAGES={"en"}            # 指定語言
INSTALL_TYPE="EE"                # 指定安裝版本,這裏是企業版
s_nameForDBAGrp= "dba"           # 指定DBA組
s_nameForOPERGrp= "dba"          # 指定操做組
n_configurationOption=3        # 指定配置說明,文件中數字表明的含義,都有註釋說明,這裏僅安裝軟件

(2).運行腳本(自帶),就在數據庫解壓目錄下
vim

[oracle@stu135 database]$ ls
doc  ent.rsp  install  response  runInstaller  stage  welcome.html
[oracle@stu135 database]$ ./runInstaller -help   # 若是不知道跟那些參數,能夠用help查詢
# 使用靜默安裝【無交互的】,指定應答文件,忽略系統檢查,此步可省略
[oracle@stu135 database]$ ./runInstaller -responseFile /tmp/database/ent.rsp -ignoreSysPrereqs -silent
Starting Oracle Universal Installer...
Checking installer requirements...
................................................(詳細的安裝過程省略)
Installation in progress (Mon Jun 17 15:32:29 CST 2013)
...............................................................  18% Done.
...............................................................  36% Done.
...............................................................  54% Done.
...............................................................  73% Done.
............                                                     76% Done.
Install successful

(3).安裝完成後,會提示安裝腳本[兩個腳本:orainstRoot.sh / root.sh ],兩個腳本以root用戶身份運行
bash

[root@stu135 db_1]# cd /u01/app/oracle/oraInventory/
[root@stu135 oraInventory]# bash orainstRoot.sh
Changing permissions of /u01/app/oracle/oraInventory to 770.
Changing groupname of /u01/app/oracle/oraInventory to oinstall.
The execution of the script is complete
[root@stu135 oraInventory]# cd /u01/app/oracle/product/10.2.0/db_2/
[root@stu135 db_2]# bash root.sh
Running Oracle10 root.sh script...
The following environment variables are set as:
    ORACLE_OWNER= oracle
    ORACLE_HOME=  /u01/app/oracle/product/10.2.0/db_2
Enter the full pathname of the local bin directory: [/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
yFinished running generic part of root.sh script.
Now product-specific root actions will be performed.

(4).到此,oracle軟件算是安裝成功了,下面就是手動安裝數據庫


oracle

相關文章
相關標籤/搜索