Database - RAC/Scalability (MOSC)

MOSC Banner

Need help in automation of service relocation script

edited Dec 12, 2013 10:48PM in Database - RAC/Scalability (MOSC) 2 commentsAnswered
 Hello,

In a loop I am using below command for every database

crsctl status res | grep -E "ora\.$DATABASE\.(.+)\.svc" and below is one of the sample output
NAME=ora.sgraphut.sgraphutxdb.svc

Now I want to extract just service name out of this string (that is sgraphutxdb) please help me how do I proceed?
Additionally,if I need to pass the node name as one of the parameters while calling this script
Let's suppose the script name is test_relocate.sh and I need to execute this like below:
test_relocate.sh -n node1
Now how do I recognize this inside the script in a loop

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center