Oracle Real Application Clusters (RAC) provide high availability, scalability, and manageability for databases. One of the most powerful tools for managing RAC databases is srvctl
, a command-line utility that allows administrators to control various database services. This blog explores essential srvctl
commands to help you efficiently manage Oracle RAC environments.
1. Checking Database Configuration and Status
- List all available databases on the host:
- Check the status of a specific database and its instances:
- Retrieve detailed status information about a database, including its instances and states:
2. Stopping and Starting Databases
Stopping the Database
- Stop the database on all RAC nodes:
- Stopping the database using different modes:
Starting the Database
Start the database across all nodes:
- Starting the database in different states:
3. Managing Database Instances
Administrators can manage individual database instances using the following commands:
- Start a specific instance:
- Stop a specific instance:
4. Adding and Modifying Database Configurations
- Adding a database to cluster services:
Adding a new instance to the cluster:
- Modify database configuration (SPFILE, disk groups):
5. Checking Cluster and ASM Configuration
- Display complete Oracle Clusterware configuration details:
- Check ASM configuration details:
6. Managing Listeners and VIPs
Check the status of local database listeners:
Stop the local database listener:
Stop a specific listener on a node:
- Stop and remove Virtual IP (VIP):
7. Managing SCAN and SCAN Listeners
Check SCAN and SCAN listener status:
Stop a specific SCAN listener:
Stop a specific SCAN VIP:
8. Removing and Adding Database Services
Remove a database from cluster services:
- Add a database service:
Add an instance to the database:
srvctl add instance -d <db_unique_name> -i <inst_name> -n <node_name>
9. Managing Database Services
Relocate a service from one instance to another:
Remove a database service:
Add a database service with preferred and available lists:
Start and stop a service:
Comments
Post a Comment