Skip to content

2026.7.0-java21-alpine uses the wrong class version with its JVM #4157

Description

@rob-h-w

Describe the problem

The shipped JVM doesn't match the compiled java class version.

I downgraded to 2026.6.1-java25-alpine in the meantime.

Container definition

services:
...
  minecraft:
    container_name: minecraft
    environment:
      - EULA=TRUE
      - MEMORY=4G
      - DEV=${DEV}
      - TZ=${TZ}
    image: ${Minecraft}
    networks:
      - external-network
    ports:
      - 25565:25565
    restart: unless-stopped
    volumes:
      - /a/path/logs/minecraft:/data/logs
      - /a/path/minecraft:/data
...
networks:
  default:
    internal: true
  external-network:
    driver: bridge

Container logs

minecraft  | [init] Running as uid=1000 gid=1000 with /data as 'drwxr-xr-x 1 1000 1000 662 Jun 20 07:35 /data'
minecraft  | [init] Image info: buildtime=2026-07-04T14:30:00.426Z,version=2026.7.0-java21-alpine,revision=78ecbb5749639137054b847def6816c13c6e61f7
minecraft  | [init] Resolving type given VANILLA
minecraft  | [init] Resolved version given LATEST into 26.2
minecraft  | [init] Copying any configs from /config to /data/config
minecraft  | [mc-image-helper] 09:30:52.809 INFO  : Created/updated 1 property in /data/server.properties
minecraft  | [init] Setting initial memory to 4G and max to 4G
minecraft  | [init] Starting the Minecraft server...
minecraft  | Error: LinkageError occurred while loading main class net.minecraft.bundler.Main
minecraft  | 	java.lang.UnsupportedClassVersionError: net/minecraft/bundler/Main has been compiled by a more recent version of the Java Runtime (class file version 69.0), this version of the Java Runtime only recognizes class file versions up to 65.0
minecraft  | 2026-07-12T09:30:52.931+0200	WARN	mc-server-runner	Minecraft server failed. Inspect logs above for errors that indicate cause. DO NOT report this line as an error.	{"exitCode": 1}
minecraft  | 2026-07-12T09:30:52.931+0200	INFO	mc-server-runner	Done

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions