Page 1 of 1

java 1.6, epoll stack trace, grsec 2.6.23-14

PostPosted: Tue Jun 03, 2008 11:57 am
by futung.cheng
Hi,

I am using grsec with java 1.6 and I get an epoll stack trace. Is this a known issue with running a grsec kernel?

Thank You,
Fu-Tung

# uname -r
2.6.23.14-grsec

$ java -version
java version "1.6.0_06"
Java(TM) SE Runtime Environment (build 1.6.0_06-b02)
Java HotSpot(TM) Client VM (build 10.0-b22, mixed mode, sharing)

java.lang.InternalError: unable to get address of epoll functions, pre-2.6 kernel?
> at sun.nio.ch.EPollArrayWrapper.init(Native Method)
> at un.nio.ch.EPollArrayWrapper.<clinit>(EPollArrayWrapper.java:258)
> at sun.nio.ch.EPollSelectorImpl.<init>(EPollSelectorImpl.java:52)
> at sun.nio.ch.EPollSelectorProvider.openSelector(EPollSelectorProvider.java:18)
> at java.nio.channels.Selector.open(Selector.java:209)

Re: java 1.6, epoll stack trace, grsec 2.6.23-14

PostPosted: Tue Jun 03, 2008 12:42 pm
by cormander
Look at the .config file you used when you compiled your kernel, do you have:

CONFIG_EPOLL=y

If not, that's your problem.

If you did have this option - might want to run an strace on that command to see how it's trying to retrieve this information. In this case, it's more then likely trying to use /proc/kallsyms or /boot/System.map, which the CONFIG_GRKERNSEC_HIDESYM is designed to hide (if it's turned on, that is).

Re: java 1.6, epoll stack trace, grsec 2.6.23-14

PostPosted: Tue Jun 03, 2008 1:11 pm
by PaX Team
futung.cheng wrote:I am using grsec with java 1.6 and I get an epoll stack trace. Is this a known issue with running a grsec kernel?
does your libc have epoll_create, epoll_ctl and epoll_wait? that's what jdk/src/solaris/native/sun/nio/ch/EPollArrayWrapper.c:Java_sun_nio_ch_EPollArrayWrapper_init() looks up via dlsym and you get error if any of that fails. other than that, dlsym shouldn't be affected by any grsec feature i think.

Re: java 1.6, epoll stack trace, grsec 2.6.23-14

PostPosted: Fri Jun 27, 2008 1:39 pm
by futung.cheng
Glibc was the culprit !! Thank you !!!

Fu-Tung