Installation of Newbler version 2.5.3 on Ubuntu 10.04.1 (Lucid Lynx) without using the supplied Nixstaller.
Important Note: Do not cut and paste the commands below. Type them in.
Important Note 2: This installation should also work with earlier versions of Ubuntu. Later versions of Ubuntu, 10.04.1 and 10.10 (Maverick Meerkat), did not come with Sun java as did previous versions. I have also tested this installation using java-6-openjdk that comes with 10.04 and 10.10 and it works just fine.
I'm sure there are probably easier/faster ways to accomplish this install, however, this is a tested work around and I have tried and tested. I wrote this with detailed instructions so that those with little or limited unix/linux experience should be able install Newbler without too much difficulty.
My apologies to those who find the step by step approach to be over-kill.
1) Everything needs to be done with root privileges so it's easier to just become root (if you can't this, better stop now and get someone to help you with the install).
2) If you have Newbler already installed, rename the directory opt/454 to something like opt/454_older.ver.number and go to step 3.
If Newbler has never been installed, you will also need to add opt/454/bin to your path. Different ways to do this. I did it by creating an .sh file that contains the path and placing the file in /etc/profile_d
/etc/profile_d~# pico -w 454.sh
Once in the pico editor type the following:
exit editor with CtrlX and yes to save. You will need to log off and then log back on for the path change to take place.
Now open a bash shell and enter echo $PATH at the prompt to verify that the path has been added and become root again.
3) Navigate to the indicated directories below and create the following directories in the indicated locations:
opt/~# mkdir 454
opt/454~# mkdir apps
opt/454/apps~# mkdir jre
4) Copy the Newbler tarball file DataAnalysis.tgz to directory /opt/454 and extract (either at command line using tar -xzvf DataAnalysis.tgz or with the Ubuntu GUI package manager)
5) Remove the file DataAnalysis.tgz after you have extracted it.
6) Navigate to the directory DataAnalysis_2.5.3/packages/ and copy the following .tgz files to the indicated destinations:
/opt/454/DataAnalysis_2.5.3/packages~# cp newbler_CLI-2.5.3.x86_64.tgz ../../
/opt/454/DataAnalysis_2.5.3/packages~# cp assembly_GUI_2.5.3.noarch.tgz ../../apps
/opt/454/DataAnalysis_2.5.3/packages~# cp mapper_GUI_2.5.3.noarch.tgz ../../apps
/opt/454/DataAnalysis_2.5.3/packages~# cp amplicon_GUI_2.5.3.noarch.tgz ../../apps
7) Navigate to the directories shown below and extract the the four tarballs. You should remove each .tgz file after extracting it.
opt/454~# tar -xzvf newbler_CLI-2.5.3.x86_64.tgz
opt/454/apps~# tar -xzvf assembly_GUI_2.5.3.noarch.tgz
opt/454/apps~# tar -xzvf mapper_GUI_2.5.3.noarch.tgz
opt/454/apps~# tar -xzvf ampicon_GUI_2.5.3.noarch.tgz
8) Now remove the directory DataAnalysis_2.5.3 located in opt/454
If you've done everything correctly to this point, your directory structure will look like this:
apps bin config
amplicons assembly jre mapper
Now we need to make multiple symbolic links to get everything to run. You can do this two ways:
A) Use the command gksudo nautilus which opens a GUI with root privileges and then create the the required symbolic links graphically by copying and pasting the target link to its appropriate destination directory.
B) Make the symbolic links at command line (as I have shown).
First make the primary java link:
9) Navigate to the directory /opt/454/apps/jre and create a symbolic link to the java that Ubuntu is using and give it the name of the java directory that Newbler wants to use: jre1.6.0_13
Use either A or B, not both!
A) For early Ubuntu versions with Sun Java
/opt/454/apps/jre~# ln -s /usr/lib/jvm/java-6-sun jre1.6.0_13
B) For later Ubuntu versions without Sun Java installed:
/opt/454/apps/jre~# ln -s /usr/lib/jvm/java-6-openjdk jre1.6.0_13
You can check that the link was made by doing an ls command and you should see one of the following:
jre1.6.0_13 -> usr/lib/jvm/java-6-sun/ OR jre1.6.0_13 -> usr/lib/jvm/java-6-openjdk/
Now, you need to make symbolic links for the three applications (amplicon, assembly, and mapper) back to the link that you just created in /opt/454/apps/jre
(again, you can also do this in Nautilus by just copying the link you created in opt/454/apps/jre and then pasting into the appropriate directories below)
10) Navigate to the directories shown below and create the symbolic link in each as follows:
/opt/454/apps/assembly/jre~# ln -s ../../jre/jre1.6.0_13 jre1.6.0_13
/opt/454/apps/amplicon/jre~# ln -s ../../jre/jre1.6.0_13 jre1.6.0_13
/opt/454/apps/mapper/jre~# ln -s ../../jre/jre1.6.0_13 jre1.6.0_13
Again, an ls command from within each jre directory should show the following:
jre1.6.0_13 -> ../../jre/jre1.6.0_13
Now you need to create the final four symbolic links, these are all from within the /opt/454/bin directory, to the their respective application executables which listed below:
11) Navigate to opt/454/bin and create the following symbolic links:
/opt/454/bin~# ln -s ../apps/assembly/bin/gsAssembler gsAssembler
/opt/454/bin~# ln -s ../apps/mapper/bin/gsMapper gsMapper
/opt/454/bin~# ln -s ../apps/amplicons/bin/gsAmplicon gsAmplicon
/opt/454/bin~# ln -s ../apps/amplicons/bin/doAmplicon doAmplicon
12) Test each program at command line by typing the program name, e.g. gsAssemble, gsMapper, or gsAmplicon.
In each case the GUI should launch. If it doesn't, it is likely due to an error in creation of the symbolic links for either java or the executables.
Note: that doAmplicon is a command line program and does not launch a GUI but goes to a > prompt.