How to get a Job / Folder directory ?

Article ID:360041569311
1 minute readKnowledge base


  • How do I get a Jenkins Item (Pipeline Job, Folder, Multibranch Job, Freestyle Job, etc…​) directory ?

  • Diagnosing Jenkins Item issues


The directory of an Item contains most of the information needed to diagnose Item 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 Item page and click on the Support link. Then click on Generate Bundle:

support item bundle
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 an item directory by using the command cbsupport required-data item. See 2.5.2. Generating information for a Jenkins Job / Folder issue for more details.

From the File System

In any case, you can find the item directory of a specific item in the file system under the Item Root Directory at $JENKINS_HOME/jobs/$PATH_TO_JOB/.

you may exclude the underlying stashes/, jobs/ and builds/ directories or cherry pick what you are looking for to avoid collecting too much data

On a Linux machine, you can use the tar command to do this. An example command might look like this:

tar -cvzf $JOB_FOLDER.tar.gz $JENKINS_HOME/jobs/$PATH_TO_JOB/

This command will create an archive file called "$JOB_FOLDER.tar.gz" which you can then provide to CloudBees support.