apt_install() fails, no previous apt_update or repo out of date
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Charm Helpers |
Fix Released
|
Medium
|
Chris Glass | ||
Landscape Server |
Fix Released
|
Medium
|
Unassigned | ||
15.07 |
Fix Released
|
Medium
|
Chris Glass | ||
Cisco-odl |
Fix Released
|
Medium
|
Chris Glass | ||
keystone (Juju Charms Collection) |
Fix Released
|
Undecided
|
Chris Glass | ||
nova-cloud-controller (Juju Charms Collection) |
Fix Released
|
Undecided
|
Chris Glass |
Bug Description
The charm tried to install python-netaddr, but apt-get failed:
2015-05-14 20:38:04 INFO unit.keystone/
2015-05-14 20:38:04 INFO unit.keystone/
2015-05-14 20:38:04 INFO unit.keystone/
2015-05-14 20:38:04 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 INFO unit.keystone/
2015-05-14 20:38:05 ERROR juju.worker.
That's an odd error, it's almost as if apt-get update wasn't run, or failed. But I don't see either in the log (attached).
After that was logged, I ssh'ed into the system, and indeed, apt-get complains that python-netaddr cannot be authenticated:
root@juju-
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libfreetype6 os-prober
Use 'apt-get autoremove' to remove them.
Suggested packages:
ipython python-netaddr-docs
The following NEW packages will be installed:
python-netaddr
0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
Need to get 849 kB of archives.
After this operation, 4,216 kB of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
python-netaddr
Install these packages without verification? [y/N] n
E: Some packages could not be authenticated
Policy shows it comes from the ubuntu archive:
root@juju-
python-netaddr:
Installed: (none)
Candidate: 0.7.10-1ubuntu1.1
Version table:
0.
500 http://
0.7.10-1build1 0
500 http://
root@juju-
After I manually ran apt-get update, apt-get install was happy:
root@juju-
Ign http://
Get:1 http://
Get:2 http://
Get:3 http://
Get:4 http://
Get:5 http://
Get:6 http://
Ign http://
Hit http://
Hit http://
Ign http://
Hit http://
Get:7 http://
Hit http://
Get:8 http://
Hit http://
Hit http://
Hit http://
Hit http://
Hit http://
Hit http://
Get:9 http://
Get:10 http://
Get:11 http://
Get:12 http://
Get:13 http://
Get:14 http://
Ign http://
Ign http://
Fetched 2,106 kB in 4s (469 kB/s)
Reading package lists... Done
root@juju-
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libfreetype6 os-prober
Use 'apt-get autoremove' to remove them.
Suggested packages:
ipython python-netaddr-docs
The following NEW packages will be installed:
python-netaddr
0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
Need to get 849 kB of archives.
After this operation, 4,216 kB of additional disk space will be used.
Get:1 http://
Fetched 849 kB in 0s (22.8 MB/s)
Selecting previously unselected package python-netaddr.
(Reading database ... 26045 files and directories currently installed.)
Preparing to unpack .../python-
Unpacking python-netaddr (0.7.10-1ubuntu1.1) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up python-netaddr (0.7.10-1ubuntu1.1) ...
root@juju-
Related branches
- David Britton (community): Approve
- Adam Collard (community): Approve
-
Diff: 72 lines (+11/-7)3 files modifiedcharmhelpers/contrib/network/ip.py (+5/-3)
charmhelpers/contrib/openstack/templating.py (+2/-1)
charmhelpers/contrib/templating/jinja.py (+4/-3)
- Liam Young (community): Approve
-
Diff: 72 lines (+11/-7)3 files modifiedcharmhelpers/contrib/network/ip.py (+5/-3)
charmhelpers/contrib/openstack/templating.py (+2/-1)
charmhelpers/contrib/templating/jinja.py (+4/-3)
- OpenStack Charmers: Pending requested
-
Diff: 534 lines (+257/-53)10 files modifiedhooks/charmhelpers/cli/__init__.py (+1/-5)
hooks/charmhelpers/cli/commands.py (+4/-4)
hooks/charmhelpers/contrib/network/ip.py (+5/-3)
hooks/charmhelpers/contrib/openstack/context.py (+8/-9)
hooks/charmhelpers/contrib/openstack/templating.py (+2/-1)
hooks/charmhelpers/contrib/openstack/utils.py (+7/-5)
hooks/charmhelpers/contrib/storage/linux/ceph.py (+224/-2)
hooks/charmhelpers/contrib/storage/linux/utils.py (+3/-2)
hooks/charmhelpers/core/hookenv.py (+1/-20)
hooks/charmhelpers/core/host.py (+2/-2)
- OpenStack Charmers: Pending requested
-
Diff: 562 lines (+280/-53)11 files modifiedhooks/charmhelpers/cli/__init__.py (+1/-5)
hooks/charmhelpers/cli/commands.py (+4/-4)
hooks/charmhelpers/cli/hookenv.py (+23/-0)
hooks/charmhelpers/contrib/network/ip.py (+5/-3)
hooks/charmhelpers/contrib/openstack/context.py (+8/-9)
hooks/charmhelpers/contrib/openstack/templating.py (+2/-1)
hooks/charmhelpers/contrib/openstack/utils.py (+7/-5)
hooks/charmhelpers/contrib/storage/linux/ceph.py (+224/-2)
hooks/charmhelpers/contrib/storage/linux/utils.py (+3/-2)
hooks/charmhelpers/core/hookenv.py (+1/-20)
hooks/charmhelpers/core/host.py (+2/-2)
Changed in charm-helpers: | |
assignee: | nobody → Chris Glass (tribaal) |
Changed in charm-helpers: | |
status: | Confirmed → In Progress |
importance: | Undecided → Medium |
Changed in charm-helpers: | |
status: | In Progress → Fix Committed |
Changed in landscape: | |
importance: | Undecided → Medium |
Changed in keystone (Juju Charms Collection): | |
assignee: | nobody → Chris Glass (tribaal) |
Changed in nova-cloud-controller (Juju Charms Collection): | |
assignee: | nobody → Chris Glass (tribaal) |
Changed in keystone (Juju Charms Collection): | |
status: | New → In Progress |
Changed in nova-cloud-controller (Juju Charms Collection): | |
status: | New → In Progress |
Changed in landscape: | |
milestone: | none → 15.08 |
Changed in keystone (Juju Charms Collection): | |
status: | Fix Committed → Fix Released |
Changed in nova-cloud-controller (Juju Charms Collection): | |
status: | Fix Committed → Fix Released |
tags: | added: kanban-cross-team |
tags: | removed: kanban-cross-team |
Changed in landscape: | |
status: | Fix Committed → Fix Released |
milestone: | 15.08 → 15.07 |
Changed in charm-helpers: | |
status: | Fix Committed → Fix Released |
I think it's just a missing apt-get update. The code does:
try: install( 'python- netaddr' )
import netaddr
except ImportError:
apt_
import netaddr
And apt_install() does not call apt_update(). Also see https:/ /bugs.launchpad .net/charm- helpers/ +bug/1397808