Issue
- How do I get a build directory of a build number of a specific Job ?
- Diagnosing build issues
Resolution
A build directory contains most of the information needed to diagnose build issues. There are different ways to collect it.
From the UI
If using Support Core 2.67 or later, you can download directly from the UI. Navigate to the build page and click on the Support link. Then click on Generate Bundle:
Note: you may adjust the options to collect specific data. For more details about the different options, have a look at the help ?
tooltips.
With cbsupport
With the cbsupport CLI, you can download a build directory by using the command cbsupport required-data build
. See 2.5.2. Generating information for a Jenkins Build issue for more details.
From the File System
In any case, you can find the build directory of a specific build number in the file system under the Build Record Root Directory.
- By default, it is
$JENKINS_HOME/jobs/$PATH_TO_JOB/builds/$BUILD_NUMBER
If the Build Record Root Directory is customized, its location can be found:
- Before Jenkins 2.119, it is managed via GUI: Manage Jenkins > Configure System > Advanced
- Since Jenkins 2.119, it is managed by
jenkins.model.Jenkins.buildsDir
via Features controlled by system properties.
Note: you may exclude the underlying stashes/
and artifacts/
directories or cherry pick what you are looking for to avoid collecting too much data
0 Comments