Page MenuHomePhabricator

Nodepool instances have duplicate entry for jessie-backports/main
Closed, ResolvedPublic


apt complains with:

W: Duplicate sources.list entry jessie-backports/main amd64 Packages

A grep in /etc/ yields:

/etc/apt/sources.list:deb jessie-backports main
/etc/apt/sources.list.d/debian-backports.list:deb jessie-backports main contrib non-free
/etc/apt/sources.list.d/debian-backports.list:deb-src jessie-backports main contrib non-free

From /dib/puppet/ciiimage.pp we use include ::apt which does:

# enable backports for Debian systems
if $::operatingsystem == 'Debian' {
    apt::repository { 'debian-backports':
        uri         => '',
        dist        => "${::lsbdistcodename}-backports",
        components  => 'main non-free contrib',
        comment_old => true,

I am not sure how we end up having it as well in /etc/apt/sources.list

Event Timeline

hashar raised the priority of this task from to Needs Triage.
hashar updated the task description. (Show Details)
hashar added a subscriber: hashar.
hashar claimed this task.

Same repository, not the same components and thus apt reject both:

- deb jessie-backports main
+ deb jessie-backports main contrib non-free

Turns out I forgot I have filled this bug and ended up fixing it via T126246: Provision openjdk-7-jre-headless on Nodepool slaves.

Although T126246 has much of the information, lets reuse this bug to clean up the solution I found.

Related bugs were T126230 and T126246

The fix is 1d667fb6ccb24c83abc7dfcdecd2a52eae2c9ae6 . That pass to the dib delian-minimal element 'main,contrib,non-free' to forge the /etc/apt/sources.list.

So we now:

export DIB_DEBIAN_COMPONENTS='main,contrib,non-free'

The fix I proposed upstream has been merged . Have to update our documentation I guess.

hashar triaged this task as Medium priority.Mar 14 2016, 7:42 PM
hashar moved this task from In-progress to Done on the Continuous-Integration-Scaling board.
hashar moved this task from Backlog to Patch merged upstream on the Upstream board. got merged and is included in diskimage-builder as of 1.12.0. Have to rebuild an image with that version or a later one and confirm it works all fine then we can get this task closed.

Change 270873 abandoned by Hashar:
dib: only use 'main' Debian component

Got fixed with dib 1.12.0 and us doing:

export DIB_DEBIAN_COMPONENTS='main,contrib,non-free'

Change 270872 had a related patch set (by Hashar) published:
apt: make components parameterizable

Change 270872 abandoned by Hashar:
apt: make components parameterizable

No more needed.

Got fixed with dib 1.12.0 and us doing:

export DIB_DEBIAN_COMPONENTS='main,contrib,non-free'

Works fine now since dib 1.12.0 and setting DIB_DEBIAN_COMPONENTS='main,contrib,non-free'