Backup Jobs fail after upgrade to release 2.319.3.4 or higher

2 minute readKnowledge base

Issue

I have some Backup Jobs and they are failing since I upgraded to release 2.319.3.4 (or higher) with the following stack trace:

This job was last saved by a user without the right level of permission. Please, configure the backup job with an user with the right permission. anonymous is missing the Overall/RunScripts permission ERROR: Build step failed with exception hudson.security.AccessDeniedException3: anonymous is missing the Overall/RunScripts permission at hudson.security.ACL.checkPermission(ACL.java:79) at hudson.security.AccessControlled.checkPermission(AccessControlled.java:51) [...]

Context

There is a known issue related to Backup Jobs caused by how the hashes of the Items are managed. After upgrading CloudBees CI to release 2.319.3.4 or higher, the required hashes (generated from the Backup jobs) are missing and CloudBees CI is not able to confirm the permissions of the Backup jobs. Since those hashes are generated automatically when the backup job is created or updated, we would only need to Save the configuration of the job (we would not need to apply any kind of changes to the Job configuration, we would only need to save the same configuration that we had for the job previously) to address the known issue.

Resolution

As mentioned above, the solution for this issue is to save once the Backup Jobs. This can be done manually one Item at a time from the UI, navigating under the Configure section of the Job and hitting the button Save; or you can navigate under Manage Jenkins → Script Console and execute the following script to save all the Backup Jobs at once:

Jenkins.instance.getAllItems().findAll{it instanceof com.infradna.hudson.plugins.backup.BackupProject}.each{ it.save() }