Solaris10下完全解除安裝Oracle1106RAC環境
寫了幾篇關於Oracle RAC環境的安裝,還從來沒有寫過解除安裝Oracle RAC環境的文章,前兩天在測試的時候發現,如果Rac環境無法解除安裝乾淨,很可能再次安裝RAC環境時會碰到錯誤,因此這裡簡單描述一下Oracle RAC環境的解除安裝。
首先解除安裝Oracle資料庫,為了更好的解除安裝資料庫,最好是保證資料庫處於開啟狀態,這樣DBCA就可以根據讀取Oracle資料檔案的資訊並進行刪除。
啟動DBCA圖形介面,選擇Oracle Real Application Cluster database選擇。
選擇Delete a Databasese。
然後選擇FINISH,刪除整個資料庫檔案。
利用NETCA工具刪除監聽設定。
下面執行建立資料庫的圖形介面runInstaller,開始資料庫軟體的解除安裝:
進入WELCOME介面後,直接點選Installed Products,這時會彈出一個對話方塊,在Oracle Homes中有兩個物件:OraCrs11g_home和OraDb11g_home。
在刪除的時候一定要先選擇解除安裝OraDb11g_home,因為還需要執行Cluster目錄下的shell指令碼來清除CLUSTER對作業系統進行的修改,所以OraCrs11g_home的解除安裝放到後面的步驟中進行。
選中OraDb11g_home點選REMOVE即可進行解除安裝。
下面利用CLUSTER目錄下提供的shell來清除CLUSTER系統的所有修改:
在節點2執行:
root@newtrade2 # cd /data/oracle/product/11.1/crs/
root@newtrade2 # . ./install/rootdelete.sh remote nosharedhome -force
Getting local node name
NODE = newtrade2
CRS resources for listeners are still configured.
Getting local node name
NODE = newtrade2
Stopping VIPs that are still up
Getting cluster node names
Cluster Nodes = newtrade1
newtrade2
Stopping vip
Stopping vip
Stopping resources.
This could take several minutes.
Successfully stopped Oracle Clusterware resources
Stopping Cluster Synchronization Services.
Shutting down the Cluster Synchronization Services daemon.
Shutdown request successfully issued.
Waiting for Cluster Synchronization Services daemon to stop
Cluster Synchronization Services daemon has stopped
Oracle CRS stack is not running.
Oracle CRS stack is down now.
Removing script. for Oracle Cluster Ready services
Updating ocr file for downgrade
Cleaning up SCR settings in '/var/opt/oracle/scls_scr'
Cleaning up Network socket directories
在節點1執行:
root@newtrade1 # cd /data/oracle/product/11.1/crs/
root@newtrade1 # . ./install/rootdelete.sh remote nosharedhome -force
Getting local node name
NODE = newtrade1
CRS resources for listeners are still configured.
Getting local node name
NODE = newtrade1
Stopping VIPs that are still up
Getting cluster node names
Cluster Nodes = newtrade1
newtrade2
Stopping vip
Stopping vip
Stopping resources.
This could take several minutes.
Successfully stopped Oracle Clusterware resources
Stopping Cluster Synchronization Services.
Shutting down the Cluster Synchronization Services daemon.
Shutdown request successfully issued.
Waiting for Cluster Synchronization Services daemon to stop
Cluster Synchronization Services daemon has stopped
Oracle CRS stack is not running.
Oracle CRS stack is down now.
Removing script. for Oracle Cluster Ready services
Updating ocr file for downgrade
Cleaning up SCR settings in '/var/opt/oracle/scls_scr'
Cleaning up Network socket directories
在節點1執行:
root@newtrade1 # ./install/rootdeinstall.sh
Verifying existence of ocr.loc file
Removing contents from OCR device
2560+0 records in
2560+0 records out
下面可以利用CLUSTER的安裝程式runInstaller來解除安裝CLUSTER軟體:
進入WELCOME介面後,點選Installed Products,在彈出的對話方塊中選擇OraCrs11g_home,然後點選REMOVE。
最後刪除/var/opt目錄下的Oracle資訊和ORACLE_BASE目錄,在兩個節點分別執行下面的SQL:
root@newtrade1 # rm -rf /data/oracle
root@newtrade1 # rm -rf /var/opt/oracle
刪除/usr/local/bin目錄下的設定:
root@newtrade2 # rm /usr/local/bin/dbhome
root@newtrade2 # rm /usr/local/bin/oraenv
root@newtrade2 # rm /usr/local/bin/coraenv
最後利用作業系統命令檢查一下,系統中是否還殘留一些Oracle的設定:
root@newtrade1 # find / -name oracle
/opt/VRTSvcs/wizards/bin/oracle
/opt/openv/netbackup/ext/db_ext/oracle
/usr/appserver/samples/blueprints/petstore1.4/src/sql/oracle
/usr/appserver/samples/jdbc/apps/simple/setup/sql/oracle
/usr/appserver/samples/security/realms/apps/rdbms/setup/sql/oracle
/export/CFS/MP1/cluster_server_agents/oracle_agent/patches/123670-01/VRTScsocw/reloc/opt/VRTSvcs/wizards/bin/oracle
/export/CFS/veritas/cluster_server_agents/oracle_agent/pkgs/VRTScsocw/reloc/opt/VRTSvcs/wizards/bin/oracle
/export/home/oracle
/data/oracle
這裡的oracle相關目錄和檔案都是其他軟體中所包含的檔案,比如netbackup等。
如果是利用VCM,則可以利用下面的方法清除共享磁碟:
root@newtrade1 # vxassist -g datavg remove volume ocr
root@newtrade1 # vxassist -g datavg remove volume vot
整個Oracle資料庫和RAC環境清除工作至此結束,當然如果願意可以透過userdel和groupdel刪除oracle使用者和oinstall、dba組。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/4227/viewspace-405421/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Airtest 環境搭建之JDK1.8下載安裝&配置&完全解除安裝AIJDK
- linux環境下解除安裝oracle11gLinuxOracle
- Ubuntu下搭建JAVA開發環境及解除安裝UbuntuJava開發環境
- 如何完全解除安裝WSL
- Windows環境下達夢資料庫安裝及解除安裝手冊Windows資料庫
- Linux環境下達夢資料庫安裝及解除安裝手冊Linux資料庫
- Windows 環境下 Python 環境安裝WindowsPython
- 解除安裝windows安裝ubuntu的完全指南WindowsUbuntu
- 如何將Java完全解除安裝Java
- CentOS 7 完全解除安裝PHPCentOSPHP
- [轉]如何完全解除安裝WSL
- 完全解除安裝刪除 GitLabGitlab
- Elementary os完全解除安裝DockerDocker
- 完全解除安裝刪除gitlabGitlab
- Mysql--所有版本安裝以及完全解除安裝MySql
- Linux下安裝Go環境LinuxGo
- docker環境下安裝tensorflowDocker
- linux環境下redis安裝LinuxRedis
- Windows環境下安裝LinuxWindowsLinux
- Windows環境下安裝NexusWindows
- Windows 環境下安裝 RedisWindowsRedis
- Windows 環境下安裝 LaravelWindowsLaravel
- Mac環境下安裝PodMac
- Linux下Java環境安裝LinuxJava
- Windows環境下安裝RabbitMQWindowsMQ
- kali環境下安裝dvwa
- Linux環境下安裝NginxLinuxNginx
- linux或者CentOS環境下安裝.NET Core環境LinuxCentOS
- Debian中完全解除安裝MySQL的方法MySql
- ubuntu環境下安裝perf工具Ubuntu
- Linux環境下nginx安裝配置LinuxNginx
- 在Ubuntu環境下安裝eclipseUbuntuEclipse
- Docker 下安裝配置 lnmp 環境DockerLNMP
- Mac環境下安裝配置RedisMacRedis
- Linux環境下ApacheActiveMQ基本安裝LinuxApacheMQ
- win10怎麼解除安裝cygwin_win10如何完全解除安裝cygwinWin10
- window環境下安裝和切換兩個python環境Python
- WAMPSERVER整合環境下載與安裝Server
- HMMer在Windows環境下的安裝HMMWindows