[Important] Workaround for Cytoscape + Latest Version of Apple Java VM Problem

29 views
Skip to first unread message

Keiichiro Ono

unread,
Jun 17, 2009, 1:40:09 PM6/17/09
to cytoscap...@googlegroups.com
Hi.
Apple had released latest version of Java updates last week, and it
breaks lots of things in Cytoscape. If you use Leopard (OS X 10.5.x)
on 64-bit Intel chip machine (Core 2 Duo or later), you can avoid this
issue by using 64-bit version of Java 6. you can switch the Java
runtime by the following steps:

1. Go to Application-->Utilities
2. Double-click Java Preferences
3. For Java Applications, drag-and-drop Java SE 6 to the top of the list.
4. Exit from Java Preferences
5. Go to terminal (Applications-->Utilities) and type "java -version"
6. If you can see the following, your machine is configured to use Java 6:

gamay:MCODE2 kono$ java -version
java version "1.6.0_13"
Java(TM) SE Runtime Environment (build 1.6.0_13-b03-211)
Java HotSpot(TM) 64-Bit Server VM (build 11.3-b02-83, mixed mode)

For older machine users, we have not figured out how to solve this issue yet.
Sorry for the trouble.

Thanks.
Kei

--
Keiichiro Ono ko...@ucsd.edu

Cytoscape Core Developer Team: http://www.cytoscape.org/
UCSD Bioengineering Ideker Lab: http://chianti.ucsd.edu/idekerlab/

Michi

unread,
Jun 19, 2009, 5:07:33 AM6/19/09
to cytoscape-discuss
On a colleagues Mac we a have set up java like you wrote above but
when we start Cytoscape by clicking on its icon it seems to start in
java5.
My plugin uses java6 and I suppose therefore I get the error "
java.lang.UnsupportedVersionError: Bad version number in .class
file...." when loading my plugin.
To get around this error we start Cyptoscape from by skript (or in the
console) with the command in the cytoscape.sh file:
java -Dswing.aatext=true -Xss5M -Xmx512M -jar cytoscape.jar
cytoscape.CyMain -p plugins "$@"
Then Cytoscape doesn't come up with the error and all seems to work
fine.

Is there another way of telling the Mac to use java6 for Cytoscape or
is this behaviour caused by the installer or dmg file.

Michael
Message has been deleted

Gary Bader

unread,
Jun 20, 2009, 11:41:07 AM6/20/09
to cytoscap...@googlegroups.com
Hi Michael - you can tell the Mac to use Java 6 (or any supported
version) by default using the "Java Preferences" application, which is
in /Applications/Utilities/Java/.

Gary
--
http://baderlab.org
Terrence Donnelly Centre for Cellular and Biomolecular Research
University of Toronto

phlampe

unread,
Jun 24, 2009, 5:33:53 AM6/24/09
to cytoscape-discuss
In my case, I have a Mac Pro with Mac OS 10.5.7 installed, and even
after the last java update, a "java -version" at the command line kept
returning version 1.5, and even after changing the order with the Java
Preferences app.

The fix for this Java home problem selection, from Apple's Java
discussion list (see http://discussions.apple.com/thread.jspa?messageID=9657716
), is to use the new java_home utility to assign the good value in the
JAVA_HOME environment variable.

To do that, edit your .profile file (in your home directory), and
change the JAVA_HOME line from:
export JAVA_HOME=/Library/Java/Home

to (notice the backquotes):
export JAVA_HOME=`/usr/libexec/java_home`

I don't know why I had that hard-coded JAVA_HOME assignment in my
profile, maybe from some old installations or maybe it's just normal.

Cytoscape worked well afterwards.

Paul-Henri
> --http://baderlab.org

Keiichiro Ono

unread,
Jun 24, 2009, 1:17:54 PM6/24/09
to cytoscap...@googlegroups.com
Hi.
All of Apple Java2D problems we are experiencing now are the known
issues and users of other software (such as Taverna) have same
problems. Some discussions are going on in Apple's discussion board:

http://lists.apple.com/archives/Java-dev/2009/Jun//msg00291.html

I hope Apple releases a new patch soon...

Kei

2009/6/24 phlampe <paulhen...@gmail.com>:

biodan653

unread,
Jun 25, 2009, 12:57:35 AM6/25/09
to cytoscape-discuss
I use 2.6.2 at home on a MacBook Pro on 10.5.7. The java fix above
works for me but i'm still having issues with dialogs having
unpredictable sizes. For example, the ManagePlugins dialog is about
3000 pixels wide and i still can't see the 'install' button. The
Import Attribute from Table/Excel has similar problems. If i resize
the dialog window, the dialog is filled with white space and i'm in
worse shape.

For a while, i went back to 2.6.1 where the ManagePlugins dialog at
least lets me see the Install button, but the Import Attributes dialog
problem persists.

Are all these issues due to the same Java problem?

BTW, at work i use a Linux workstation where these issues don't
exist.

I realize that i could use my VMware XP environment but performance
would likely suffer (whenever i use VMware even with 2GB ram dedicated
to the virtual environment, the laptop slows down).

On Jun 24, 10:17 am, Keiichiro Ono <kei...@gmail.com> wrote:
> Hi.
> All of Apple Java2D problems we are experiencing now are the known
> issues and users of other software (such as Taverna) have same
> problems.  Some discussions are going on in Apple's discussion board:
>
> http://lists.apple.com/archives/Java-dev/2009/Jun//msg00291.html
>
> I hope Apple releases a new patch soon...
>
> Kei
>
> 2009/6/24 phlampe <paulhenri.la...@gmail.com>:
>
>
>
>
>
> > In my case, I have a Mac Pro with Mac OS 10.5.7 installed, and even
> > after the last java update, a "java -version" at the command line kept
> > returning version 1.5, and even after changing the order with the Java
> > Preferences app.
>
> > The fix for this Java home problem selection, from Apple's Java
> > discussion list (seehttp://discussions.apple.com/thread.jspa?messageID=9657716
> Keiichiro Ono    k...@ucsd.edu
Reply all
Reply to author
Forward
0 new messages