Normally we set the ORACLE_UNQNAME setting in our bash_profile. But in my case I use the backup server to restore both production and stage backupsets for testing. It is very easy to forget setting this environment variable. Therefore I decided to modify my oraenv file on just this server to :
# Install any “custom” code here
case “$ORACLE_SID” in
(“LJPROD”) export ORACLE_UNQNAME=”LJPROD” ;;
(“LJSTAGE”) export ORACLE_UNQNAME=”LJSTAGE” ;;
Granted if you set the ORACLE_SID to something not in your oratab file the unqname , and home will not be set, but this would be the case with no changes to the default environment. Seems there are a lot of posts about this subject in a RAC environment but not mentioned often when using Data Guard and or RMAN.
Let me know your thoughts on this, any best practices, and if you have done something similar for your environments.