Priorities for custom repositories aren't set properly on Ubuntu
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Fuel for OpenStack |
Fix Committed
|
High
|
Ihor Kalnytskyi |
Bug Description
Fuel version info (6.1 build #476): http://
Priorities for custom repositories on Ubuntu don't work properly because of incorrect pinning:
root@node-1:~# cat /etc/apt/
Package: *
Pin: release l=trusty-
Pin-Priority: 1200
root@node-1:~# apt-cache policy | grep -A 2 http.*obs
500 http://
release o=obs:/
origin obs-1.mirantis.com
root@node-1:~# apt-get install cinder-api
Reading package lists... Done
Building dependency tree
Reading state information... Done
cinder-api is already the newest version.
After I modified pinning for 'mos-extra' repository, APT priorities became to work fine:
root@node-1:~# cat /etc/apt/
Package: *
Archive: ubuntu
Pin: release l=trusty-
Pin-Priority: 1200
root@node-1:~# apt-cache policy | grep -A 2 http.*obs
1200 http://
release o=obs:/
origin obs-1.mirantis.com
http://
Steps to reproduce:
1. Create environment on Ubuntu
2. Go to 'Settings' tab and add some extra Ubuntu repository and set priority for it
3. Deploy cluster
4. Go to some cluster node and check extra repo priority using `apt-cache policy` command
Expected result:
- priority is set as defined
Actual result:
- priority is default
Diagnostic snapshot is attached.
Changed in fuel: | |
status: | New → Confirmed |
Changed in fuel: | |
assignee: | Fuel Python Team (fuel-python) → Igor Kalnitsky (ikalnitsky) |
Well, it looks like apt pinning doesn't use the 'Archive' info for flat repos. For instance, we don't see the 'a=...' information in 'apt-cache policy':
release o=obs:/ /build. opensuse. org/trusty- fuel-6. 1-stable- 6740/ubuntu, n=ubuntu, l=trusty- fuel-6. 1-stable- 6740,c=
and we see that Archive is actually Null in 'apt-cache dump' output:
File: /var/lib/ apt/lists/ obs-1.mirantis. com:82_ trusty- fuel-6. 1-stable- 6740_ubuntu_ Packages opensuse. org/trusty- fuel-6. 1-stable- 6740/ubuntu fuel-6. 1-stable- 6740
Type: Debian Package Index
Size: 7187
ID: 2
Flags: 0
Time: Wed, 27 May 2015 10:09:36 GMT
Archive: (null)
Component:
Version: (null)
Origin: obs://build.
Site: obs-1.mirantis.com
Label: trusty-
Architecture: (null)
We should either remove Archive field from Release file in flat repos or inject skip hacks into nailgun/ fuel-agent/ preseed.