Page MenuHomePhabricator

Puppet on CI Trusty slaves: Duplicate declaration: Exec[jenkins-deploy kvm membership]
Closed, ResolvedPublic

Description

The Trusty CI Jenkins slaves fail puppet with:

Error: Could not retrieve catalog from remote server:
  Error 400 on SERVER: Duplicate declaration:
    Exec[jenkins-deploy kvm membership]
    is already declared in file /etc/puppet/modules/contint/manifests/packages/androidsdk.pp:19;
    cannot redeclare at /etc/puppet/modules/contint/manifests/packages/labs.pp:86

That Exec is solely needed for the Android testing for which we have a dedicated role role::ci::slave::android, though the resource is defined both in contint::packages::labs (shared by all slaves) and contint::packages::androidsdk.

Event Timeline

Change 318272 had a related patch set uploaded (by Hashar):
contint: kvm groupadd is only for android testing

https://gerrit.wikimedia.org/r/318272

Mentioned in SAL (#wikimedia-releng) [2016-10-27T10:25:03Z] <hashar> integration: purge Android packages from Trusty slaves for T149294 : salt -v '*slave-trusty*' cmd.run 'apt-get --yes remove --purge gcc-multilib lib32z1 lib32stdc++6 qemu'

Mentioned in SAL (#wikimedia-releng) [2016-10-27T10:30:26Z] <hashar> integration: on Trusty slaves, remove jenkins-deploy from KVM which is only needed for Android testing for T149294: salt -v '*slave-trusty*' cmd.run 'deluser jenkins-deploy kvm'

Solved. I have cherry picked https://gerrit.wikimedia.org/r/318272 on the CI puppetmaster and added it to the Puppet SWAT for review/merge.

@hashar, sorry for any trouble. I feel a bit out of the loop. Was this routine but irregular maintenance work that detected an error in our Puppet configuration or related to the Xdummy changes I submitted or something else?

Change 318272 merged by Alexandros Kosiaris:
contint: kvm groupadd is only for android testing

https://gerrit.wikimedia.org/r/318272

Unrelated to your Xdummy patch :]

The root cause is https://gerrit.wikimedia.org/r/#/c/300738/2..4/modules/contint/manifests/packages/labs.pp which added exec {'jenkins-deploy kvm membership' while it was already in a different manifest.

The patch got merged, the labs puppetmaster has been autorebased and kept PS2 which was reduced down to just removing that exec statement. Today I have rebased again and dropped that patch, that caused the duplication error. Rest is catching up / polishing puppet :-}

It is all set now!

I merged the xdummy change a little while ago.