Subject: Re: [alpine-devel] Java Runtime Environment on Alpine Linux

From: Natanael Copa <[email-masked]>
Date: Tue, 28 May 2013 14:31:12 +0200

On Tue, 28 May 2013 15:37:14 +0430
Richard Johnson <[email-masked]> wrote:

> Just recently I installed the package "openjdk6-jre-base" on Alpine Linux, and I tried to run a precompiled class file, which resulted in the following error:
>    Error occurred during initialization of VM
>    Could not reserve enough space for object heap
> 
> More Details:
> - I have installed this instance of alpine from alpine-xen-2.6.0_rc3-x86_64.iso, However I did "apk upgrade" just after installing the JRE.
> - I am running Java in dom0
> - I have allocated more than 800MB for dom0
> - Even when running trivial commands such as "java -version" I get the same error message
> - My goal is to run a Swing application in the X environment
> 
> Is there any solution/workaround?

hm, it works for me.

ncopa-desktop:~$ java -version
java version "1.6.0_24"
OpenJDK Runtime Environment (IcedTea6 1.11.11) (Alpine 1.6.0_p24-r7)
OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode)

I know that java (the JIT specificically) and PaX does not go well
together. We do disable pax protection on java binaries but it might be
that something slipped through.

try see what paxctl tells you about the binaries:

paxctl -v /usr/lib/jvm/java-1.6-openjdk/bin/*
paxctl -v /usr/lib/jvm/java-1.6-openjdk/jre/bin/*

You should see things like:
- PaX flags: -----m-x-e-r [/usr/lib/jvm/java-1.6-openjdk/bin/java]
	MPROTECT is disabled
	RANDEXEC is disabled
	EMUTRAMP is disabled
	RANDMMAP is disabled

-nc

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---