Project

General

Custom queries

Profile

Actions

Bug #5071

closed

Debian package management: can't specify a repository (ex: "-t wheezy-backports")

Added by Olivier Chédru almost 11 years ago. Updated over 7 years ago.

Status:
Rejected
Priority:
N/A
Category:
Techniques
Target version:
Severity:
Major - prevents use of part of Rudder | no simple workaround
UX impact:
User visibility:
Getting started - demo | first install | level 1 Techniques
Effort required:
Priority:
59
Name check:
Fix check:
Regression:

Description

Steps to reproduce with Rudder 2.10.2:
- Create a directive "APT package manager configuration" (1.0) with the following parameters:
- Check "Also add the following package repositories"
- Repository 1: URL = http://debian.proxad.net/debian, distribution = wheezy-backports, Use main = Yes
- Create a directive "Package management for Debian / Ubuntu / APT systems" (2.0) with the following parameters:
- Define package version to install: use criteria below
- Package name: rsyslog
- Packet version match: == (or >=)
- Packet version number: 7.6.3

Assign both directives to the same rule targeting a node running Debian 7.5.

The directives stay in the status "Repaired", 0%, with the following details:
Performed repair action for deb package rsyslog with policy: update


Related issues 3 (0 open3 closed)

Related to Rudder - Bug #5244: Technique 'Package management for RHEL / CentOS / SuSE / RPM systems' v5.1: Unable to update a package without version set but still report a successRejected2014-07-08Actions
Related to Rudder - Bug #4999: Technique rpmPackageInstallation: Specified version is not taken into accountReleasedJonathan CLARKE2014-06-11Actions
Related to Rudder - Bug #10241: "Package management" technique missing "allow untrusted" switchReleasedBenoît PECCATTEActions
Actions #1

Updated by Olivier Chédru almost 11 years ago

Note the Debian repository is properly set in /etc/apt/sources.list.d/rudder-apt.list, but the package is not upgraded.

Actions #2

Updated by Nicolas PERRON over 10 years ago

As far I can see, your repaired status could be due to CFEngine trying to compare a version not matched. The installed version is not ok and older than the promised one, then CFEngine will try to update.
Trying to update could fail/succeed but will send a repaired report. It seems to be the same problem than #5244.

Actions #3

Updated by Nicolas PERRON over 10 years ago

The repository you added seems to have rsyslog 7.6.3 but still not having all required dependencies:

[...]
 rsyslog depends on libc6 (>= 2.17); however:
  Version of libc6:amd64 on system is 2.13-38+deb7u1.
 rsyslog depends on libestr0 (>= 0.1.4); however:
  Version of libestr0 on system is 0.1.1-2.
[...]

Maybe this is why rsyslog is never updated. Did you try manually to check if it was possible ?

Actions #4

Updated by Olivier Chédru over 10 years ago

Yes, it was OK.
I used the following manual procedure to upgrade rsyslog on a freshly installed Debian 7.5:

echo "deb http://debian.proxad.net/debian wheezy-backports main" >> /etc/apt/sources.list
apt-get update
apt-get -y -t wheezy-backports install rsyslog

Actions #5

Updated by Nicolas PERRON over 10 years ago

  • Status changed from New to Discussion
  • Assignee set to Jonathan CLARKE
  • Target version set to 2.6.17

The problem is that "Package management for Debian / Ubuntu / APT systems" is not able to manage packages with backport repositories.
APT needs to be configured in order to use backports by default. For example, adding a file /etc/apt/apt.conf.d/myconf containing:

APT::Default-Release "wheezy-backports";

I see two options:
- Add new version of "APT package manager configuration" to add custom configuration into APT (a textbox where options could be added into /etc/apt/apt.conf.d/99rudder). It seems to me that this is the simpliest way and it's flexible.
- Add new version of "Package management for Debian / Ubuntu / APT systems" to add an option if we want to use a backport or not. It seems to me that this is more complex as different package_method would be used in function of being installed by backport or not.

What's your opinion Jon ?

Actions #6

Updated by Jonathan CLARKE over 10 years ago

  • Assignee changed from Jonathan CLARKE to Nicolas PERRON

I don't think it's a good idea to change the settings on hosts for apt via a config file. This could have undesired side effects.

However, using the "-t" option as in Olivier's example above looks great.

Sure, it would require a new package_method, but we could pass a parameter to the package method to specify the name to use.

Actions #7

Updated by Nicolas PERRON over 10 years ago

  • Assignee changed from Nicolas PERRON to Jonathan CLARKE
  • % Done changed from 0 to 100
  • Pull Request set to https://github.com/Normation/rudder-techniques/pull/452

I've made a Pull Request: https://github.com/Normation/rudder-techniques/pull/452

Jon, would you like to review it ?

Actions #11

Updated by François ARMAND about 10 years ago

  • Assignee changed from Jonathan CLARKE to Benoît PECCATTE
  • Target version changed from 2.6.20 to 2.10.10

Benoit, could you take a look at that one please (on 2.10).

Actions #48

Updated by Alexis Mousset over 7 years ago

  • Status changed from New to Rejected
  • Priority changed from 58 to 59

Fixed in #10241 for the "Package" technique, closing.

It is now possible to pass arbitrary options to apt.

Actions

Also available in: Atom PDF