Take the 2-minute tour ×

I recently upgraded to Lion on two of my Macs. Both were previously fully updated Snow Leopard installs. Once Lion was installed I then fired up a web page that required Java, and on both machines Java was downloaded and installed without error. The applet that was trying to run requires 32-bit Java. On both machines, I used the Java Preferences app to switch the priority to 32-bit Java first. On machine A, everything works as expected - running java -version returns "Java HotSpot(TM) Client VM (build 20.1-b02-383, mixed mode)". If I switch to 64-bit Java as the first preference, I get "Java HotSpot(TM) 64-Bit Server VM (build 20.1-b02-383, mixed mode)". This is also the case on machine B. However, if I navigate to http://java.com/en/download/testjava.jsp I get discrepancies.

On machine A, the Architecture is reported correctly as i386 when 32-bit Java is the top priority. However, machine B always reports x86_64, regardless of the order in the preferences app. The behavior is consistent between Chrome, Firefox and Safari. Further, I've tried running Safari in 32-bit mode, but the Java architecture is still x86_64 (and I can verify that it's actually the 64-bit mode as the applet errors with a very specific error message).

Repairing permissions and reinstalling Java (as well as rebooting, etc) hasn't solved anything.

At this point, I'd normally write this up as "time to do a fresh re-install," but since I'm still trying to learn the various inner workings of Macs, I'd like to try to resolve this one.

share|improve this question

migrated from stackoverflow.com Aug 12 '11 at 18:53

This question came from our site for professional and enthusiast programmers.

How does an applet require 32-bit Java? –  Yann Ramin Aug 12 '11 at 17:25
I have no idea why it's written to require 32-bit, but in this case as soon as it starts it shows a message that says something like "It appears you're running 64-bit java, this applet requires 32-bit java." Most likely they didn't want to test it under 64-bit, so they just "disabled" it. –  Mark Moseley Aug 12 '11 at 17:39
are there any native components in this applet, like jni? –  Denis Tulskiy Aug 12 '11 at 18:34
Before reinstalling, try checking, on machine B, if the same behavior occurs on a fresh user account. It might be due to some configuration files in ~/Library (though I'm not sure which) –  michel-slm Aug 12 '11 at 19:01
Coincidentally enough, I compile all my java apps in x86. . . (hides) –  surfasb Aug 12 '11 at 22:43

1 Answer 1

i was having the same problem. only thing is that i'm using snow leopard still. i'm still in the dark about what lion looks like and if it still uses spotlight. if so...go to spotlight (or whatever search index program lion has) and search "java". "Java Preferences" should appear. Click. Navigate to "General" tab if not already there. What you need to do is change the order. You should have Java 32 and Java 64 listed. (will probably be listed with Java 64 first then 32) You want to click and drag to change the process cycle order so that Java 32 is listed first before Java 64. After that, close preferences and close browser and reopen.

*Quick note. Your browser should be set to be running in 32-bit mode as well. To do this hold control and click or right click or 2 finger click whatever brings up a way to get "get info" in Lion. Once there click the 32-bit check box. Close "Get Info" and close/reopen browser

share|improve this answer

Your Answer


