Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-71963

Failed to start thread "GC Thread#0" - pthread_create failed (EPERM)

    • Icon: Bug Bug
    • Resolution: Not A Defect
    • Icon: Major Major
    • core, docker

      Docker Jenkins image fails to start, and crashes with the below output to the console.

      This started happening with 2.420, also happening on 2.421, versions up to 2.419 work just fine.

      jenkins-docker | [0.003s][warning][os,thread] Failed to start thread "GC Thread#0" - pthread_create failed (EPERM) for attributes: stacksize: 1024k, guardsize: 4k, detached.
      jenkins-docker | #
      jenkins-docker | # There is insufficient memory for the Java Runtime Environment to continue.
      jenkins-docker | # Cannot create worker GC thread. Out of system resources.
      jenkins-docker | # An error report file with more information is saved as:
      jenkins-docker | # /tmp/hs_err_pid6.log
      jenkins-docker exited with code 1

          [JENKINS-71963] Failed to start thread "GC Thread#0" - pthread_create failed (EPERM)

          Sebastian added a comment -

          poddingue Have the same issue using the 2.422 tag, tried allocating more memory to the server & increasing memory allocated via jvm args but neither helped, temporarily reverted to 2.419

          Sebastian added a comment - poddingue  Have the same issue using the 2.422 tag, tried allocating more memory to the server & increasing memory allocated via jvm args but neither helped, temporarily reverted to 2.419 . 

          Bruno Verachten added a comment - - edited

          By using this tag, you're using Debian Bookworm with openjdk version 11.0.20.
          Could you please make a test with another tag, for example 2.422-jdk17 that would give you the same Debian Bookworm but with openjdk version {{17.0.8 }}this time?
          I can't reproduce, unfortunately, as I don't have a Red Hat Enterprise Linux release 8.2 machine, and the 2.422 image works well for me.
          I can't see anything in the [changelog|http://example.com] either.

          Bruno Verachten added a comment - - edited By using this tag, you're using Debian Bookworm with openjdk version 11.0.20 . Could you please make a test with another tag, for example 2.422-jdk17 that would give you the same Debian Bookworm but with openjdk version {{17.0.8 }}this time? I can't reproduce, unfortunately, as I don't have a Red Hat Enterprise Linux release 8.2 machine, and the 2.422 image works well for me. I can't see anything in the [changelog| http://example.com ] either.

          asgeirn added a comment - - edited

          Main controller image, yes. We used the latest tag, but have now it fixed to 2.419.

          This is the definition in the Docker Compose file:

          version: '3'
          services:
                  jenkins:
                          container_name: jenkins-docker
                          image: jenkins/jenkins:2.419
                          ports:
                                  - "8080:8080"
                                  - "50000:50000"
                          volumes:
                                  - /jenkins/jenkins_home:/var/jenkins_home
                                  - /var/run/docker.sock:/var/run/docker.sock
          

          asgeirn added a comment - - edited Main controller image, yes. We used the latest tag, but have now it fixed to 2.419 . This is the definition in the Docker Compose file: version: '3' services: jenkins: container_name: jenkins-docker image: jenkins/jenkins:2.419 ports: - "8080:8080" - "50000:50000" volumes: - /jenkins/jenkins_home:/ var /jenkins_home - / var /run/docker.sock:/ var /run/docker.sock

          asgeirn added a comment -

          Just tested with 2.422-jdk17, this has same issue. 2.419-jdk17 works just fine.

          asgeirn added a comment - Just tested with 2.422-jdk17 , this has same issue. 2.419-jdk17 works just fine.

          Bruno Verachten added a comment - - edited

          Thank you.

          My usage is different somehow, as I'm building my own images based on the Jenkins controller image.

          Bruno Verachten added a comment - - edited Thank you. My usage is different somehow, as I'm building my own images based on the Jenkins controller image.

          Do you have the possibility to update your RedHat version to something more recent, like 8.8 for instance?
          Same for Docker, as your version is really outdated (I'm running Docker version 24.0.5 community edition on my machine).

          Bruno Verachten added a comment - Do you have the possibility to update your RedHat version to something more recent, like 8.8 for instance? Same for Docker, as your version is really outdated (I'm running Docker version 24.0.5 community edition on my machine).

          Sebastian added a comment -

          Updated our version of docker from 20.x.x to 24.0.6, and 2.422 is now up and running Thanks for the assistance poddingue !

          Sebastian added a comment - Updated our version of docker from 20.x.x to 24.0.6, and 2.422 is now up and running Thanks for the assistance poddingue !

          That's fantastic news, thanks for the feedback! 

          Bruno Verachten added a comment - That's fantastic news, thanks for the feedback! 

          asgeirn added a comment -

          Upgrading to docker-ce-24.0.6-1.el8.x86_64 fixed the issue for us as well, thanks for the suggestion!

          asgeirn added a comment - Upgrading to docker-ce-24.0.6-1.el8.x86_64 fixed the issue for us as well, thanks for the suggestion!

          Thanks for the feedback too!
          Happy "Jenkinsing". 

          Bruno Verachten added a comment - Thanks for the feedback too! Happy "Jenkinsing". 

            csanchez Carlos Sanchez
            asgeirn asgeirn
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: