<?php
system('java -version');
?>
system('java -version');
?>
with the error
Error occurred during initialization of VM
Could not reserve enough space for code cache.
Could not reserve enough space for code cache.
We already had the setsebool -P httpd_ssi_exec=1 option on, so that Apache had permission to execute whatever. Strangely, however, this "memory" issue is also due, somehow to selinux.
Edit: As a commenter below just indicated, you can use setsebool -P httpd_execmem=1 to disable this setting. If that doesn't work, well, back to the sledgehammer.
Ah, eureka indeed! That was it for us, too!
ReplyDeleteHooray! Glad it was helpful.
ReplyDeleteFor those searching in the future, I solved this issue on CentOS 6.2 by issuing the command:
ReplyDeletesetsebool httpd_execmem=1
Thank you.
DeleteAh, yes, thanks for the setsebool command (as I re-encounter this issue on a second machine)! This allows me to keep SELimux active, instead of just nuking the whole thing. And I see from the man page that the -P option makes the setting persist across reboots, which was my next concern. And now we can run the Java authentication module to log into our new wiki!
Deletepaxctl -c -m /usr/bin/keytool
ReplyDeletepaxctl -c -m /usr/bin/java
did the trick for me