Skip to content

Document multi-db tns admin #269

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 23, 2025
Merged

Document multi-db tns admin #269

merged 2 commits into from
Jun 23, 2025

Conversation

anders-swanson
Copy link
Member

fixes #262

Signed-off-by: Anders Swanson <anders.swanson@oracle.com>
@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Jun 23, 2025

3. In the combined `tnsnames.ora` file, and add the following snippet to each tns alias connection string, to tell the client where the wallet directory is:

(security=(MY_WALLET_DIRECTORY=/path/to/this/database/wallet))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

needs the ```

README.md Outdated
@@ -811,9 +845,75 @@ log:
# disable: 0
```

#### Configuring connections for multiple databases using Oracle Database wallet(s)

The Oracle Database Metrics exporter uses ODPI-C, which can only initalize the TNS aliases from a `tnsnames.ora` file once per process. To work around this, the exporter can be configured to read from a "combined" `tnsnames.ora` file containing all tns aliases for connections in a multi-database configuration.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tns should be caps.

README.md Outdated

The Oracle Database Metrics exporter uses ODPI-C, which can only initalize the TNS aliases from a `tnsnames.ora` file once per process. To work around this, the exporter can be configured to read from a "combined" `tnsnames.ora` file containing all tns aliases for connections in a multi-database configuration.

1. For each database the exporter will connect to, download the corresponding wallet files. If you're using ADB/ATP-S, download the regional wallet instead of the instance wallet IFF the databases are in the same region.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

keep iff iff you are confident everyone knows what iff means

README.md Outdated
db2_high = (description= (retry_count=20)(retry_delay=3)(address=(protocol=tcps)(port=1522)(host=adb.****.oraclecloud.com))(connect_data=(service_name=****.adb.oraclecloud.com))(security=(MY_WALLET_DIRECTORY=/wallets/db2)(ssl_server_dn_match=yes)))
```

4. Take wallet files (cwallet.sso ewallet.p12 ewallet.pem) for each database, and place them in separate directories. E.g., db1 gets its own directory, db2 gets its own directory, and so forth.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i'd put comments between file names

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

e.g. capitalization

Signed-off-by: Anders Swanson <anders.swanson@oracle.com>
@anders-swanson anders-swanson merged commit ae5164b into main Jun 23, 2025
1 check passed
@anders-swanson anders-swanson deleted the docu-multidb-tnsadmin branch June 23, 2025 19:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TNS Admin failing in Multi-DB setup
2 participants