Siebel On Active Data Guard Standby
Siebel On Active Data Guard Standby
Siebel On Active Data Guard Standby
April 2015
This paper describes how a read only Siebel application service can be delivered on a standby site
querying data from an Active Data Guard standby. This can be used to:
Offloaded read only user workload from the primary database increasing the overall utilization and
performance capacity of the system.
The Active Data Guard standby database is a block for block replica of the primary database and so it is not
possible to make any changes to the standby database. All changes must be made on the primary and then
synchronized to the standby.
The S_USER and S_SSA_ID tables are always updated by the Siebel application, even if the user is only
performing queries, and so we must find a way to divert these updates to a read/write database in order for
the Siebel application to startup without error against the read only Active Database Guard standby.
The approach used in this paper is to create a separate “dummy” database located on the standby site to
contain the S_USER and S_SSA_ID. We assume that any changes to these tables when running in read only
mode are not needed and can be safely discarded.
Siebel is redirected to the “dummy” database and tables by creating a separate “RO” schema (table owner). In
this schema, S_SSA_ID and S_USER are database links to the “dummy” database. All other Siebel tables are
created as synonyms of the actual tables on the true Siebel schema.
When running on the primary site Siebel is configured to connect to the true table owner. When running on
the standby site against the Active Data Guard standby database Siebel is configured to connect to the “RO”
table owner.
Prerequisites
Configuration Steps
Environment Variables
Identify appropriate values for the following environment variables and be prepared to set these variables as
indicated in the subsequent configuration steps:
mkdir $RO_DIR
sqlplus / as sysdba <<EOF
create or replace directory ro_dir as '${RO_DIR}';
GRANT READ, WRITE ON DIRECTORY ro_dir TO $SIEB_TBO;
EOF
mkdir $RO_DIR
sqlplus / as sysdba <<EOF
DECLARE
CURSOR NAME IS SELECT TABLE_NAME FROM DBA_TABLES
WHERE OWNER='$SIEB_TBO';
synonym_does_not_exist EXCEPTION;
PRAGMA EXCEPTION_INIT(synonym_does_not_exist, -01434);
BEGIN
FOR TNAME IN NAME
LOOP
BEGIN
EXECUTE IMMEDIATE 'DROP SYNONYM ' || TNAME.TABLE_NAME;
exception when synonym_does_not_exist then null;
END;
END LOOP;
END;
/
DECLARE
CURSOR NAME IS SELECT TABLE_NAME FROM DBA_TABLES
WHERE OWNER='$SIEB_TBO';
BEGIN
FOR TNAME IN NAME
LOOP
BEGIN
EXECUTE IMMEDIATE 'CREATE SYNONYM ' || TNAME.TABLE_NAME || ' FOR $SIEB_TBO.' ||
TNAME.TABLE_NAME;
END;
END LOOP;
END;
/
EOF
Create Siebel File System Replica
Create a replica of the Siebel file system on the standby site. Ideally, this would be continuously replicated
from the primary and mounted in read only mode, so that changes made on the primary can be viewed on the
standby but no changes can be made on the standby.
The Siebel File System currently used by the Siebel on the standby site should be dismounted and the replica
should be mounted in its place. Here is an example of how the file system could be mounted on Linux
(/etc/fstab):
TableOwner = RO
Change the enterprise level table owner and password parameters using server manager:
change ent param TableOwner="RO"
change enterprise param TableOwnPass=RO123
Change the ServerNamedDataSrc named datasource table owner parameter using server manager
Deactivate unused system auxiliary components: SRM capabilities does not apply to the secondary enterprise,
no updates and maintenance will be managed on SRM model. Note that services implemented to be
executed in this enterprise will be implemented in an isolated way, executing all the read only actions inside
the ObjMgr (no remote workflows or asynchronous requests to other components)
deactivate component definition SRProc
deactivate component definition SvrTblCleanup
deactivate component definition SvrTaskPersist
Shutdown Siebel.
DUMMY =
(DESCRIPTION =
(CONNECT_TIMEOUT=5)
(TRANSPORT_CONNECT_TIMEOUT=3)
(RETRY_COUNT=3)
(ADDRESS_LIST=
(FAILOVER=on)
(LOAD_BALANCE=on)
(ADDRESS = (PROTOCOL = TCP)(HOST = scam08-scan3)(PORT = 1521)))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = dummy))
)
As a safety precaution, it is best if this alias is not defined on the primary database servers so that if a Siebel
server tries to connect to the “RO” table owner on the primary database server it will fail.
Point Siebel on Standby to Standby Database
Good to have a different database service (for example SIEB_STBY) for the database in active standby mode.
The alias must be defined in the tnsnames.ora on each standby Siebel server. For example:
SIEBXD =
(DESCRIPTION =
(CONNECT_TIMEOUT=5)
(TRANSPORT_CONNECT_TIMEOUT=3)
(RETRY_COUNT=3)
(ADDRESS_LIST=
(LOAD_BALANCE=on)
(ADDRESS = (PROTOCOL = TCP)(HOST = scam08-scan3)(PORT = 1521)))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = sieb_stby))
)