ORACLE – Different Ways to Start and Stop Oracle RAC Instances

In this blog post, I will show you the different methods to stop and start an Oracle RAC instance and an Oracle RAC database.

1. Check the status of the database by using srvctl utility. (execute srvctl on unix prompt)

srvctl status database -d orclrac

2. Stop the instance instrac

srvctl stop instance -d orclrac -i instrac -o immediate

3. Verify that the instance instrac is down

# check out the status of instracin the output of the following command:
srvctl status database -d orclrac 

# check out the processes in the OS level
ps -ef | grep pmon

# connect to the database and verify to which instance the session is connected
sqlplus system/oracle@rac
SELECT INSTANCE_NAME FROM V$INSTANCE;

4. To stop two instances (e.g. instrac1, instrac2) in a single srvctl utility command.

srvctl stop instance -d rac -i instrac1,instrac2 -o immediate

5. Startup the database using the srvctl utility

Note: the startoption is optional and it defaults to open. With start command, it accepts the open, mount and nomout options.

srvctl stop instance -d rac -i instrac1,instrac2 -o immediate

6. Checkout the status of the database

srvctl status database -d orclrac

 

Knowledge worth sharing...Share on linkedin
Linkedin
Share on facebook
Facebook
Share on google
Google
Share on twitter
Twitter

Oracle – Enabling Archivelog Mode in Oracle RAC

Below are the steps to enable Archivelog Mode in Oracle RAC

# make sure orclrac database is running
srvctl status database -d orclrac

# stop the database
srvctl stop database -d orclrac -o immediate
srvctl status database -d orclrac

# start the database in mount state
srvctl start database -d orclrac -o mount

# using sqlplus, login as sysdba
sqlplus / as sysdba

# verify that the instances are in MOUNT state
SELECT INSTANCE_NAME,STATUS FROM GV$INSTANCE;

# verify that the database is operating in NOARCHIVE mode
ARCHIVE LOG LIST;

# define the destination of the archive log files
ALTER SYSTEM SET LOG_ARCHIVE_DEST_1='LOCATION=USE_DB_RECOVERY_FILE_DEST' SCOPE=SPFILE;

# Note: because OMF is enabled, setting the
# LOG_ARCHIVE_FORMAT parameter has no effect.

# enable the archivelog mode
ALTER DATABASE ARCHIVELOG;

# restart the database
srvctl stop database -d orclrac
srvctl start database -d orclrac

# verify that the archivelog is enabled
sqlplus / as sysdba
archive log list

 

Knowledge worth sharing...Share on linkedin
Linkedin
Share on facebook
Facebook
Share on google
Google
Share on twitter
Twitter