Since oracle 12c, SAP recommends to use “oracle” user instead of “orasid” for database. Now there is a hot question, what if I have multiple databases with different <DBSID> in the same host? How to let one “oracle” user to admin all the databases in the same host?
In the past, we can easily achieve this, because every different databases with different <DBSID> have their unique admin user “orasid”. Also all the environment variables of the database are existing in login scripts. As soon as “orasid” log on the OS, the environment variables will automatically set from home profile. This is an permanent change.
However since “oracle” comes to use, we cannot use login script to set environment variables like “orasid” (we have multiple databases installed).
But we need to run “. oraenv” as mentioned in note
“1915317 – Migrating Software Owner to ‘oracle'” where we can set all the oracle related environment variables for <DBSID>. Afterwards we can have unique environment variables for the < DBSID> we are interested in. By using this way, we can switch to different database without problem for “oracle” user.
So the differences on environment variable settings:
1. “orasid”: uses lo login profile to set, different “orasid” users have different login profile in the its own home directory, this is a permanent change
2. “oracle”: we have to manually run “. oraenv” where asks to input <DBSID> to adjust environment variables, this is a temporary change
By the way we need to use “source” command before oraenv, like “. oraenv”.