9i RAC轉換為SINGLE例項
客戶有個RAC,覺得太難管,不想弄,想做成雙機
今天在LINUX上測試了下下,ORACLE方面的
SQL> create pfile='/tmp/init.ora' from spfile;
File created.
[oracle@westzq1 ~]$ srvctl stop database -d rac9i
*********************************************************************************
[oracle@westzq1 ~]$ cat /tmp/init.ora
#*.background_dump_dest='/oracle/ora9/admin/rac9i/bdump'
*.background_dump_dest='/oracle/ora9/admin/single/bdump'
#*.cluster_database_instances=2
#*.cluster_database=true
#rac9i1.cluster_database=TRUE
*.compatible='9.2.0.0.0'
*.control_files='/dev/raw/raw3','/dev/raw/raw2'
#*.core_dump_dest='/oracle/ora9/admin/rac9i/cdump'
*.core_dump_dest='/oracle/ora9/admin/single/cdump'
*.db_block_size=8192
*.db_cache_size=25165824
*.db_domain=''
*.db_file_multiblock_read_count=16
*.db_name='rac9i'
*.fast_start_mttr_target=300
*.hash_join_enabled=TRUE
#rac9i1.instance_name='rac9i1'
#rac9i2.instance_name='rac9i2'
#rac9i2.instance_number=2
#rac9i1.instance_number=1
*.instance_name='single'
*.java_pool_size=0
*.large_pool_size=8388608
#rac9i2.local_listener='(address=(protocol=tcp)(host=westzq2)(port=1521))'
#rac9i1.local_listener='(address=(protocol=tcp)(host=westzq1)(port=1521))'
*.log_archive_dest_1='LOCATION=/oracle/ora9/arch MANDATORY REOPEN'
*.log_archive_format='%t_%s'
*.log_archive_start=TRUE
*.open_cursors=300
*.parallel_max_servers=50
*.pga_aggregate_target=25165824
*.processes=150
*.query_rewrite_enabled='FALSE'
#*.remote_listener='LISTENERS_RAC9I'
#rac9i2.remote_listener='(address=(protocol=tcp)(host=westzq1)(port=1521))'
#rac9i1.remote_listener='(address=(protocol=tcp)(host=westzq2)(port=1521))'
*.remote_login_passwordfile='exclusive'
*.shared_pool_size=83886080
*.sort_area_size=524288
*.star_transformation_enabled='TRUE'
#rac9i1.thread=1
#rac9i2.thread=2
*.timed_statistics=TRUE
*.undo_management='AUTO'
*.undo_retention=10800
#rac9i1.undo_tablespace='UNDOTBS1'
#rac9i2.undo_tablespace='UNDOTBS2'
*.undo_tablespace='UNDOTBS1'
##*.user_dump_dest='/oracle/ora9/admin/rac9i/udump'
*.user_dump_dest='/oracle/ora9/admin/single/udump'
*********************************************************************************
export ORACLE_SID=single
*********************************************************************************
[oracle@westzq1 admin]$ ls -l
total 8
drwxr-xr-x 8 oracle dba 4096 Dec 2 2008 rac9i
[oracle@westzq1 admin]$ mv rac9i single
[oracle@westzq1 admin]$ ls -l
total 8
drwxr-xr-x 8 oracle dba 4096 Dec 2 2008 single
[oracle@westzq1 dbs]$ orapwd file=/oracle/ora9/product/9.2/dbs/orapwsingle password=sys
*********************************************************************************
啟動例項一
SQL> startup pfile='/tmp/init.ora';
ORACLE instance started.
Total System Global Area 135336712 bytes
Fixed Size 451336 bytes
Variable Size 109051904 bytes
Database Buffers 25165824 bytes
Redo Buffers 667648 bytes
Database mounted.
Database opened.
SQL> show parameter cluster
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
cluster_database boolean FALSE
cluster_database_instances integer 1
cluster_interconnects string
SQL> show parameter instance
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
active_instance_count integer
cluster_database_instances integer 1
instance_groups string
instance_name string single
instance_number integer 0
open_links_per_instance integer 4
parallel_instance_group string
parallel_server_instances integer 1
*********************************************************************************
SQL> alter database disable thread 2;
Database altered.
*********************************************************************************
[oracle@westzq1 bin]$ cd $ORACLE_HOME/rdbms/lib
[oracle@westzq1 lib]$ make -f ins_rdbms.mk rac_off
rm -f /oracle/ora9/product/9.2/lib/libskgxp9.so
cp /oracle/ora9/product/9.2/lib//libskgxpd.so /oracle/ora9/product/9.2/lib/libskgxp9.so
rm -f /oracle/ora9/product/9.2/lib/libskgxn9.so
cp /oracle/ora9/product/9.2/lib//libskgxns.so /oracle/ora9/product/9.2/lib/libskgxn9.so
/usr/bin/ar d /oracle/ora9/product/9.2/rdbms/lib/libknlopt.a kcsm.o
/usr/bin/ar cr /oracle/ora9/product/9.2/rdbms/lib/libknlopt.a /oracle/ora9/product/9.2/rdbms/lib/ksnkcs.o
[oracle@westzq1 lib]$ make -f ins_rdbms.mk ioracle
- Linking Oracle
rm -f /oracle/ora9/product/9.2/rdbms/lib/oracle
gcc -o /oracle/ora9/product/9.2/rdbms/lib/oracle -L/oracle/ora9/product/9.2/rdbms/lib/ -L/oracle/ora9/product/9.2/lib/ -L/oracle/ora9/product/9.2/lib/stubs/ -Wl,-E `test -f /oracle/ora9/product/9.2/rdbms/lib/skgaioi.o && echo /oracle/ora9/product/9.2/rdbms/lib/skgaioi.o` /oracle/ora9/product/9.2/rdbms/lib/opimai.o /oracle/ora9/product/9.2/rdbms/lib/ssoraed.o /oracle/ora9/product/9.2/rdbms/lib/ttcsoi.o /oracle/ora9/product/9.2/lib/nautab.o /oracle/ora9/product/9.2/lib/naeet.o /oracle/ora9/product/9.2/lib/naect.o /oracle/ora9/product/9.2/lib/naedhs.o /oracle/ora9/product/9.2/rdbms/lib/config.o -lserver9 -lodm9 -lskgxp9 -lskgxn9 -lclient9 -lvsn9 -lwtcserver9 -lcommon9 -lgeneric9 /oracle/ora9/product/9.2/rdbms/lib/defopt.o -lknlopt `if /usr/bin/ar tv /oracle/ora9/product/9.2/rdbms/lib/libknlopt.a | grep xsyeolap.o > /dev/null 2>&1 ; then echo "-loraolap9" ; fi` -lslax9 -lpls9 -lplp9 -lserver9 -lclient9 -lvsn9 -lwtcserver9 -lcommon9 -lgeneric9 -lknlopt -lslax9 -lpls9 -lplp9 -ljox9 -lserver9 -locijdbcst9 -lwwg9 `cat /oracle/ora9/product/9.2/lib/ldflags` -lnsslb9 -lncrypt9 -lnsgr9 -lnzjs9 -ln9 -lnl9 -lnro9 `cat /oracle/ora9/product/9.2/lib/ldflags` -lnsslb9 -lncrypt9 -lnsgr9 -lnzjs9 -ln9 -lnl9 -lmm -lnls9 -lcore9 -lnls9 -lcore9 -lnls9 -lxml9 -lcore9 -lunls9 -lnls9 `cat /oracle/ora9/product/9.2/lib/ldflags` -lnsslb9 -lncrypt9 -lnsgr9 -lnzjs9 -ln9 -lnl9 -lnro9 `cat /oracle/ora9/product/9.2/lib/ldflags` -lnsslb9 -lncrypt9 -lnsgr9 -lnzjs9 -ln9 -lnl9 -ltrace9 -lnls9 -lcore9 -lnls9 -lcore9 -lnls9 -lxml9 -lcore9 -lunls9 -lnls9 `if /usr/bin/ar tv /oracle/ora9/product/9.2/rdbms/lib/libknlopt.a | grep "kxmnsd.o" > /dev/null 2>&1 ; then echo " " ; else echo "-lordsdo9"; fi` -lctxc9 -lctx9 -lzx9 -lgx9 -lctx9 -lzx9 -lgx9 -lordimt9 -lnls9 -lcore9 -lnls9 -lcore9 -lnls9 -lxml9 -lcore9 -lunls9 -lnls9 -lsnls9 -lunls9 -lxsd9 -lnls9 -lcore9 -lnls9 -lcore9 -lnls9 -lxml9 -lcore9 -lunls9 -lnls9 `cat /oracle/ora9/product/9.2/lib/sysliblist` -Wl,-rpath,/oracle/ora9/product/9.2/lib:/lib/i686:/lib:/usr/lib -lm `cat /oracle/ora9/product/9.2/lib/sysliblist` -ldl -lm `test -f /oracle/ora9/product/9.2/rdbms/lib/skgaioi.o && echo -laio`
mv -f /oracle/ora9/product/9.2/bin/oracle /oracle/ora9/product/9.2/bin/oracleO
mv /oracle/ora9/product/9.2/rdbms/lib/oracle /oracle/ora9/product/9.2/bin/oracle
chmod 6751 /oracle/ora9/product/9.2/bin/oracle
*********************************************************************************
[oracle@westzq1 lib]$ /oracle/ora9/product/9.2/bin/gsdctl stop
Successfully stopped GSD on local node
[oracle@westzq1 lib]$ ps -ef|grep oracm
oracle 5398 1 0 00:05 pts/1 00:00:00 oracm
oracle 5399 5398 0 00:05 pts/1 00:00:00 oracm
oracle 5401 5399 0 00:05 pts/1 00:00:00 oracm
oracle 5402 5399 0 00:05 pts/1 00:00:00 oracm
oracle 5403 5399 0 00:05 pts/1 00:00:00 oracm
oracle 5404 5399 0 00:05 pts/1 00:00:00 oracm
oracle 5405 5399 0 00:05 pts/1 00:00:00 oracm
oracle 5406 5399 0 00:05 pts/1 00:00:02 oracm
oracle 5407 5399 0 00:05 pts/1 00:00:00 oracm
oracle 5423 5399 0 00:05 pts/1 00:00:00 oracm
oracle 8846 6806 0 00:35 pts/1 00:00:00 grep oracm
[oracle@westzq1 lib]$ kill -9 5398
*********************************************************************************
SQL> startup pfile='/tmp/init.ora';
ORACLE instance started.
Total System Global Area 135336712 bytes
Fixed Size 451336 bytes
Variable Size 109051904 bytes
Database Buffers 25165824 bytes
Redo Buffers 667648 bytes
Database mounted.
Database opened.
SQL> create spfile from pfile='/tmp/init.ora';
File created.
*********************************************************************************
SQL> select * from v$thread;
THREAD# STATUS ENABLED GROUPS INSTANCE OPEN_TIME CURRENT_GROUP# SEQUENCE# CHECKPOINT_CHANGE# CHECKPOIN
---------- ------ -------- ---------- ---------------- --------- -------------- ---------- ------------------ ---------
ENABLE_CHANGE# ENABLE_TI DISABLE_CHANGE# DISABLE_T
-------------- --------- --------------- ---------
1 OPEN PUBLIC 2 single 30-AUG-09 1 51 2185600 30-AUG-09
1 02-DEC-08 0
2 CLOSED DISABLED 2 rac9i2 29-SEP-09 0 15 2185307 29-SEP-09
62222 02-DEC-08 2185416 30-AUG-09
SQL> select * from v$log;
GROUP# THREAD# SEQUENCE# BYTES MEMBERS ARC STATUS FIRST_CHANGE# FIRST_TIM
---------- ---------- ---------- ---------- ---------- --- ---------------- ------------- ---------
1 1 51 26214400 1 NO CURRENT 2185600 30-AUG-09
2 1 50 26214400 1 YES INACTIVE 2185583 30-AUG-09
3 2 15 26214400 1 YES INACTIVE 2185254 29-SEP-09
4 2 14 26214400 1 YES INACTIVE 2185247 29-SEP-09
SQL> alter database drop logfile group 3;
Database altered.
SQL> alter database drop logfile group 4;
Database altered.
SQL> select * from v$thread;
THREAD# STATUS ENABLED GROUPS INSTANCE OPEN_TIME CURRENT_GROUP# SEQUENCE# CHECKPOINT_CHANGE# CHECKPOIN
---------- ------ -------- ---------- ---------------- --------- -------------- ---------- ------------------ ---------
ENABLE_CHANGE# ENABLE_TI DISABLE_CHANGE# DISABLE_T
-------------- --------- --------------- ---------
1 OPEN PUBLIC 2 single 30-AUG-09 1 51 2185600 30-AUG-09
1 02-DEC-08 0
*********************************************************************************
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.
Total System Global Area 135336712 bytes
Fixed Size 451336 bytes
Variable Size 109051904 bytes
Database Buffers 25165824 bytes
Redo Buffers 667648 bytes
Database mounted.
Database opened.
SQL>
*********************************************************************************
需要注意的:
初始化引數修改
執行緒的DISABLE和日誌組的DROP
ORACLE RAC選項的關閉,不關閉單例項下啟動還是需要叢集件的支援
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/8242091/viewspace-613556/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 將RAC軟體轉換為單例項軟體單例
- RAC+單例項DG的切換單例
- 如何將獨立例項轉換成叢集例項EU
- RMAN Duplicate RAC to Single Instance
- RAC+DG(asm單例項)ASM單例
- rac恢復到單例項單例
- 將RAC備份集恢復為單例項資料庫單例資料庫
- 路由交換例項路由
- 例項詳解構建數倉中的行列轉換
- Oracle 11g RAC到單例項OGG同步Oracle單例
- js圖片切換例項JS
- HowTo Restore RMAN Disk backups of RAC Database to Single Instance On Another NoRESTDatabase
- unix時間轉換為datetimedatetime轉換為unixtime
- 將外掛類路徑轉為型別,並建立例項。型別
- [js常用]百度將文字轉化為語音例項JS
- 【RAC】RAC更換心跳地址和RAC更換儲存主要步驟
- Flink例項(五十): Operators(十)多流轉換運算元(五)coGroup 與union
- CSS 例項之翻轉圖片CSS
- rac二節點例項redo故障無法啟動修復
- 單例項Primary快速搭建Standby RAC參考手冊(19.16 ADG)單例
- oracle rac 單個例項不能生成awr報告的問題Oracle
- ORA-29702複製RAC Oracle軟體啟動單例項Oracle單例
- ORACLE11GR2 RAC解除安裝ASM例項步驟OracleASM
- CentOS 7.3 ECS上搭建RAC 18c+單例項DG+EMCC+DG的FSFO快速故障轉移配置CentOS單例
- 設計模式例項講解 - 里氏替換設計模式
- vue移動端路由切換完整例項Vue路由
- jQuery table表格隔行換色程式碼例項jQuery
- 一次詳細的RAC 節點例項驅逐分析文件
- 一次RAC例項驅逐詳細分析及解決方案
- I/O複用3個小例項+將signal轉化為IO事件事件
- rac 正常關閉例項service不會自動漂移,只有在例項異常abort才會發生自動failoverAI
- 使用遞迴遍歷並轉換樹形資料(以 TypeScript 為例)遞迴TypeScript
- Oracle 資料庫巡檢指令碼 單例項 RAC 輸出HTML格式Oracle資料庫指令碼單例HTML
- Oracle 例項和RAC叢集下資料庫日誌目錄合集Oracle資料庫
- 記錄一次Oracle 11.2.0.4 RAC異地恢復到單例項Oracle單例
- 從nub備份恢復(同平臺)恢復RAC至單例項單例
- 純CSS的導航欄Tab切換例項CSS
- keras轉tensorflow lite【方法二】直接轉:簡單模型例項Keras模型
- div前後翻轉效果程式碼例項