Installation and Upgrade > Advanced Deployment Considerations > Advanced Database Configurations > Configuring Windchill with Oracle Data Guard
  
Configuring Windchill with Oracle Data Guard
The following sections document configuration steps for using Windchill with Oracle Data Guard.
Configuring a New Windchill Installation for use with Oracle Data Guard
Complete the following steps to configure a new Windchill installation for use with Oracle Data Guard.
1. Configure and verify Oracle Data Guard following the information provided by Oracle: https://docs.oracle.com/database/121/SBYDB/create_ps.htm
* 
PTC strongly recommends selecting MaxProtection as the Data Guard Protection mode to avoid any data inconsistencies immediately after a database failover. While assuring data consistency, this protection mode can negatively affect overall system performance.
2. Configure the client failover service for Oracle Data Guard using the “Client Failover Best Practices for Highly Available Oracle Databases: Oracle Database 11g Release 2” white paper provided by Oracle (http://www.oracle.com/technetwork/database/features/availability/maa-wp-11gr2-client-failover-173305.pdf) or Oracle support documents 461874.1 or 1429223.1.
3. Create the Windchill Oracle database user schema by executing the following statements as a database administrative user, using SQL*Plus. Replace the variables with values appropriate for your system.
create user <Windchill_DB_Username> identified by <Windchill_DB_User_password>
default tablespace <Default_Tablespace_Name>
temporary tablespace <Temporary_Tablespace_Name>
/
grant connect, resource to <Windchill_DB_Username>
/
grant create sequence, create view,
unlimited tablespace to <Windchill_DB_Username>
4. Launch the PTC Solution Installer (PSI) and install Windchill by selecting the Oracle Advanced option for the Database Software field in the platform components window.
5. In the database information window of the PSI, enter the following information:
The full Oracle Data Guard connection string in the Oracle Database Connection String field as follows, replacing the variables with values appropriate for your system:
(DESCRIPTION=(ADDRESS_LIST=(FAILOVER=ON)(ADDRESS=(PROTOCOL=TCP)
(HOST=<Primary_DB_HOST>)(PORT=<Listener_Port>))(ADDRESS=(PROTOCOL=TCP)
(HOST=<StandBy_DB_HOST>)(PORT=<Listener_Port>)))
(CONNECT_DATA=(SERVICE_NAME=<Client_Failover_Service_Name>)
(SERVER=DEDICATED)(FAILOVER_MODE=(TYPE=session)(METHOD=BASIC)(RETRIES=180)
(DELAY=5))))
The user name and password of the existing Windchill database user in the User Name and Password fields.
Configuring an Existing Windchill Oracle Database for use with Oracle Data Guard
Complete the following steps to configure an existing Windchill Oracle database for use with Oracle Data Guard.
1. Stop Windchill.
2. Back up the existing Windchill database, and verify that the backup is valid.
3. Configure and verify Oracle Data Guard following the information provided by Oracle: https://docs.oracle.com/database/121/SBYDB/create_ps.htm
* 
PTC strongly recommends selecting MaxProtection as the Data Guard Protection mode to avoid any data inconsistencies immediately after a database failover. While assuring data consistency, this protection mode can negatively affect overall system performance.
4. Configure the client failover service for Oracle Data Guard using the Client Failover Best Practices white paper for JDBC applications provided by Oracle (http://www.oracle.com/technetwork/database/features/availability/maa-wp-11gr2-client-failover-173305.pdf) or Oracle support documents 461874.1 or 1429223.1.
5. From a Windchill shell, run the following command to set the needed properties, replacing the variables with values appropriate for your system:
xconfmanager -s wt.pom.dbConnectionRetryCount=60 -t "db/db.properties"
xconfmanager -s
wt.pom.jdbc.host="(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)
(HOST==<Primary_DB_Host>)(PORT=<Listener_Port>))
(ADDRESS=(PROTOCOL=TCP)(HOST=<Standby_DB_Host>)
(PORT=<Listener_Port>)))
(CONNECT_DATA=(SERVICE_NAME=<Client_Failover_Service_Name>)
(SERVER=DEDICATED)(FAILOVER_MODE=(TYPE=session)(METHOD=BASIC)(RETRIES=180)
(DELAY=5))))" -t "db/db.properties"
xconfmanager -s wt.pom.jdbc.port="" -t "db/db.properties"
xconfmanager -s wt.pom.jdbc.service="" -t "db/db.properties"
xconfmanager -p
6. Start Windchill.
7. Verify that all Windchill functionality works as expected.