Open m2kar opened 1 year ago
@m2kar This is strange.
Could you share the output of?
docker run --rm -it -v /tmp:/tmp -v $(pwd):/app:rw -w /app -t ghcr.io/joernio/joern:nightly java -version
docker run --rm -it -v /tmp:/tmp -v $(pwd):/app:rw -w /app -t ghcr.io/joernio/joern:nightly echo $JAVA_HOME
As a workaround, start the bash shell and then type joern
docker run --rm -it -v /tmp:/tmp -v $(pwd):/app:rw -w /app -t ghcr.io/joernio/joern:nightly /bin/bash
joern
Here are the output of the shell commands:
$ sudo docker run --rm -it -v /tmp:/tmp -v $(pwd):/app:rw -w /app -t ghcr.io/joernio/joern:nightly java -version
Unable to find image 'ghcr.io/joernio/joern:nightly' locally
nightly: Pulling from joernio/joern
c5196fa8a240: Pull complete
537fdc407eb3: Pull complete
7f668f01f2e2: Pull complete
Digest: sha256:e1dd6e483ef847150234f7220f5f6a1334df0e7430ff094fbdc43798ec88897b
Status: Downloaded newer image for ghcr.io/joernio/joern:nightly
[0.014s][warning][os,thread] Failed to start thread "GC Thread#0" - pthread_create failed (EPERM) for attributes: stacksize: 1024k, guardsize: 4k, detached.
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Cannot create worker GC thread. Out of system resources.
# An error report file with more information is saved as:
# /app/hs_err_pid1.log
failed to resize tty, using default size
2.
$ sudo docker run --rm -it -v /tmp:/tmp -v $(pwd):/app:rw -w /app -t ghcr.io/joernio/joern:nightly echo $JAVA_HOME
@m2kar Could you try it on a recent version of Linux with sufficient memory?
The memory is sufficient.
$ free -m
total used free shared buff/cache available
Mem: 17275 3066 9277 56 4930 13855
Swap: 2047 0 2047
The linux version:
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.1 LTS
Release: 18.04
Codename: bionic
@m2kar Kernel 4 is quite old. Do you have ubuntu 22.04?
I try on another operation system, and this docker works.
$ lsb_release -a
LSB Version: n/a
Distributor ID: ManjaroLinux
Description: Manjaro Linux
Release: 23.0.0
Codename: Uranos
$ uname -a
Linux SEC-T440s 6.1.44-1-MANJARO #1 SMP PREEMPT_DYNAMIC Wed Aug 9 09:02:26 UTC 2023 x86_64 GNU/Linux
$ sudo docker run --rm -it -v /tmp:/tmp -v $(pwd):/app:rw -w /app -t ghcr.io/joernio/joern:nightly java -version
openjdk version "17.0.8" 2023-07-18 LTS
OpenJDK Runtime Environment (Red_Hat-17.0.8.0.7-1) (build 17.0.8+7-LTS)
OpenJDK 64-Bit Server VM (Red_Hat-17.0.8.0.7-1) (build 17.0.8+7-LTS, mixed mode, sharing)
There may be some incompatibility within the older version of Docker or the older version of the Linux kernel.
Describe the bug When run joern docker image from ghcr.io, show
No java installations was detected
.To Reproduce Steps to reproduce the behavior:
Expected behavior run joern
Screenshots If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Ubuntu 18.04.5 LTS/ Linux version 4.15.0-197-generic (buildd@lcy02-amd64-110) (gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04)) #208-Ubuntu SMP Tue Nov 1 17:23:37 UTC 2022