SQLDev, Ubuntu

Install SQL Developer on Ubuntu 17.04

ubuntu logoLast week I decided to blow away Windows on my ASUS laptop and install a flavor of #Linux. I’ve got a few machines running Oracle Linux so I settled on #Ubuntu. To be more specific:

dbryant@asus:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 17.04
Release: 17.04
Codename: zesty

As a person that spends a significant amount working in the Oracle database, I really needed to get #SQLDeveloper going. Unfortunately, the Linux RPM version won’t work so I need to go grab the ‘Other Platforms’ version for this install. At the time of this post, the current version is sqldeveloper-17.2.188.1159-no-jre.zip. So go ahead and download that from the Oracle OTN Downloads site. You will need to either login or create a free account to complete the download. While you are downloading, you may need to go ahead and install JAVA by issuing the following commands:

dbryant@asus:~$ sudo apt-get update

dbryant@asus:~$ sudo apt-get install default-jdk

Once the SQL Developer zip file downloads execute the following steps to unzip the file in the proper location in the file system:

dbryant@asus:~$ cd Downloads (or wherever you decided to download the zip file)
dbryant@asus:~$ sudo mv sqldeveloper*.zip /usr/local/bin
dbryant@asus:~$ cd /usr/local/bin
dbryant@asus:~$ sudo unzip sqldeveloper-17.2.188.1159-no-jre.zip
dbryant@asus:~$ sudo ln -s /usr/local/bin/sqldeveloper/sqldeveloper.sh /bin/sqldeveloper
dbryant@asus:~$ sudo rm /usr/local/bin/sqldeveloper*.zip (only if you want to get rid of the zip file)

Now lets make a small edit to the sqldeveloper.sh script

dbryant@asus:~$ sudo vi /usr/local/bin/sqldeveloper/sqldeveloper.sh

#!/bin/bash
cd "dirname $0"/sqldeveloper/bin && bash sqldeveloper $*

Change the line above to:

#!/bin/bash
cd /usr/local/bin/sqldeveloper/sqldeveloper/bin && bash sqldeveloper $*

You can now launch SQL Developer:

dbryant@asus:~$ sqldeveloper

When you first run SQL Developer, you will be prompted for the path to the JDK installation.

dbryant@asus:~$ cd /usr/lib/jvm

dbryant@asus:/usr/lib/jvm$ ls
default-java  java-1.8.0-openjdk-amd64  java-8-openjdk-amd64

Copy and paste this: /usr/lib/jvm/java-1.8.0-openjdk-amd64 in the dialog box.

At this point, you should have a successful launch of SQL Developer in #Ubuntu 17.04

ubuntu_sqldev

Enjoy!dbaontap

Related Posts Plugin for WordPress, Blogger...

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.