Upgrade Task 51602 fails: pad block corrupted
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
When upgrading Bamboo to 6.0.x from 5.15 or lower, the upgrade fails with the following appearing in the atlassian-bamboo
.log
:
2017-06-12 09:35:13,278 INFO [16-UpgradeTaskBackgroundThread:pool-32-thread-1] [AbstractUpgradeManager] ----------------------------------------------------------------------------------------
2017-06-12 09:35:13,278 INFO [16-UpgradeTaskBackgroundThread:pool-32-thread-1] [AbstractUpgradeManager] 51602 : Re-encrypting SMTP mail server password using new encryption service (bootstrap)
2017-06-12 09:35:13,278 INFO [16-UpgradeTaskBackgroundThread:pool-32-thread-1] [AbstractUpgradeManager] ----------------------------------------------------------------------------------------
2017-06-12 09:35:13,294 ERROR [16-UpgradeTaskBackgroundThread:pool-32-thread-1] [AbstractUpgradeManager] java.lang.RuntimeException: org.bouncycastle.crypto.InvalidCipherTextException: pad block corrupted
java.lang.RuntimeException: org.bouncycastle.crypto.InvalidCipherTextException: pad block corrupted
...
Caused by: org.bouncycastle.crypto.InvalidCipherTextException: pad block corrupted
...
2017-06-12 09:35:13,294 INFO [16-UpgradeTaskBackgroundThread:pool-32-thread-1] [AbstractUpgradeManager] Completed task 51602 successfully.
Cause
This issue occurs when Bamboo is unable to decrypt the mail server password. This can occur due to a previously failed upgrade.
Resolution
If there is a mail server configured in Bamboo, please do the following:
- Stop Bamboo
Open
<bamboo-home>/bamboo-mail.cfg.xml
Update the password field so that it reads
<password></password>
Start Bamboo
- Finally, once you are able to start Bamboo, please update the Mail server configuration from
Administration >> Overview >> Mail server