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

Logs can grow without bound when using timestamper plugin

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved (View Workflow)
    • Minor
    • Resolution: Fixed
    • timestamper-plugin
    • None
    • Jenkins 2.19.1
      Timestamper 1.8.7 (but observed in older versions as well)

    Description

      When a single pipeline step generates a lot of logging all at once, the log on disk will repeat itself without end, eventually running the host out of disk space.

      This persists between Jenkins restarts and can only be stopped by stopping Jenkins, deleting the $JENKINS_HOME/jobs/[job]/build/[build id] directory, and starting Jenkins again.

      STR:
      1. Create a new pipeline job with the following pipeline script definition:
      stage ('Boom') {
      node {
      timestamps

      { sh "seq 1 100000" }

      }
      }

      2. Run the job.

      Expected result:
      Job terminates eventually.

      Actual result:
      Job does not terminate, and fills the log continuously.

      Attachments

        Activity

          eflores Edwin Flores created issue -
          eflores Edwin Flores made changes -
          Field Original Value New Value
          Description When a single pipeline step generates a lot of logging all at once, the log on disk will repeat itself without end, eventually running the host out of disk space.

          This persists between Jenkins restarts and can only be stopped by stopping Jenkins, deleting the $JENKINS_HOME/jobs/[job]/build/[build id] directory, and starting Jenkins again.

          STR:
          1. Create a new pipeline job with the following pipeline script definition:
          {{stage ('Boom') {
              node {
                  timestamps {
                      sh "seq 1 100000"
                  }
              }
          }}}
          2. Run the job.

          Expected result:
          Job terminates eventually.

          Actual result:
          Job does not terminate, and fills the log continuously.
          When a single pipeline step generates a lot of logging all at once, the log on disk will repeat itself without end, eventually running the host out of disk space.

          This persists between Jenkins restarts and can only be stopped by stopping Jenkins, deleting the $JENKINS_HOME/jobs/[job]/build/[build id] directory, and starting Jenkins again.

          STR:
          1. Create a new pipeline job with the following pipeline script definition:
          {{
          stage ('Boom') {
              node {
                  timestamps {
                      sh "seq 1 100000"
                  }
              }
          }
          }}
          2. Run the job.

          Expected result:
          Job terminates eventually.

          Actual result:
          Job does not terminate, and fills the log continuously.
          eflores Edwin Flores made changes -
          Description When a single pipeline step generates a lot of logging all at once, the log on disk will repeat itself without end, eventually running the host out of disk space.

          This persists between Jenkins restarts and can only be stopped by stopping Jenkins, deleting the $JENKINS_HOME/jobs/[job]/build/[build id] directory, and starting Jenkins again.

          STR:
          1. Create a new pipeline job with the following pipeline script definition:
          {{
          stage ('Boom') {
              node {
                  timestamps {
                      sh "seq 1 100000"
                  }
              }
          }
          }}
          2. Run the job.

          Expected result:
          Job terminates eventually.

          Actual result:
          Job does not terminate, and fills the log continuously.
          When a single pipeline step generates a lot of logging all at once, the log on disk will repeat itself without end, eventually running the host out of disk space.

          This persists between Jenkins restarts and can only be stopped by stopping Jenkins, deleting the $JENKINS_HOME/jobs/[job]/build/[build id] directory, and starting Jenkins again.

          STR:
          1. Create a new pipeline job with the following pipeline script definition:
          stage ('Boom') {
              node {
                  timestamps {
                      sh "seq 1 100000"
                  }
              }
          }

          2. Run the job.

          Expected result:
          Job terminates eventually.

          Actual result:
          Job does not terminate, and fills the log continuously.
          stevengbrown Steven G Brown made changes -
          Resolution Fixed [ 1 ]
          Status Open [ 1 ] Resolved [ 5 ]

          People

            stevengbrown Steven G Brown
            eflores Edwin Flores
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: