Find in this Blog

Monday, July 6, 2015

OPS$ user ID creation after Backup restore to hetrogeniouse environment!!!

You just  modify according to your current system setup.
1.Login to orasid and  execute  sqlplus "/as sysdba"
2.CREATE USER "OPS$<Hostname>\<SID>ADM" DEFAULT TABLESPACE PSAPSR3 TEMPORARY TABLESPACE PSAPTEMP IDENTIFIED EXTERNALLY;
3.SELECT GRANTED_ROLE FROM DBA_ROLE_PRIVS WHERE GRANTEE = 'OPS$<Hostname>\<SID>ADM';
4.GRANT CONNECT, RESOURCE TO "OPS$<Hostname>\<SID>ADM";
5.CREATE USER "OPS$<Hostname>\SAPSERVICE<SID>" DEFAULT TABLESPACE PSAPSR3USR TEMPORARY TABLESPACE PSAPTEMP IDENTIFIED EXTERNALLY;
6.SELECT GRANTED_ROLE FROM DBA_ROLE_PRIVS WHERE GRANTEE = 'OPS$<Hostname>\SAPSERVICE<SID>';
7.GRANT CONNECT, RESOURCE TO "OPS$<Hostname>\SAPSERVICE<SID>";
8.SELECT OWNER FROM DBA_TABLES WHERE TABLE_NAME = 'SAPUSER';
9.CREATE TABLE "OPS$<Hostname>\<SID>ADM".SAPUSER (USERID VARCHAR2(256), PASSWD VARCHAR2(256));
10.INSERT INTO "OPS$<Hostname>\<SID>ADM".SAPUSER VALUES ('SAPSR3', 'Password');

 sapuser schema name and  DBpassword ('OWNER', 'PASSWORD');
11.SELECT OWNER, TABLE_OWNER, TABLE_NAME FROM DBA_SYNONYMS WHERE SYNONYM_NAME = 'SAPUSER';

SQL> SELECT OWNER FROM DBA_TABLES WHERE TABLE_NAME = 'SAPUSER';
OWNER 
------------------------------
OPS$PREPRODGEP\GEPADM
(optional, to remove all other non usable owner)
 
12.CREATE SYNONYM "OPS$<Hostname>\SAPSERVICE<SID>".SAPUSER FOR "OPS$<Hostname>\<SID>ADM".SAPUSER;
13.GRANT SELECT, UPDATE ON "OPS$<Hostname>\<SID>ADM".SAPUSER TO "OPS$<Hostname>\SAPSERVICE<SID>";


Set the following parameter:

REMOTE_OS_AUTHENT = TRUE
           in init<sid>.ora.
SQL> ALTER SYSTEM SET REMOTE_OS_AUTHENT = TRUE SCOPE=SPFILE;
System altered.
SQL> COMMIT;
RESTART THE DATABASE:


Thanks
Yoonus

No comments:

Post a Comment

Ask Your Questions ?#