I recently installed Ubuntu 11.10 with a lot of hesitation. After the upgrade, I realised why I was hesitating. Somewhere in the back of my mind, I had this feeling that something won’t work. To say the least, Unity on Ubuntu 11.10 is rubbish and I absolutely hated it. I thought I will do the same thing that I did previously, revert to the classic desktop. However, the classic desktop is not that nice with Ubuntu 11.10. Long story short, I have moved onto to Xfce 4.8 and I absolutely love it. Clean, classic style.
Coming back to the topic of this post, I needed to install Oracle’s SQL Developer. As I did a clean install of Ubuntu, I first needed to install JDK. I decided to go with Oracle’s JDK 1.7. Here is how I installed it.
For Ubuntu 11.10 64 bit OS, download and extract the right version of JDK for your platform.
http://www.oracle.com/technetwork/java/javase/downloads/jdk-7u1-download-513651.html
Copy the extracted directory to /usr/lib and follow the steps as shown below:
masud@masud:/opt$ sudo mv jdk1.7.0_01/ jdk1.7.0 masud@masud:/opt$ ls jdk1.7.0 masud@masud:/opt$ sudo mv jdk1.7.0/ /usr/lib masud@masud:/opt$ ls masud@masud:/opt$ sudo update-alternatives --install "/usr/bin/java" "java" "/usr/lib/jdk1.7.0/bin/java" 1 masud@masud:/opt$ sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/lib/jdk1.7.0/bin/javac" 1 update-alternatives: using /usr/lib/jdk1.7.0/bin/javac to provide /usr/bin/javac (javac) in auto mode. masud@masud:/opt$ sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/lib/jdk1.7.0/bin/javaws" 1 masud@masud:/opt$ sudo update-alternatives --config java There are 2 choices for the alternative java (providing /usr/bin/java). Selection Path Priority Status ------------------------------------------------------------ * 0 /usr/lib/jvm/java-6-openjdk/jre/bin/java 1061 auto mode 1 /usr/lib/jdk1.7.0/bin/java 1 manual mode 2 /usr/lib/jvm/java-6-openjdk/jre/bin/java 1061 manual mode Press enter to keep the current choice[*], or type selection number: 1 update-alternatives: using /usr/lib/jdk1.7.0/bin/java to provide /usr/bin/java (java) in manual mode. masud@masud:/opt$ java -version java version "1.7.0_01" Java(TM) SE Runtime Environment (build 1.7.0_01-b08) Java HotSpot(TM) 64-Bit Server VM (build 21.1-b02, mixed mode) masud@masud:/opt$ sudo update-alternatives --config javac There is only one alternative in link group javac: /usr/lib/jdk1.7.0/bin/javac Nothing to configure. masud@masud:/opt$ sudo update-alternatives --config javaws There are 2 choices for the alternative javaws (providing /usr/bin/javaws). Selection Path Priority Status ------------------------------------------------------------ * 0 /usr/lib/jvm/java-6-openjdk/jre/bin/javaws 1061 auto mode 1 /usr/lib/jdk1.7.0/bin/javaws 1 manual mode 2 /usr/lib/jvm/java-6-openjdk/jre/bin/javaws 1061 manual mode Press enter to keep the current choice[*], or type selection number: 1 update-alternatives: using /usr/lib/jdk1.7.0/bin/javaws to provide /usr/bin/javaws (javaws) in manual mode. masud@masud:/opt$
Now download the Oracle’s SQL Developer package for your system from the following address.
http://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/index.html
Now go through the following steps:
masud@masud:~/Downloads$ sudo mv sqldeveloper /usr/lib masud@masud:~/Downloads$ cd /usr/lib masud@masud:/usr/lib$ cd sqldeveloper/ masud@masud:/usr/lib/sqldeveloper$ ls dataminer ide jdbc jdev.label jviews modules readme.html sqldeveloper sqldeveloper.sh timingframework icon.png j2ee jdev jlib lib rdbms sleepycat sqldeveloper.exe sqlj view-source-paths.lis masud@masud:/usr/lib/sqldeveloper$ ls -lrt sqldeveloper.sh -rw-r--r-- 1 masud masud 71 2011-03-25 14:59 sqldeveloper.sh masud@masud:/usr/lib/sqldeveloper$ chmod +x sqldeveloper.sh masud@masud:/usr/lib/sqldeveloper$ ./sqldeveloper.sh Oracle SQL Developer Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. masud@masud:/usr/lib/sqldeveloper$
You may get a message by SQL Developer that version 1.7 of Java is not supported at this time.