this-user opened a new issue, #6457: URL: https://github.com/apache/gravitino/issues/6457
### Version main branch ### Describe what's wrong Trying to start the Iceberg REST server image published on Docker Hub results in an error, and the server fails to start. This happens with both the `0.7.0-incubating` as well as the `0.8.0-incubating` version on `x86_64` Arch Linux system with Kernel `6.13.2`. ``` ++ dirname /root/gravitino-iceberg-rest-server/bin/start-iceberg-rest-server.sh + bin_dir=/root/gravitino-iceberg-rest-server/bin ++ cd /root/gravitino-iceberg-rest-server/bin/../ ++ pwd + iceberg_rest_server_dir=/root/gravitino-iceberg-rest-server + cd /root/gravitino-iceberg-rest-server + python bin/rewrite_config.py + ./bin/gravitino-iceberg-rest-server.sh start Log dir doesn't exist, create /root/gravitino-iceberg-rest-server/logs GravitinoIcebergRESTServer is not running ``` The failure seems to be related to some changes in the `cgroups` mechanism that was made some time ago that causes issues with older Java versions (see log output below), and the published images use `openjdk:17-jdk-buster` as base image that contains a JDK 17 from 2022. ``` # java --version openjdk 17.0.2 2022-01-18 OpenJDK Runtime Environment (build 17.0.2+8-86) OpenJDK 64-Bit Server VM (build 17.0.2+8-86, mixed mode, sharing) ``` The solution is swapping out the base image for one with a newer JRE/JDK. The latest Java 17 version is currently `17.0.14`. However, one additional issue is that the new OpenJDK images don't come with Python pre-installed, which is needed to start Gravitino. So, installing would have to be done in the `Dockerfile`. Additionally, the OpenJDK images are deprecated, although new builds are currently still being created. However, switching to another currently still supported base image might make sense. I have tried a build with `eclipse-temurin:17-ubi9-minimal`, which works if the needed packages are added during the build: `RUN microdnf install -y python procps` This version comes with Python 3.9. Another option would be using `amazoncorretto:17-alpine3.19`, which offers Python 3.11, while newer Alpine images have already switched to 3.12, which is not currently supported by Gravitino. `RUN apk add python3` ### Error message and/or stacktrace ``` # cat /root/gravitino-iceberg-rest-server/logs/gravitino-iceberg-rest-server.out log4j:WARN No appenders could be found for logger (org.apache.gravitino.iceberg.server.GravitinoIcebergRESTServer). log4j:WARN Please initialize the log4j system properly. log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info. Exception in thread "main" java.lang.NullPointerException: Cannot invoke "jdk.internal.platform.CgroupInfo.getMountPoint()" because "anyController" is null at java.base/jdk.internal.platform.cgroupv2.CgroupV2Subsystem.getInstance(CgroupV2Subsystem.java:81) at java.base/jdk.internal.platform.CgroupSubsystemFactory.create(CgroupSubsystemFactory.java:113) at java.base/jdk.internal.platform.CgroupMetrics.getInstance(CgroupMetrics.java:167) at java.base/jdk.internal.platform.SystemMetrics.instance(SystemMetrics.java:29) at java.base/jdk.internal.platform.Metrics.systemMetrics(Metrics.java:58) at java.base/jdk.internal.platform.Container.metrics(Container.java:43) at jdk.management/com.sun.management.internal.OperatingSystemImpl.<init>(OperatingSystemImpl.java:182) at jdk.management/com.sun.management.internal.PlatformMBeanProviderImpl.getOperatingSystemMXBean(PlatformMBeanProviderImpl.java:280) at jdk.management/com.sun.management.internal.PlatformMBeanProviderImpl$3.nameToMBeanMap(PlatformMBeanProviderImpl.java:199) at java.management/java.lang.management.ManagementFactory.lambda$getPlatformMBeanServer$0(ManagementFactory.java:488) at java.base/java.util.stream.ReferencePipeline$7$1.accept(ReferencePipeline.java:273) at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:179) at java.base/java.util.HashMap$ValueSpliterator.forEachRemaining(HashMap.java:1779) at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509) at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499) at java.base/java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:150) at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:173) at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) at java.base/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:596) at java.management/java.lang.management.ManagementFactory.getPlatformMBeanServer(ManagementFactory.java:489) at org.apache.gravitino.metrics.source.JVMMetricsSource.<init>(JVMMetricsSource.java:34) at org.apache.gravitino.GravitinoEnv.initBaseComponents(GravitinoEnv.java:398) at org.apache.gravitino.GravitinoEnv.initializeBaseComponents(GravitinoEnv.java:157) at org.apache.gravitino.iceberg.server.GravitinoIcebergRESTServer.initialize(GravitinoIcebergRESTServer.java:48) at org.apache.gravitino.iceberg.server.GravitinoIcebergRESTServer.main(GravitinoIcebergRESTServer.java:73) ``` ### How to reproduce `$ docker run -it --run apache/gravitino-iceberg-rest:0.8.0-incubating sh` ### Additional context _No response_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
