2.1.2 Autonomous Database
If you are using an Autonomous Database as a Metadata store, the Oracle Stream Analytics platform reads and writes all its meta-data to an Autonomous Database that is fully managed by Oracle.
- Stop GGSA by running the command
sudo systemctl stop osa
- Comment the MySQL section in
jetty-osa-datasource.xml
file as shown below.<?xml version="1.0"?> <!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure_9_3.dtd"> <Configure id="Server" class="org.eclipse.jetty.server.Server"> <!-- <New id="osads" class="org.eclipse.jetty.plus.jndi.Resource"> <Arg> <Ref refid="wac"/> </Arg> <Arg>jdbc/OSADataSource</Arg> <Arg> <New class="com.mysql.cj.jdbc.MysqlConnectionPoolDataSource"> <Set name="URL">jdbc:mysql://localhost:3306/OSADB</Set> <Set name="User">osa</Set> <Set name="Password"> <Call class="org.eclipse.jetty.util.security.Password" name="deobfuscate"> <Arg>OBF:{OBFUSCATED_PASSWORD}</Arg> </Call> </Set> <Set name="maxAllowedPacket">209715200</Set> <Set name="allowPublicKeyRetrieval">true</Set> </New> </Arg> </New> --> </Configure>
- Add the following section for Oracle database right below the commented section.
<New id="osads" class="org.eclipse.jetty.plus.jndi.Resource"> <Arg> <Ref refid="wac"/> </Arg> <Arg>jdbc/OSADataSource</Arg> <Arg> <New class="oracle.jdbc.pool.OracleDataSource" type="adw"> <Set name="URL">jdbc:oracle:thin:@{service_name}?TNS_ADMIN={wallet_absolute_path}</Set> <Set name="User">osa</Set> <Set name="Password"> <Call class="org.eclipse.jetty.util.security.Password" name="deobfuscate"> <Arg>OBF:{obfuscated_password}</Arg> </Call> </Set> <Set name="connectionCachingEnabled">true</Set> <Set name="connectionCacheProperties"> <New class="java.util.Properties"> <Call name="setProperty"><Arg>MinLimit</Arg><Arg>1</Arg></Call> <Call name="setProperty"><Arg>MaxLimit</Arg><Arg>15</Arg></Call> <Call name="setProperty"><Arg>InitialLimit</Arg><Arg>1</Arg></Call> </New> </Set> </New> </Arg> </New>
- Replace the following variables in above XML with actual values:
-
service_name
– one of the service names listed in tnsnames.ora file inside the wallet wallet_absolute_path
– the absolute path of wallet folder on the machine where osa is installedobfuscated_password
– the obfuscated password for user ‘osa’. See the previous section on how to generate an obfuscated password
-
- The next step is to initialize the metadata store and set the password for user osaadmin.
Note:
You will need database administrator credentials with sysdba privileges to perform this step.- Change directory to
/u01/app/osa/osa-base/bin
- Execute
./start-osa.sh dbroot=<db sys user> dbroot_password=<db sys password> osaadmin_password=${OSA_ADMIN_PASSWORD}
- Execute
./stop-osa.sh
- Execute
sudo systemctl start osa
, to start GGSA as a system service
- Change directory to