Monday, December 17, 2012

Restarting correct sequence numbers in policy managed database


********************************************************************************
This blog is for to restart correct instance numbers in the proper sequence number
********************************************************************************

In our case the instances running on different hosts as below

[oracle@subhen-db01 ~]$ srvctl status database -d ORCL
Instance ORCL_2 is running on node subhen-db01
Instance ORCL_1 is running on node subhen-db02
Instance ORCL_3 is running on node subhen-db03

***************************
database is policy managed
***************************

[oracle@subhen-db01 ~]$ srvctl config database -d ORCL
Database unique name: ORCL
Database name: ORCL
Oracle home: /oracle/app/database/11.2.0.2/ORCL
Oracle user: oracle
Spfile: +DATA/ORCL/spfileORCL.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: KXD2BUPOOL
Database instances:
Disk Groups: DATA,FRA
Mount point paths:
Services:
Type: RAC
Database is policy managed

***************************
STEPS followed as below
***************************
--stop the database 
[oracle@subhen-db01 ~]$ srvctl stop database -d ORCL
[oracle@subhen-db01 ~]$ srvctl status database -d ORCL
Instance ORCL_2 is not running on node subhen-db01
Instance ORCL_1 is not running on node subhen-db02
Instance ORCL_3 is not running on node subhen-db03
--remove database from grid configuration
[oracle@subhen-db01 ~]$ srvctl remove database -d ORCL
Remove the database ORCL? (y/[n]) y
--add database back to configuration
[oracle@subhen-db01 ~]$ srvctl add database -d ORCL -o /oracle/app/database/11.2.0.2/ORCL -p +DATA/ORCL/spfileORCL.ora -y AUTOMATIC -g "KXD2BUPOOL" -a "DATA,FRA" -n ORCL
[oracle@subhen-db01 ~]$ srvctl status database -d ORCL
Database is not running.
--start database 
[oracle@subhen-db01 ~]$ srvctl start database -d ORCL
[oracle@subhen-db01 ~]$  srvctl status database -d ORCL
Instance ORCL_1 is running on node subhen-db01
Instance ORCL_2 is running on node subhen-db02
Instance ORCL_3 is running on node subhen-db03
[oracle@subhen-db01 ~]$ srvctl config database -d ORCL
Database unique name: ORCL
Database name: ORCL
Oracle home: /oracle/app/database/11.2.0.2/ORCL
Oracle user: oracle
Spfile: +DATA/ORCL/spfileORCL.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: KXD2BUPOOL
Database instances:
Disk Groups: DATA,FRA
Mount point paths:
Services:
Type: RAC
Database is policy managed

No comments:

Post a Comment