can't juju add machine when multiple images with same arch/release exist

Bug #1317680 reported by Chris J Arges
22
This bug affects 3 people
Affects Status Importance Assigned to Milestone
juju-core
Fix Released
Medium
Unassigned
juju-core (Ubuntu)
Invalid
High
Unassigned

Bug Description

Setup the following:
$ cat ~/.juju/environments.yaml

default: local

environments:
  local:
    type: local
    container: kvm

Execute the following:
$ juju add-machine

You will see:
$ juju status
environment: local
machines:
  "0":
    agent-state: started
    agent-version: 1.18.1.1
    dns-name: localhost
    instance-id: localhost
    series: trusty
  "1":
    agent-state-info: '(error: kvm container creation failed: exit status 1)'
    instance-id: pending
    series: trusty

I have the following:
$ uvt-simplestreams-libvirt query
release=trusty arch=amd64 label=daily (20140318)
release=trusty arch=amd64 label=release (20140416.1)

If I do:
$ uvt-simplestreams-libvirt purge
$ uvt-simplestreams-libvirt sync release=trusty arch=amd64

Then I get this working correctly:
$ juju add-machine
$ juju status
environment: local
machines:
  "0":
    agent-state: started
    agent-version: 1.18.1.1
    dns-name: localhost
    instance-id: localhost
    series: trusty
  "3":
    agent-state: pending
    instance-id: arges-local-machine-3
    series: trusty
    hardware: arch=amd64 cpu-cores=1 mem=512M root-disk=8192M
services: {}

ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: juju-core 1.18.1-0ubuntu1
ProcVersionSignature: Ubuntu 3.13.0-18.38-generic 3.13.6
Uname: Linux 3.13.0-18-generic x86_64
ApportVersion: 2.14.1-0ubuntu3
Architecture: amd64
Date: Thu May 8 17:02:34 2014
Dependencies:
 gcc-4.9-base 4.9-20140406-0ubuntu1
 libc6 2.19-0ubuntu6
 libgcc1 1:4.9-20140406-0ubuntu1
 multiarch-support 2.19-0ubuntu6
InstallationDate: Installed on 2014-03-17 (52 days ago)
InstallationMedia: Ubuntu-Server 14.04 LTS "Trusty Tahr" - Alpha amd64 (20140313)
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: juju-core
UpgradeStatus: No upgrade log present (probably fresh install)

tags: added: cloud-installer
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in juju-core (Ubuntu):
status: New → Confirmed
Revision history for this message
Robie Basak (racb) wrote :

Looks like Juju isn't disambiguating enough in this case. Adding "label=release" to the uvt-kvm call that Juju makes will probably fix this specific case.

I'm not sure how best to manage the situation when the user can manually pull in more images than Juju does. uvt-kvm currently requires that the image be unambiguously specified. I wonder if there are other cases that won't be covered?

Having said that, assuming that Juju still syncs only from the default stream, adding a "label=release" shouldn't hurt anything and should fix this.

Curtis Hovey (sinzui)
Changed in juju-core:
status: New → Triaged
importance: Undecided → Medium
tags: added: kvm streams
Revision history for this message
Robie Basak (racb) wrote :

Also see: https://bugs.launchpad.net/ubuntu/+source/juju-core/+bug/1322302/comments/32 for a related use case that may have a similar issue.

tags: added: simplestreams
Revision history for this message
Anastasia (anastasia-macmood) wrote :

Juju now differentiates images based on streams as well.

Changed in juju-core:
status: Triaged → Fix Released
Changed in juju-core (Ubuntu):
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.