您好,登錄后才能下訂單哦!
今天就跟大家聊聊有關12c如何在集群操作rac與rac one node互相轉換,可能很多人都不太了解,為了讓大家更加了解,小編給大家總結了以下內容,希望大家根據這篇文章可以有所收獲。
-- 首先在集群里停掉2號節點的實例
[oracle@host01 app]$ srvctl stop instance -d racdb -i racdb_2
--查看rac的類型,目前顯示為(Type: RAC)
[oracle@host01 app]$ srvctl config database -d racdb
Database unique name: racdb
Database name: racdb
Oracle home: /u01/app/oracle/product/12.1.0/db_1
Oracle user: oracle
Spfile: +DATA/RACDB/PARAMETERFILE/spfile.288.960026421
Password file: +DATA/RACDB/PASSWORD/pwdracdb.276.960026013
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: racdbpool
Disk Groups: FRA,DATA
Mount point paths:
Services: RACDBACN
Type: RAC
Start concurrency:
Stop concurrency:
OSDBA group: dba
OSOPER group: oper
Database instances:
Configured nodes:
Database is policy managed
-- 轉換成rac one node類型
[oracle@host01 app]$ srvctl convert database -d racdb -c RACONENODE
-- 再查看rac的類型,此時顯示(Type: RACOneNode)
[oracle@host01 app]$ srvctl config database -d racdb
Database unique name: racdb
Database name: racdb
Oracle home: /u01/app/oracle/product/12.1.0/db_1
Oracle user: oracle
Spfile: +DATA/RACDB/PARAMETERFILE/spfile.288.960026421
Password file: +DATA/RACDB/PASSWORD/pwdracdb.276.960026013
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: racdbpool
Disk Groups: FRA,DATA
Mount point paths:
Services: RACDBACN
Type: RACOneNode
Online relocation timeout: 30
Instance name prefix: racdb
Candidate servers:
OSDBA group: dba
OSOPER group: oper
Database instances:
Database is policy managed
-- 嘗試再重新轉換回rac類型
[oracle@host01 app]$ srvctl convert database -d racdb -c RAC
-- 查看rac的類型,已經變成rac了,而且在兩個節點上的實例也被起來了
[oracle@host01 app]$ srvctl config database -d racdb
Database unique name: racdb
Database name: racdb
Oracle home: /u01/app/oracle/product/12.1.0/db_1
Oracle user: oracle
Spfile: +DATA/RACDB/PARAMETERFILE/spfile.288.960026421
Password file: +DATA/RACDB/PASSWORD/pwdracdb.276.960026013
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: racdbpool
Disk Groups: FRA,DATA
Mount point paths:
Services: RACDBACN
Type: RAC
Start concurrency:
Stop concurrency:
OSDBA group: dba
OSOPER group: oper
Database instances:
Configured nodes:
Database is policy managed
-- 再重新轉換回rac one node
[oracle@host01 app]$ srvctl convert database -d racdb -c RACONENODE
PRCD-1154 : Failed to convert the configuration of cluster database racdb into its equivalent RAC One Node database configuration because cluster database is running on more than one server [host02, host01]
-- 提示有兩個節點在跑,關掉2號節點
[oracle@host01 app]$ srvctl stop instance -d racdb -i racdb_2
PRCD-1315 : failed to stop instances for database racdb
PRCR-1014 : Failed to stop resource ora.racdb.db
PRCR-1065 : Failed to stop resource ora.racdb.db
CRS-2529: Unable to act on 'ora.racdb.db' because that would require stopping or relocating 'ora.racdb.racserv.svc', but the force option was not specified
-- 提示要先關掉racserv這個service才能關閉2號節點實例
[oracle@host01 app]$ srvctl stop service -d RACDB -s racserv
-- 再次關閉實例
[oracle@host01 app]$ srvctl stop instance -d racdb -i racdb_2
-- 轉換rac至rac one node
[oracle@host01 app]$ srvctl convert database -d racdb -c RACONENODE
-- 查狀態,轉換成功
[oracle@host01 app]$ srvctl config database -d racdb
Database unique name: racdb
Database name: racdb
Oracle home: /u01/app/oracle/product/12.1.0/db_1
Oracle user: oracle
Spfile: +DATA/RACDB/PARAMETERFILE/spfile.288.960026421
Password file: +DATA/RACDB/PASSWORD/pwdracdb.276.960026013
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: racdbpool
Disk Groups: FRA,DATA
Mount point paths:
Services: RACDBACN
Type: RACOneNode
Online relocation timeout: 30
Instance name prefix: racdb
Candidate servers:
OSDBA group: dba
OSOPER group: oper
Database instances:
Database is policy managed
看完上述內容,你們對12c如何在集群操作rac與rac one node互相轉換有進一步的了解嗎?如果還想了解更多知識或者相關內容,請關注億速云行業資訊頻道,感謝大家的支持。
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。