Install Oracle client on Ubuntu

SQL Developer

Install SQL Developer on Ubuntu

Using the OCI/thick client

  1. Install the Oracle client (see above)

  2. Close SQL Developer

  3. Run this command to configure java.library.path

    echo "AddVMOption -Djava.library.path=/usr/lib/oracle/12.1/client64/lib" >> ~/.sqldeveloper/19.4.0/product.conf

    Change the paths as necessary

  4. Open SQL Developer

  5. Tools > Preferences > Database > Advanced

  6. Check Use Oracle Client

  7. Configure

    1. Client Type > Instant Client

    2. Client Location: /usr/lib/oracle/12.1/client64/lib

    3. Click Test and make sure there are no errors

    4. Click OK

  8. Check Use OCI/Thick driver, OK

Viewing tables

  1. In the Connections view on the left, expand Tables under the applicable database connection

    • If you don’t see the table you’re looking for, it may be under a different user. Expand Other Users under the connection name and then expand Tables under the applicable user.

    • It may also be useful to look in Views in case the table you’re looking for is actually a view

      • If you still don’t see the table you’re looking for, you may not have permissions to see it (although you may still be able to query it)

Working with packages

  1. In a SQL tab, type the name of the package

  2. Right-click on the package name > Popup Describe to view the function declarations in the package

  3. Near the top of the package tab that opens up, click Open Body to view the source

    • If you click Open Body and nothing happens, it’s possible your user does not have permissions to view the package body


Run Oracle Database XE (Express Edition) in a container

  1. Check out Oracle’s container image repo

    git clone
    cd docker-images/OracleDatabase/SingleInstance/dockerfiles
  2. For, download the Oracle DB XE binaries and copy to docker-images/OracleDatabase/SingleInstance/dockerfiles/

  3. Build the container image

    • 18

      ./ -v 18.4.0 -x -o --network=host

      (-o --network=host is only required if you’re using Docker with iptables: false)

    • 11

      ./ -v -x -o --network=host
  4. Run the container

    • Run it just once and automatically delete it when it’s stopped

      • 18

        docker run --rm -p 1521:1521 oracle/database:18.4.0-xe
      • 11

        docker run --rm --shm-size=1g -p 1521:1521 oracle/database:
    • Stop the container using Ctrl+C

    • Run it so it can be stopped and restarted

      • Run it the first time

        • 18

          docker run --name oracledb -p 1521:1521 oracle/database:18.4.0-xe
        • 11

          docker run --name oracledb --shm-size=1g -p 1521:1521 -e oracle/database:
      • Run it after it’s been stopped


        docker container start -a oracledb
      • Delete it when you’re finished


        docker container rm oracledb
  5. Connect to the database

    • If no password is provided, one will be generated and printed near the top of the output of docker run
    • SID: XE
    • User: system