> For the complete documentation index, see [llms.txt](https://docs.tessell.com/tessell/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tessell.com/tessell/database-engines/tessell-for-oracle/database-connections-using-ssl-tls/linux-platform.md).

# Linux platform

This guide covers connecting to a Tessell Oracle database service over SSL/TLS on Linux using SQL\*Plus.

***

## Step 1 — Install tools

1. Download and unzip the Oracle Instant Client from [Oracle Instant Client Downloads (Linux x86-64)](https://www.oracle.com/cis/database/technologies/instant-client/linux-x86-64-downloads.html).
2. Download and unzip SQLcl from [Oracle SQLcl Downloads](https://www.oracle.com/database/sqldeveloper/technologies/sqlcl/download/).

For example:

* Instant Client: `/home/ubuntu/<user>/instantclient_21_9`
* SQLcl: `/home/ubuntu/<user>/sqlcl`

***

## Step 2 — Set up `orapki`

Installing `orapki` directly from Oracle requires the full Fusion Middleware package. Use the following script instead to simulate `orapki` via SQLcl's bundled JARs:

```bash
#!/bin/bash
# set classpath for orapki - align this to your local SQLcl installation
SQLCL=<sqlcl unzipped path>/lib/   # e.g. /home/ubuntu/<user>/sqlcl/lib/
CLASSPATH=${SQLCL}/oraclepki.jar:${SQLCL}/osdt_core.jar:${SQLCL}/osdt_cert.jar
# simulate orapki command
java -classpath ${CLASSPATH} oracle.security.pki.textui.OraclePKITextUI "$@"
```

```bash
# Make orapki executable
chmod +x orapki
```

***

## Step 3 — Download the CA certificate

Download the CA certificate from the **Overview** tab of your DB service in Tessell (**My Services → Overview → CA Certificate**).

<div align="center"><img src="https://3421475909-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FXNKiIctERJykfezXfUU2%2Fuploads%2Fgit-blob-e164e1fc0feb4656cf68402a48eba3800c20a5a8%2Fimage.png?alt=media" alt="" width="800"></div>

<p align="center"><em>Figure 1 — CA Certificate download on the service Overview page</em></p>

***

## Step 4 — Create the Oracle wallet and import the certificate

1. Create the wallet directory:

```bash
./orapki wallet create -wallet /home/ubuntu/<user>/wallet/ -auto_login_only
```

2. Import the Tessell CA certificate:

```bash
./orapki wallet add -wallet /home/ubuntu/<user>/wallet/ -trusted_cert -cert TessellCA.crt -auto_login_only
```

3. Verify the certificate was imported:

```
./orapki wallet display -wallet /home/ubuntu/<user>/wallet/
Oracle PKI Tool Release 21.0.0.0.0 - Production
Version 21.0.0.0.0
Copyright (c) 2004, 2022, Oracle and/or its affiliates. All rights reserved.
Requested Certificates:
User Certificates:
Trusted Certificates:
Subject:        CN=tessell.com
```

***

## Step 5 — Configure `sqlnet.ora`

Create a `sqlnet.ora` file in `<instant_client_path>/network/admin` with the following content:

```
WALLET_LOCATION =
  (SOURCE =
   (METHOD = FILE)
   (METHOD_DATA =
    (DIRECTORY = /Users/<user>/orainscli/test_wallet)
   )
  )
SQLNET.AUTHENTICATION_SERVICES = (TCPS,NTS,BEQ)
SSL_CLIENT_AUTHENTICATION = FALSE
SSL_CIPHER_SUITES = (SSL_RSA_WITH_AES_256_CBC_SHA, SSL_RSA_WITH_3DES_EDE_CBC_SHA)
SSL_SERVER_DN_MATCH = ON
```

***

## Step 6 — Connect using SQL\*Plus

1. Download and install the SQL\*Plus package.
2. Set `ORACLE_HOME` to the Instant Client directory:

```bash
export ORACLE_HOME=/home/ubuntu/<user>/instantclient_21_9
```

3. Confirm `sqlnet.ora` is present in `$ORACLE_HOME/network/admin`.
4. Connect to the database:

```
sqlplus <user>/<password>@(DESCRIPTION = (ADDRESS = (PROTOCOL = TCPS)(HOST = oraclessl<service name>dnd-efwyu.qarel.tsl-barc.cloud)(PORT = 1521))(CONNECT_DATA = (SERVICE_NAME = <service name>))(SECURITY = (SSL_SERVER_CERT_DN = "CN=oraclessl<service name>dnd-efwyu.qarel.tsl-barc.cloud")))
```

> **Tip:** The Tessell service Overview page provides a pre-configured connection string you can use as a starting point.

5. Verify the connected protocol:

```sql
SELECT sys_context('USERENV', 'NETWORK_PROTOCOL') as network_protocol,
       sys_context('USERENV', 'AUTHENTICATION_METHOD') as authentication_method
FROM dual;
```

Expected output:

```
NETWORK_PROTOCOL                    AUTHENTICATION_METHOD
----------------------------------- -----------------------------------
tcps                                PASSWORD
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.tessell.com/tessell/database-engines/tessell-for-oracle/database-connections-using-ssl-tls/linux-platform.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
