Cannot launch Fiji from Ubuntu repository

255 views
Skip to first unread message

google...@plast.id.au

unread,
May 12, 2013, 8:33:06 AM5/12/13
to fiji-...@googlegroups.com
Hi,

I cannot seem to launch Fiji after downloading the Ubuntu repository version as specified on the download page.

As per the existing bug about specifying the java installation here <https://groups.google.com/forum/?fromgroups=#!topic/fiji-devel/7cZ8SuIzwEg>, I specified my java installation in /etc/default/fiji, trying Oracle 7, and OpenJDK 6 and 7. No matter which I used, I could not get Fiji to start. I tried specifying my java installation in the same way on another computer, and this worked fine. I'll attach the console errors below, for each of the three java directories.


/opt/java/32/jre1.7.0_21

$ fiji
Exception in thread "main" java.lang.NoClassDefFoundError: fiji/Main
Caused by: java.lang.ClassNotFoundException: fiji.Main
    at java.net.URLClassLoader$1.run(Unknown Source)
    at java.net.URLClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
Could not find fiji/Main

/usr/lib/jvm/java-6-openjdk-i386

$ fiji
Exception in thread "main" java.lang.NoClassDefFoundError: fiji/Main
Caused by: java.lang.ClassNotFoundException: fiji.Main
    at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find fiji/Main

/usr/lib/jvm/java-7-openjdk-i386

$ fiji
Exception in thread "main" java.lang.NoClassDefFoundError: fiji/Main
Caused by: java.lang.ClassNotFoundException: fiji.Main
    at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
Could not find fiji/Main

How can I get Fiji to start?

google...@plast.id.au

unread,
May 17, 2013, 12:56:55 AM5/17/13
to fiji-...@googlegroups.com
Optimistic bump. Also, I tried installing imagej from the official Ubuntu repositories, and that runs fine, so presumably I *am* running into a Fiji bug.

Cheers.

Johannes Schindelin

unread,
May 17, 2013, 4:46:49 PM5/17/13
to google...@plast.id.au, fiji-...@googlegroups.com
Hi googlegroups,

On Thu, 16 May 2013, google...@plast.id.au wrote:

> Optimistic bump. Also, I tried installing imagej from the official
> Ubuntu repositories, and that runs fine, so presumably I *am* running
> into a Fiji bug.

Have you tried to run any of the recommended downloads from
http://fiji.sc/Downloads?

If so, I would suggest running with them for now, unless you have
resources to work on fixing the Debian packages.

Thanks,
Johannes

Curtis Rueden

unread,
May 17, 2013, 5:15:08 PM5/17/13
to Johannes Schindelin, google...@plast.id.au, Fiji Developers
Hi googlegroups & Dscho,

> If so, I would suggest running with them for now, unless you have
> resources to work on fixing the Debian packages.

To better reflect the situation with the Debian packages, I added a blurb to the Downloads page explaining that we currently do not have the resources to fix them.

> $ fiji
> Exception in thread "main" java.lang.NoClassDefFoundError: fiji/Main

Packaging Fiji according to Debian best practices ends up being an insanely complicated problem. It not too surprising that things aren't fully working right now, since the Fiji build system has undergone substantial changes since those packages were actively developed. 

That said, did you try "fiji --dry-run"? It should spit out the full command line that will actually be used to launch the JVM (with the caveat that it does so not via exec, but rather by dynamically linking to the Java native library). It might shed some light on things.

Regards,
Curtis



--
--
Please avoid top-posting, and please make sure to reply-to-all!

Mailing list web interface: http://groups.google.com/group/fiji-devel

---
You received this message because you are subscribed to the Google Groups "Fiji-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fiji-devel+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



google...@plast.id.au

unread,
May 20, 2013, 2:36:24 AM5/20/13
to Curtis Rueden, Johannes Schindelin, Fiji Developers
Thank you both for the help.


On 18/05/13 07:15, Curtis Rueden wrote:
Hi googlegroups & Dscho,

> If so, I would suggest running with them for now, unless you have
> resources to work on fixing the Debian packages.

To better reflect the situation with the Debian packages, I added a blurb to the Downloads page explaining that we currently do not have the resources to fix them.

I was indeed confused at first, because the recommendation was to install from the Ubuntu repository. Manually downloading the version from the Fiji webpage works fine for me.


> $ fiji
> Exception in thread "main" java.lang.NoClassDefFoundError: fiji/Main

Packaging Fiji according to Debian best practices ends up being an insanely complicated problem. It not too surprising that things aren't fully working right now, since the Fiji build system has undergone substantial changes since those packages were actively developed. 

That said, did you try "fiji --dry-run"? It should spit out the full command line that will actually be used to launch the JVM (with the caveat that it does so not via exec, but rather by dynamically linking to the Java native library). It might shed some light on things.

I just realised that I ran into some errors in installation through the repos. Hence, I installed fiji-base instead of fiji. Here are the errors, and here is the output of `fiji --dry-run`

$ sudo apt-get install fiji
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 fiji : Depends: fiji-tracer (>= 20110603170739) but it is not going to be installed
        Depends: fiji-trakem2 (>= 20110608182633) but it is not going to be installed
        Depends: fiji-plugins (>= 20110605200331) but it is not going to be installed
        Depends: fiji-scripting (>= 20110531182644) but it is not going to be installed
        Depends: fiji-vib (>= 20110609114510) but it is not going to be installed
        Depends: fiji-3d-viewer (>= 20110526092926) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

$ sudo apt-get install fiji-base

$ sudo vim /etc/default/fiji

$ fiji
Exception in thread "main" java.lang.NoClassDefFoundError: fiji/Main
Caused by: java.lang.ClassNotFoundException: fiji.Main
    at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find fiji/Main
$ fiji --dry-run
java -Dpython.cachedir.skip=true -Dplugins.dir=/usr/lib/fiji/ -Xmx1321m -Xincgc -XX:PermSize=128m -Djava.class.path=/usr/share/java/postgresql.jar:/usr/share/java/bsh.jar:/usr/share/java/jcommon.jar:/usr/share/java/jfreechart.jar:/usr/share/java/jzlib.jar:/usr/share/java/vecmath.jar:/usr/share/java/junit4.jar:/usr/share/java/itext1.jar:/usr/share/java/jama.jar:/usr/share/java/j3dutils.jar:/usr/share/java/clojure.jar:/usr/share/java/xml-apis-ext.jar:/usr/share/java/jsch.jar:/usr/lib/jvm/java-6-openjdk/lib/tools.jar:/usr/share/java/jna.jar:/usr/share/java/batik-all.jar:/usr/share/java/js.jar:/usr/share/java/j3dcore.jar:/usr/lib/fiji//jars/Fiji.jar:/usr/lib/fiji//jars/ij.jar -Dfiji.debian=true -Dsun.java.command=Fiji -Dfiji.dir=/usr/lib/fiji/ -Dfiji.defaultLibPath=lib/i386/client/libjvm.so -Dfiji.executable=/usr/lib/fiji/fiji -Djava.library.path=::/usr/lib/fiji/lib/linux32 fiji.Main -port7


Here is the output of dry-run for the manual installation (which works).
$ ./ImageJ-linux32 --dry-run
java -Dpython.cachedir.skip=true -Dplugins.dir=/home/me/Applications/Fiji.app -Xmx1336m -Xincgc -XX:PermSize=128m -Dsun.java.command=ImageJ -Djava.class.path=/home/me/Applications/Fiji.app/jars/ij-launcher-2.0.0-SNAPSHOT.jar -Dimagej.dir=/home/me/Applications/Fiji.app -Dij.dir=/home/me/Applications/Fiji.app -Dfiji.dir=/home/me/Applications/Fiji.app -Dfiji.defaultLibPath=lib/i386/client/libjvm.so -Dfiji.executable=./ImageJ-linux32 -Dij.executable=./ImageJ-linux32 -Djava.library.path=/home/me/Applications/Fiji.app/lib/linux32 imagej.ClassLauncher -classpath /home/me/Applications/Fiji.app/jars/ij-1.47q.jar fiji.Main -port7

Curtis Rueden

unread,
May 24, 2013, 12:17:39 PM5/24/13
to google...@plast.id.au, Johannes Schindelin, Fiji Developers
Hi googlegroups,

FYI, after some discussion on IRC, the relevant developers decided to discontinue the Fiji Debian packages for now. The Fiji Downloads page has been updated accordingly.

Regards,
Curtis


google...@plast.id.au

unread,
May 24, 2013, 8:56:47 PM5/24/13
to Curtis Rueden, Johannes Schindelin, Fiji Developers

On 25/05/13 02:17, Curtis Rueden wrote:
> Hi googlegroups,
>
> FYI, after some discussion on IRC, the relevant developers decided to
> discontinue the Fiji Debian packages for now. The Fiji Downloads page
> has been updated accordingly.
>
> Regards,
> Curtis
>

Ah okay. That's actually a bit of a shame, since the packages work
perfectly fine on my other machine (Dell XPS 17 l702x running Kubuntu
13.04 64-bit). It's only my Eee PC 1000H running Xubuntu 13.04 32-bit
that doesn't work. Still, I understand why you would do this, for
consistency.

Cheers, and thanks for all the help.

Johannes Schindelin

unread,
May 25, 2013, 11:27:57 AM5/25/13
to google...@plast.id.au, Curtis Rueden, Fiji Developers
Hi googlegroups,

On Sat, 25 May 2013, google...@plast.id.au wrote:

> On 25/05/13 02:17, Curtis Rueden wrote:
>
> > FYI, after some discussion on IRC, the relevant developers decided to
> > discontinue the Fiji Debian packages for now. The Fiji Downloads page
> > has been updated accordingly.
>
> Ah okay. That's actually a bit of a shame, since the packages work
> perfectly fine on my other machine (Dell XPS 17 l702x running Kubuntu
> 13.04 64-bit). It's only my Eee PC 1000H running Xubuntu 13.04 32-bit
> that doesn't work. Still, I understand why you would do this, for
> consistency.

Again, feel free to work on this yourself. Would make for a fine way to
say thanks for all the work other people put into Fiji.

Ciao,
Johannes

google...@plast.id.au

unread,
May 27, 2013, 6:07:43 AM5/27/13
to Johannes Schindelin, Curtis Rueden, Fiji Developers
Unfortunately, I lack the programming skills necessary. My method of
saying "thanks" is limited to reporting bugs, and some basic testing.
Thanks again for the help, though!

Cheers!
Reply all
Reply to author
Forward
0 new messages