刪除Linux非rac環境下的ASM例項
我的一臺測試機上執行ASM例項,現在需要測試檔案系統的資料庫,需要刪除ASM例項,下面演示刪除ASM例項的過程:
環境說明:
作業系統:CentOS 5 x86
資料庫:Oracle 10.2.0.1 非RAC環境
ASM例項名:+ASM
參考:metalink node:311350.1
[@more@]1、檢查ASM例項程式
ora_test@oracle[/home/oracle]> ps -ef|grep asm|grep -v grep oracle 4263 1 0 Jan20 ? 00:00:02 asm_pmon_+ASM oracle 4265 1 0 Jan20 ? 00:00:00 asm_psp0_+ASM oracle 4267 1 0 Jan20 ? 00:00:00 asm_mman_+ASM oracle 4269 1 0 Jan20 ? 00:00:00 asm_dbw0_+ASM oracle 4271 1 0 Jan20 ? 00:00:00 asm_lgwr_+ASM oracle 4273 1 0 Jan20 ? 00:00:00 asm_ckpt_+ASM oracle 4275 1 0 Jan20 ? 00:00:00 asm_smon_+ASM oracle 4277 1 0 Jan20 ? 00:00:00 asm_rbal_+ASM oracle 4279 1 0 Jan20 ? 00:00:06 asm_gmon_+ASM |
2、設定ASM例項名
ora_test@oracle[/home/oracle]> export ORACLE_SID=+ASM |
3、檢查是否有例項在使用ASM
ora_test@oracle[/home/oracle]> sqlplus / as sysdba SQL*Plus: Release 10.2.0.1.0 - Production on Thu Jan 21 08:44:03 2010 Copyright (c) 1982, 2005, Oracle. All rights reserved. Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production With the Partitioning, OLAP and Data Mining options idle> select instance_name from v$asm_client; no rows selected |
如果有例項在使用ASM,需要首先停止這些相關的例項,並備份相關的datafile、controlfile等
4、檢查ASM例項上的diskgroup
idle> select name from v$asm_diskgroup; NAME ------------------------------ DATA |
5、刪除檢查到ASM例項上的diskgroup
idle> drop diskgroup data including contents; Diskgroup dropped. |
6、關閉ASM例項
idle> shutdown ORA-15100: invalid or missing diskgroup name ASM instance shutdown idle> exit Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production With the Partitioning, OLAP and Data Mining options |
7、從css中刪除ASM例項資訊
ora_test@oracle[/home/oracle]> oradism -delete -asmsid +ASM |
8、刪除ASM例項相關的spfile、pfile等檔案
ora_test@oracle[/home/oracle]> cd $ORACLE_HOME/dbs ora_test@oracle[/oracle/app/10.1/dbs]> rm -f *+ASM* ora_test@oracle[/oracle/app/10.1/dbs]> cd $ORACLE_BASE/admin ora_test@oracle[/oracle/admin]> rm -rf +ASM |
9、刪除/etc/oratab檔案中的ASM例項相關行
刪除/etc/oratab檔案中的如下行
+ASM:/oracle/app/10.1:Y |
10、用root使用者刪除cssd服務
ora_test@root[/oracle/app/10.1/bin]> ./localconfig delete Stopping CSSD. Shutting down CSS daemon. Shutdown request successfully issued. Shutdown has begun. The daemons should exit soon. |
11、清除ASM使用的裝置的檔案頭資訊
ora_test@oracle[/home/oracle]> cd /dev/raw/ ora_test@oracle[/dev/raw]> ls -l * crw------- 1 oracle oinstall 162, 1 Jan 21 08:45 raw1 crw------- 1 oracle oinstall 162, 2 Jan 21 08:45 raw2 crw------- 1 oracle oinstall 162, 3 Jan 21 08:45 raw3 ora_test@oracle[/dev/raw]> dd if=/dev/zero of=/dev/raw/raw1 bs=1024 count=10 10+0 records in 10+0 records out 10240 bytes (10 kB) copied, 0.00396028 seconds, 2.6 MB/s ora_test@oracle[/dev/raw]> dd if=/dev/zero of=/dev/raw/raw2 bs=1024 count=10 10+0 records in 10+0 records out 10240 bytes (10 kB) copied, 0.00485093 seconds, 2.1 MB/s ora_test@oracle[/dev/raw]> dd if=/dev/zero of=/dev/raw/raw3 bs=1024 count=10 10+0 records in 10+0 records out 10240 bytes (10 kB) copied, 0.00532261 seconds, 1.9 MB/s |
--end--
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/22049049/viewspace-1030772/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 刪除Linux非rac環境下的ASM例項(轉)LinuxASM
- (轉)Oracle rac環境下清除asm例項OracleASM
- linux下rac環境下刪除節點Linux
- 刪除ASM例項ASM
- 單例項刪除ASM例項單例ASM
- asm例項刪除方法ASM
- ORACLE RAC環境下刪除節點Oracle
- 【ASM學習】在windows 環境下建立ASM例項ASMWindows
- 單機環境配置ASM例項ASM
- RAC和ASM環境下打patchASM
- oracle10.2.0.1 (rhel4)rac刪除asm例項不乾淨導致重建asm例項出錯OracleASM
- RAC環境下刪庫後重新建立相同例項名的問題總結
- 【Oracle】 RAC 環境刪除oracle 之二Oracle
- 【Oracle】 RAC 環境刪除oracle 之一Oracle
- Windows環境下刪除MySQLWindowsMySql
- 【RAC】刪除RAC資料庫節點(一)——刪除資料庫例項資料庫
- Rman 單例項filesystem(Windows)恢復到ASM環境(Linux)單例WindowsASMLinux
- 【RAC】刪除RAC資料庫節點(二)——刪除ASM資料庫ASM
- 虛擬機器環境下RAC刪除節點(Final)虛擬機
- ASM單例項(Oracle 11.2.0.4)環境(一)ASM單例Oracle
- ASM單例項(Oracle 11.2.0.4)環境(二)ASM單例Oracle
- 單機環境安裝配置ASM例項ASM
- Windows bcdedit刪除多啟動項---Windows 7環境下Windows
- linux下export命令新增刪除環境變數LinuxExport變數
- Oracle RAC環境下ASM磁碟組擴容OracleASM
- Oracle10g RAC環境下DataGuard備庫搭建例項Oracle
- rac+dg環境刪除歸檔日誌
- Windows平臺模擬單例項ASM環境Windows單例ASM
- Linux下環境變數設定、檢視、刪除Linux變數
- Linux下檢視 設 刪除 環境變數方法 .Linux變數
- rac環境 asmcmd用法;首先設定oracle_home oracle_sid(asm例項)ASMOracle
- 11.2環境ASM例項spfile放在ASM磁碟組的訪問方式ASM
- Oracle10g RAC環境下DataGuard備庫搭建例項-eygleOracle
- RAC+DG(asm單例項)ASM單例
- Linux 新增環境變數和刪除環境變數Linux變數
- linux下export命令新增、刪除環境變數(轉載)LinuxExport變數
- Linux環境下oracle數庫庫改名,例項改名LinuxOracle
- Oracle10g RAC環境OCR的新增、刪除、備份Oracle