How to install Oracle Sql Developer on Ubuntu ?

This post can be considered as a second part of the new ubuntu success story :
Set a Java Development workstation on Ubuntu

Inspired by : https://forums.oracle.com/forums/thread.jspa?threadID=2302774

Prerequisit

According to the previous choice about the target path ofr all tools, we will install this new tool into the /opt/tools. So if you need to switch to a,nother directory, take care of all path mentioned into this small installation guide.

Install Oracle SQL Developer

Download “Oracle SQL Developer for other platforms” from the Oracle download zone.

Then enter the following commands:

Note:
You may need to change the name according to the current available version.

cd ~/Downloadswget http://download.oracle.com/otn/java/sqldeveloper/sqldeveloper-3.2.20.09.87-no-jre.zipsudo mkdir -p /opt/tools/oraclesudo unzip sqldeveloper-3.2.20.09.87-no-jre.zip -d /opt/tools/oracle/sudo chown -R root:root /opt/tools/oracle/sqldeveloper/sudo chmod -R 755 /opt/tools/oracle/sqldeveloper/

SQL-Developer needs to know how to find your Java Developer Kit:

cd $HOMEmkdir -p .sqldevelopercd $HOME/.sqldeveloperecho "/usr/lib/jvm/java-6-openjdk" > jdk

Note:
To be sure that new user will get the right jdk configuration, you need to execute same commands with the “skel” user path:

cd /etc/skelsudo mkdir -p .sqldevelopersudo cd /etc/skel/.sqldevelopersudo echo "/usr/lib/jvm/java-6-openjdk" > jdk

Create Unity Launcher

Cut & paste the following into a terminal command prompt in oder to register the SQL Developer Launcher:

cd $HOME/Applications/sqldeveloper

Cut and past the following into the terminal:

cat > sqldeveloper.desktop <<EOF [Desktop Entry] Exec=/opt/tools/oracle/sqldeveloper/sqldeveloper.sh %U Terminal=false StartupNotify=true Categories=GNOME;Oracle; Type=Application Icon=/opt/tools/oracle/sqldeveloper/icon.png Name=Oracle SQL Developer EOF

Then continue as following:

sudo cp sqldeveloper.desktop /usr/share/applicationssudo update-desktop-database

last operation

Now that SqlDeveloper is unzip and is well running, you can delete (or not !) the Zip archive:

rm ~/Downloads/sqldeveloper-3.2.20.09.87-no-jre.zip

That’s All Folks,

Have Fun !

McG.

Publicités