Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

There is a balance to strike with archiving reports and logs in that, of course, . On one hand, the more historical data we have the better it will be for troubleshooting the problem.  On the other hand, since these archives take up disk space, the customer may want to economize the use of that space by only keeping a certain number of logs, or past logs for only a certain amount of time before they are overwritten. 

This document aims to help the customer strike a balance between keeping as much historical information as possible while still conserving disk space by deleting old files that are of little value. configure their Jenkins jobs to archive the proper number and age of reports and balance these considerations to match their specific business needs.

Step-by-step guide

For jobs that are set up in Jenkins

  1. Configure the job to handle archives correctly
    1. Open the configuration of your Jenkins job by clicking on the job and then clicking the "Configure" button 
    2. In the General section select the checkbox next to "Discard old builds"
    3. This will expand a section where you can provide additional configuration
    4. "Strategy" should be set to "Log Rotation"
    5. Enter the number of days to keep old builds - Builds older than this number of days will be overwritten
    6. Enter the maximum number of builds you wish to keep - If there are already this many builds stored, the oldest will be overwritten by the current build
    7. "Days to keep artifacts" and "Max # of builds to keep with artifacts" do the same as e and f above, but for artifacts specifically

  2. Archive the artifacts after the build:
    1. In the "Post-build Actions" section, select "Add post-build action" > "Archive the artifacts"
    2. In "Files to archive" enter the string **/daticaldb.log, **/Reports/**, **/Logs/**, **/Snapshots/**
      1. This tells Jenkins to keep all of the files called daticaldb.log as well as the contents of the /Reports, /Logs and /Snapshots directories
    3. Click "Advanced" for optional configurations
    4. Click the Save button

Filter by label (Content by label)showLabelsfalsemax5spacescom.atlassian.confluence.content.render.xhtml.model.resource.identifiers.SpaceResourceIdentifier@a59a8d3fshowSpacefalsesortmodifiedreversetruetypepagecqllabel = "kb-how-to-article" and type = "page" and space = "~127760635"labelskb-how-to-article


Page Properties
hiddentrue


Related issues