[LXC caching] images do not return to cache once deleted (due to host caching)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
juju-core |
Won't Fix
|
Low
|
Unassigned |
Bug Description
With 1.24.4, attempt to delete LXC cached images fails:
$ juju status
environment: lxc
machines:
"0":
agent-state: started
agent-version: 1.24.4.1
dns-name: localhost
instance-id: localhost
series: trusty
state-
services: {}
$ juju cached-images list
no matching images found
$ juju add-machine
created machine 1
$ juju cached-images list
Cached images:
- kind: lxc
series: trusty
arch: amd64
source-url: https:/
created: Wed, 12 Aug 2015 06:01:38 UTC
# ls -lh /var/cache/
total 179M
-rw-r--r-- 1 root root 179M Aug 12 06:01 ubuntu-
$ juju cached-images delete --kind lxc --series trusty --arch amd64
$ juju cached-images list
no matching images found
# ls -lh /var/cache/
total 179M
-rw-r--r-- 1 root root 179M Aug 12 06:01 ubuntu-
So Juju does not report an error when deleting the image and lists the image as non-existent yet it continues to reside on the filesystem and Juju continues to use it (based on the short time required for a new machine). Not only is this confusing but it also means that the environment is stuck with the initial image.
Manual removal of the image file and a subsequent add-machine brings the image back on the filesystem and the list command reports the image.
I disabled cloning because it was interfering with my tests.
$ cat ~/.juju/
default: lxc
environments:
lxc:
type: local
lxc-clone: false
tags: | added: lxc |
Changed in juju-core: | |
status: | New → Triaged |
importance: | Undecided → High |
milestone: | none → 1.25.0 |
Changed in juju-core: | |
milestone: | 1.25.0 → none |
tags: | added: docteam |
Changed in juju-core: | |
status: | Triaged → Won't Fix |
The delete command deletes from the state server cache, not the host's cache.