Oracle
DLH.io documentation for Oracle
Oracle RDBMS is one of original enterprise database technologies that exist both on-premise and in the cloud. As a robust platform with maximum efforts focused at the enterprise level, this database technology is capable of transactional and analytical workloads and just about everything in between.
Oracle Specifications Required:
- Versions (10 or above) are supported
- Determine which way to connect: Default or SSH Tunneling
- Firewalls on your database server should allow incoming connections through the public internet on your Oracle port (typically 1521 unless your network team has changed it).
- Be sure to Our IP Grantlist / Whitelist our IP Addresses for cross network database server network access
- Consult with you Oracle administrator as needed on the setup
- We suggest creating a new read-only user to delineate this user service account for DLH.io from any other user access to your database, however, using an existing user is acceptable.
Instructions (Basic Connection Setup)
Remember DLH.io connects to your database instance with credentials supplied by you. We store your credentials securely with our bank-grade protocols.
-
Create a DLH.io user on the Oracle database
-
Connect to the Oracle database in question with your admin user.
-
Create a user for DLH.io using the following Oracle logic replacing <newsername> with you a user name that you choose (we recommend 'DLH.io_ro' to signify a read-only user), and choose a good password that complies with your security policies:
CREATE USER <new_username> IDENTIFIED BY tmp!password; GRANT RESOURCE, CONNECT TO <new_username>@'%';
-
-
**Enter your Credentials and Other Information in the Fields **
- Enter in the Name/Alias field, the name you'll use within DLH.io to differentiate this connection from others
- Enter in the Target Schema Prefix field, is the prefix of schema(s) that gets created on your destination target connection database for each of the schemas you load in this connection. So if your database has a schema named 'dbo' the target connection when synced will have a schema in that target database named the value of this field + '_dbo'.
- Alphanumeric characters only. It must start and end with a letter but can contain an underscore(_).
- Enter in the Server/Host field, the name of the public server name or the IP Address (most customers use the IP for this field)
- Enter in the Port field, where this database is accessible and the firewall restrictions are open
- Enter in the Database field, the name of the database to connect
- Enter in the Userame/Alias field, the username of user you created in the steps above to give access to DLH.io
- Leave Auth Type field alone. It is set to password because DLH.io is using TLS and requires username and password credentials to access the database
- Enter in the Password field, the password for the user you created in the steps above
-
Click Save & Test
- This attempt to connect to your database with the credentials provided.
- A message of success or failure will be shown
- If success you'll be prompted with the schema objects objects of the database and will need to complete the final steps for configuration shown below.
- If failure happens with the test connection, the connection is still saved but you will need to correct the failure based on the failure reason information provided in the message
Instructions (Continued & Final Setup)
This section of steps ensures you have coverage of other important steps required on your database side and in DLH.io once you have completed the above test connection successfully.
Enable LogMiner for Change Tracking
- To capture incremental loading delta changes of the database records being synchronized and to reduce your costs we use the native LogMiner feature of Oracle.
- Connect to your Oracle database server and access the file system
- Enable Supplemental Logging and start LogMiner as an admin user with appropriate privileges:
- ALTER DATABASE ADD SUPPLEMENTAL LOG DATA;
- EXECUTE DBMS_LOGMNR.START_LOGMNR(OPTIONS => DBMS_LOGMNR.DICT_FROM_ONLINE_CATALOG + DBMS_LOGMNR.COMMITTED_DATA_ONLY);
- For more instructions follow the the Oracle documentation or confer with your Oracle DBA
- Restart your Oracle server in order for the changes to propagate
More Specific Configuration
The Oracle database configuration can be time consuming but any Oracle DBA should understand the general concepts of what is required if a system such as DLH.io requires accessing the data tables and retrieving the incremental data changes (i.e.: deltas) to those database tables.
The following goes into more detail for configuration:
- Review the Oracle database-level supplemental logging documentation and ensure this command is run:
ALTER DATABASE ADD SUPPLEMENTAL LOG DATA;
- The above should work to create logs for all tables having a primary key. But, consider the types of tables that will be synchronized by DLH.io. In general synchronizing only tables with a primary key is the easiest approach. But this is not always the case and there are some tables you may wish to include having no primary keys. In the case of the later you will need to enable ALL columns for the supplimental logging for those tables without a PK.
- If you have tables without a PK, then identify those tables and run the following for each of those tables:
ALTER TABLE "<schema>"."<table>" ADD SUPPLEMENTAL LOG DATA (ALL) COLUMNS;
- If for soem reason you didn't want or can't enable supplemental logging at the database level but can do at the table level, then for any tables having a PK, then use this statement for each table:
ALTER TABLE "<schema>"."<table>" ADD SUPPLEMENTAL LOG DATA (PRIMARY KEY) COLUMNS;
- NB: Errors will appear if the logging is not set up correctly. But the logs from DLH.io should be sufficient for you to resolve the issue on your database on your own.
- If you have tables without a PK, then identify those tables and run the following for each of those tables:
- Grant permissions for LOG MINER by running the following statements:
GRANT SELECT ON SYS.V_$ARCHIVED_LOG TO <username>;GRANT SELECT ON SYS.V_$ARCHIVE_DEST TO <username>;GRANT SELECT ON SYS.V_$LOGMNR_CONTENTS TO <username>;GRANT EXECUTE ON DBMS_LOGMNR TO <username>;GRANT EXECUTE ON DBMS_LOGMNR_D TO <username>;GRANT SELECT ANY TRANSACTION TO <username>;GRANT EXECUTE_CATALOG_ROLE TO <username>;- .
- Grant the LogMining permission to the user that will be connecting from DLH.io:
GRANT LOGMINING TO <username>;
- Grant permissions to the user to a few additional system tables. These tables help DLH.io to review more details about the environment that help optimize performance and consistency:
- If using Oracle DB Standalone run the following:
GRANT SELECT ON DBA_FREE_SPACE TO <username>; GRANT SELECT ON SYS.V_$LOG TO <username>; GRANT SELECT ON SYS.V_$TEMPFILE TO <username>; GRANT SELECT ON SYS.V_$DATAFILE TO <username>; - If using Oracle Container DB then run the following first before running the same statement above that you would run for standalone:
ALTER SESSION SET CONTAINER=CDB$ROOT;GRANT SELECT ON DBA_FREE_SPACE TO <username>;GRANT SELECT ON SYS.V_$LOG TO <username>;GRANT SELECT ON SYS.V_$TEMPFILE TO <username>;GRANT SELECT ON SYS.V_$DATAFILE TO <username>;
- Lastly provide permissions for DLH.io to review the databases as the process confirms what type of database it is referencing, container DB, etc.:
GRANT SELECT ON SYS.V_$DATABASE TO <username>;
- If using Oracle DB Standalone run the following:
- That's it. We may update this section from time to time if we find that Oracle versions change the requirements for permissions and as we take feedback from our customers.
Other Information About this Connector
From time to time we will update the instruction set here to inform you about this connection or how specifically we must connect to optimally synchronize your data.
If you require any other type of authorization to connect to your account instance please reach out to our support team via our DLH.io Support Portal.
Issue Handling
If any issues occur with the authorization simply return to the sources page in DLH.io, edit the source details and click the Save & Test or Authorize Your Account or Re-Authorize Account button to confirm connectivity. If any issues persist please contact our support team via the DLH.io Support Portal.