Not a particularly interesting post, unless you happen to be running Debian 4.0 etch running on Virtuozzo host and are trying to install JDK5. I saw a post with a user reporting the same error on the parallels forum , but couldn’t find a clear solution, until I bumped onto a weird forum in German, which luckily linked to a related bug report (in English).
So if you get this error message when installing jdk5:
Setting up sun-java5-bin (1.5.0-14-1etch1) ...
Could not create the Java virtual machine.
dpkg: error processing sun-java5-bin (--configure):
subprocess post-installation script returned error exit status 1
Errors were encountered while processing:
sun-java5-bin
E: Sub-process /usr/bin/dpkg returned an error code (1)
The solution is to edit the postinst script
# vi /var/lib/dpkg/info/sun-java5-bin.postinst
comment out one line below:
# activate class data sharing
case i386 in i386|sparc)
rm -f $basedir/jre/lib/i386/client/classes.jsa
### $basedir/bin/java -client -Xshare:dump > /dev/null
esac
Then reinstall. Ugly, but it seems to do the trick
2 replies on “JDK 5 Debian etch Virtuozzo installation oddities”
Hi, Thanks for you great tip, it’s 2 hours now that I try to install Java on My Etch in Virtuozzo (4.0) and after doing waht you write I can install it :-)
Thanks
[…] (required) Website. Powered by WordPress and MySQL. Theme by Shlomi Noach, openark.org …Gingerlime JDK 5 Debian etch Virtuozzo installation odditiesFiled under: Technology Yoav Aner @ 3:42 pm. Not a particularly interesting post, unless … edit […]