Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Source order affects package dependencies #387

Open
0 opened this issue May 5, 2017 · 4 comments
Open

Source order affects package dependencies #387

0 opened this issue May 5, 2017 · 4 comments

Comments

@0
Copy link
Contributor

0 commented May 5, 2017

It's common for Ubuntu packages to be present in multiple repositories. For example, updates to a package in xenial might go to xenial-security and xenial-updates at different times. In the absence of priorities, apt deals with this by installing the latest version from any repository.

This works fine with bcfg2 so long as the dependencies are the same across repositories. If they differ, then bcfg2 arbitrarily selects the dependencies from the first repository that has the package (ref).

I've found this to be problematic with kernel packages. For example, linux-headers-generic currently depends on linux-headers-4.4.0-75-generic in xenial-security and on linux-headers-4.4.0-77-generic in xenial-updates. If I have xenial-security listed first, then bcfg2 wants to see version 75, but apt installs 77.

My workaround for this is to rearrange the sources as necessary, but that won't work in every case.

@AlexanderS
Copy link
Member

I have a local patch, that adds priorities to the sources. It should be possible to select the package with the highest version, if multiple sources have the same priority. (Even if it could be really hard to compare debian version numbers.)

@solj
Copy link
Member

solj commented May 10, 2017

@AlexanderS that could be useful but I guess we achieve the same effect by sorting? What case is covered by having a priority that wouldn't be covered by sorting sources?

@AlexanderS
Copy link
Member

A priority attribute would allow us to define two or more sources with equal priorities.

@xschlef
Copy link
Contributor

xschlef commented Jun 27, 2018

To add to this:
bcfg2 could also generate the /etc/apt/preferences to reflect the new source ordering on the clients.

This would limit the choices for the priority values to apt preference settings, but would reflect the source ordering to clients that run with packages version: any

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants