Hi, when I attempt to link to a BitBucket Server repository with Bamboo 6.9.0 I get a fatal error 'Unable to read cipher data for 0'.
This is a brand-new install of Bamboo. It has been linked with our existing instance of BitBucket Server and the link has been configured on both instances. Each link shows a green 'connected' status.
Attempting to link a repository in the Admin console under Linked Repositories results in the same error:
Bamboo version: 6.9.0 build 60909 running on CentOS 7.6.1810
BitBucket Server: v5.6.2 running on CentOS 7.4.1708
Log file extract:
2019-06-04 15:05:07,967 WARN [http-nio-8085-exec-22] [CacheAwareness] Inheriting disabledCaches:[com.atlassian.bamboo.ANY]
2019-06-04 15:05:08,544 FATAL [http-nio-8085-exec-22] [InstanceSecretStorage] Cipher initialisation vector is unavailable
2019-06-04 15:05:08,547 ERROR [http-nio-8085-exec-22] [BambooActionSupport] java.lang.IllegalArgumentException: Unable to read cipher data for 0
java.lang.IllegalArgumentException: Unable to read cipher data for 0
1. I am able to create a plan without linking to a repository.
2. I get the same error if I make myself administrator on both Bamboo and BitBucket.
3. Removing and recreating the link between Bamboo and BitBucket does not solve the issue.
4. Bamboo is running has the 'bamboo' user. This user has drwx access on the 'cipher' directory and rw access on the file cipher.key_0 inside that directory.
5. I've looked at the questions linked but they don't fix my issue:
6. I have *not* tried a reinstallation with a new home directory and database. If I'm unable to resolve here that's my next step.
Hey, I lodged a support request with Atlassian about my issue and they helped me through resolving it.
The issue was an incomplete key generation, and the solution was to remove the partially-generated key from both the database and the filesystem to force regeneration.
These are the steps to resolve I was provided (paraphrased):
The database should have two rows, the com.atlassian.restricted.instance.cipher.key_0 and com.atlassian.restricted.instance.cipher.iv_0. They can be selected with:
select * from BANDANA where BANDANA_KEY like '%cipher%';
To regenerate the cipher:
Hope this helps!
Do not use the suggestion to delete and regenerate the cipher key. It is suggested depending on certain situation. Using this suggestion might cause an even severe problem without solution at the end.
Report the issue to Atlassian Support so that the logs can be analysed and a different solution might be suggested.
We’re preparing for Bamboo 8.0, which will be our first Data Center release. To make sure our app vendors and customers with written in-house apps are prepared, we’re launching Bamboo 8.0 Early Acces...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events