Elastic Bamboo 5.0 Default Linux Instance update has newer versions of packages than are available through the yum repositories
Asked by Jeremy Switzer:

It appears our OnDemand instance of Bamboo was updated to 5.0 over the weekend, and along with it updates to the Default Elastic Bamboo Images. However, the changes made to the default images seems to have broken my *customise-extras.sh* script that runs when I attach my EBS volume during the startup.

The specific AMI in question is **Default Image EBS i386 (linux)**.

In my script, the first thing I do is update and install a bunch of packages through *yum* , which is where the problem seems to be. So, when I ssh on to the instance and attempt to install a package, e.g. *openssl-devel*, manually, I get the following errors:

```
# yum install openssl-develLoaded plugins: priorities, security, update-motd, upgrade-helperamzn-main                                                                                                         | 2.1 kB     00:00     amzn-updates                                                                                                      | 2.3 kB     00:00     Setting up Install ProcessResolving Dependencies--&gt; Running transaction check---&gt; Package openssl-devel.i686 0:1.0.0k-1.48.amzn1 will be installed--&gt; Processing Dependency: openssl = 1.0.0k-1.48.amzn1 for package: openssl-devel-1.0.0k-1.48.amzn1.i686--&gt; Processing Dependency: zlib-devel for package: openssl-devel-1.0.0k-1.48.amzn1.i686--&gt; Processing Dependency: krb5-devel for package: openssl-devel-1.0.0k-1.48.amzn1.i686--&gt; Running transaction check---&gt; Package krb5-devel.i686 0:1.9-33.22.amzn1 will be installed--&gt; Processing Dependency: krb5-libs = 1.9-33.22.amzn1 for package: krb5-devel-1.9-33.22.amzn1.i686--&gt; Processing Dependency: libcom_err-devel for package: krb5-devel-1.9-33.22.amzn1.i686--&gt; Processing Dependency: keyutils-libs-devel for package: krb5-devel-1.9-33.22.amzn1.i686--&gt; Processing Dependency: libkdb5.so.5 for package: krb5-devel-1.9-33.22.amzn1.i686--&gt; Processing Dependency: libselinux-devel for package: krb5-devel-1.9-33.22.amzn1.i686---&gt; Package openssl-devel.i686 0:1.0.0k-1.48.amzn1 will be installed--&gt; Processing Dependency: openssl = 1.0.0k-1.48.amzn1 for package: openssl-devel-1.0.0k-1.48.amzn1.i686---&gt; Package zlib-devel.i686 0:1.2.5-7.11.amzn1 will be installed--&gt; Running transaction check---&gt; Package keyutils-libs-devel.i686 0:1.4-4.10.amzn1 will be installed---&gt; Package krb5-devel.i686 0:1.9-33.22.amzn1 will be installed--&gt; Processing Dependency: krb5-libs = 1.9-33.22.amzn1 for package: krb5-devel-1.9-33.22.amzn1.i686--&gt; Processing Dependency: libkdb5.so.5 for package: krb5-devel-1.9-33.22.amzn1.i686---&gt; Package libcom_err-devel.i686 0:1.42.3-2.16.amzn1 will be installed--&gt; Processing Dependency: libcom_err = 1.42.3-2.16.amzn1 for package: libcom_err-devel-1.42.3-2.16.amzn1.i686---&gt; Package libselinux-devel.i686 0:2.1.6-6.12.amzn1 will be installed--&gt; Processing Dependency: libselinux = 2.1.6-6.12.amzn1 for package: libselinux-devel-2.1.6-6.12.amzn1.i686--&gt; Processing Dependency: libsepol-devel &gt;= 2.1.1-1 for package: libselinux-devel-2.1.6-6.12.amzn1.i686--&gt; Processing Dependency: pkgconfig(libsepol) for package: libselinux-devel-2.1.6-6.12.amzn1.i686---&gt; Package openssl-devel.i686 0:1.0.0k-1.48.amzn1 will be installed--&gt; Processing Dependency: openssl = 1.0.0k-1.48.amzn1 for package: openssl-devel-1.0.0k-1.48.amzn1.i686--&gt; Running transaction check---&gt; Package krb5-devel.i686 0:1.9-33.22.amzn1 will be installed--&gt; Processing Dependency: krb5-libs = 1.9-33.22.amzn1 for package: krb5-devel-1.9-33.22.amzn1.i686--&gt; Processing Dependency: libkdb5.so.5 for package: krb5-devel-1.9-33.22.amzn1.i686---&gt; Package libcom_err-devel.i686 0:1.42.3-2.16.amzn1 will be installed--&gt; Processing Dependency: libcom_err = 1.42.3-2.16.amzn1 for package: libcom_err-devel-1.42.3-2.16.amzn1.i686---&gt; Package libselinux-devel.i686 0:2.1.6-6.12.amzn1 will be installed--&gt; Processing Dependency: libselinux = 2.1.6-6.12.amzn1 for package: libselinux-devel-2.1.6-6.12.amzn1.i686---&gt; Package libsepol-devel.i686 0:2.1.3-2.11.amzn1 will be installed--&gt; Processing Dependency: libsepol = 2.1.3-2.11.amzn1 for package: libsepol-devel-2.1.3-2.11.amzn1.i686---&gt; Package openssl-devel.i686 0:1.0.0k-1.48.amzn1 will be installed--&gt; Processing Dependency: openssl = 1.0.0k-1.48.amzn1 for package: openssl-devel-1.0.0k-1.48.amzn1.i686--&gt; Finished Dependency ResolutionError: Package: libcom_err-devel-1.42.3-2.16.amzn1.i686 (amzn-updates)           Requires: libcom_err = 1.42.3-2.16.amzn1           Installed: libcom_err-1.42.3-3.17.amzn1.i686 (installed)               libcom_err = 1.42.3-3.17.amzn1           Available: libcom_err-1.42-2.15.amzn1.i686 (amzn-main)               libcom_err = 1.42-2.15.amzn1           Available: libcom_err-1.42.3-2.16.amzn1.i686 (amzn-updates)               libcom_err = 1.42.3-2.16.amzn1Error: Package: krb5-devel-1.9-33.22.amzn1.i686 (amzn-main)           Requires: krb5-libs = 1.9-33.22.amzn1           Installed: krb5-libs-1.10.3-10.25.amzn1.i686 (installed)               krb5-libs = 1.10.3-10.25.amzn1           Available: krb5-libs-1.9-33.22.amzn1.i686 (amzn-main)               krb5-libs = 1.9-33.22.amzn1Error: Package: libselinux-devel-2.1.6-6.12.amzn1.i686 (amzn-main)           Requires: libselinux = 2.1.6-6.12.amzn1           Installed: libselinux-2.1.10-3.17.amzn1.i686 (installed)               libselinux = 2.1.10-3.17.amzn1           Available: libselinux-2.1.6-6.12.amzn1.i686 (amzn-main)               libselinux = 2.1.6-6.12.amzn1Error: Package: krb5-devel-1.9-33.22.amzn1.i686 (amzn-main)           Requires: libkdb5.so.5           Available: krb5-libs-1.9-33.22.amzn1.i686 (amzn-main)               libkdb5.so.5           Installed: krb5-libs-1.10.3-10.25.amzn1.i686 (installed)               Not foundError: Package: openssl-devel-1.0.0k-1.48.amzn1.i686 (amzn-updates)           Requires: openssl = 1.0.0k-1.48.amzn1           Installed: 1:openssl-1.0.1e-4.53.amzn1.i686 (installed)               openssl = 1:1.0.1e-4.53.amzn1           Available: openssl-1.0.0j-1.43.amzn1.i686 (amzn-main)               openssl = 1.0.0j-1.43.amzn1           Available: openssl-1.0.0k-1.48.amzn1.i686 (amzn-updates)               openssl = 1.0.0k-1.48.amzn1Error: Package: libsepol-devel-2.1.3-2.11.amzn1.i686 (amzn-main)           Requires: libsepol = 2.1.3-2.11.amzn1           Installed: libsepol-2.1.7-3.12.amzn1.i686 (installed)               libsepol = 2.1.7-3.12.amzn1           Available: libsepol-2.1.3-2.11.amzn1.i686 (amzn-main)               libsepol = 2.1.3-2.11.amzn1 You could try using --skip-broken to work around the problem You could try running: rpm -Va --nofiles --nodigest
```

It looks as if there have been rpm packages installed manully or from another package repo. I have a similar problem when trying to install other \*-devel packages as well.

I was going to simply downgrade all the packages to mirror the amzn-updates repo, but I wasn't sure if these were specifically required for the Bamboo Agent to function.

Please help. My entire build system is non-functional because of this.


Answers:
author: Przemek Bruski
body: Syncing with amzn-updates shouldn't cause problems. As an alternative, you can also go back to using the images that worked for you.

comments: author: Jeremy Switzer
body: The images that were working are gone. They were replaced by these new ones that do not work.


author: Jeremy Switzer
body: There is an overwhelming number of packages to manage. For every downgraded dependency, there are five more to downgrade from there, and so on.

It looks to me like someone added a new package repo, updated the entire system, and then the removed the reference to the updated repo.

I tried running *yum distribution-syncrhonization*, but that failed as well.

I feel like I'm completely out of options here. Is there no other information you can give me about this??


author: Przemek Bruski
body: This is the list of images pre-upgrade:

image.US_EAST_1.EBS.i386.linux=ami-bf56ead6  
image.US_EAST_1.EBS.x86_64.windows=ami-976edafe  
image.US_EAST_1.EBS.x86_64.linux=ami-8156eae8  
image.US_EAST_1.S3.x86_64.linux=ami-8f56eae6  
image.US_EAST_1.S3.i386.linux=ami-9f56eaf6

Use one of them instead.

We'll look into the dependency issue you've reported.


author: Jeremy Switzer
body: Creating a new instance config pointing to the old AMI and Transferring all the capabilities over to it worked. Thanks!


author: JohnBarry
body: This is precisely the issue we're facing and I'm incredibly unhappy that this seems to have been an unpublished change.

36 hours in, zero complete builds.


author: Robert Watkins
body: FWIW, this was announced in the release notes for Bamboo 5 - [BAM-11359](https://jira.atlassian.com/browse/BAM-11359).

(Of course, the exact timing of the OnDemand update wasn't known, and there was no way to test in advance...).

Creating a new instance config did _not_ work for me - the Jobs did not recognise that the new config could build them, even though they had all of the same capabilities.


author: Przemek Bruski
body: The following workaround will solve the problem with the new images:

In your instance setup script (available under image configuration in Bamboo), add these two lines:  

```
sed -i s/2012.09/2013.03/ /etc/yum.confyum clean all
```

comments: author: Robert Watkins
body: Will the default images be updated with this (for OnDemand, at least), or will that wait for the next release?


author: Przemek Bruski
body: We'll get fixed images onto OnDemand.

5.1 may end up on OD quite soon, so I can't tell yet whether this will hapen with 5.1 or already with 5.0.

The images will most likely be the same in any case...


author: Daum
body: Using the old images works fine just create a new one...inconvinent but works.


author: Robert Watkins
body: Ditto - I need to install firefox so I can run Selenium tests, and that's completely borked with the new image.

At this point I'm tempted to toss away the Atlassian provided images and set up my own.

comments: author: Robert Watkins
body: FYI: I solved my issue by changing the CentOS version we were using as a base for getting down firefox's dependencies.

The new AMI is based off either Amazon 2012.09 or Amazon 2013.03 (there's conflicting evidence - the internal identifier says 2013.03, but the yum config says 2012.09). Either way, these are based off Centos 6 - and using that as an additional repo instead of Centos 5 let me install what I needed.


author: Daum
body: FYI we're having a similar issue with the php-mysql, php-intl, and a few others, here is the pastie from it: <http://pastie.org/8271703>


Tags: cloud

elastic

yum