Completely fails to honour constraints

Bug #1285343 reported by Aaron Bentley
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
Triaged
High
Unassigned

Bug Description

Using juju 1.16.6 and the ec2 provider:

If I specify a root disk of 10 G and mem of 8G, I get a root disk of 8G (less than 10) and mem of 1.7 G (less than 8).

In order to get an m1.large, I tried specifying 7G mem and 420G root-disk, but this resulted in the same instance type being deployed.

$ juju deploy jenkins --constraints "root-disk=10G mem=8G"
$ juju status
environment: juju-ci3
machines:
  "0":
    agent-state: started
    agent-version: 1.16.6
    dns-name: ec2-54-84-244-38.compute-1.amazonaws.com
    instance-id: i-59745278
    instance-state: running
    series: precise
    hardware: arch=amd64 cpu-cores=1 cpu-power=200 mem=3840M root-disk=8192M
  "1":
    agent-state: started
    agent-version: 1.16.6
    dns-name: ec2-54-84-242-24.compute-1.amazonaws.com
    instance-id: i-06fce526
    instance-state: running
    series: precise
    hardware: arch=amd64 cpu-cores=2 cpu-power=500 mem=1740M root-disk=8192M
services:
  jenkins:
    charm: cs:precise/jenkins-9
    exposed: false
    units:
      jenkins/0:
        agent-state: started
        agent-version: 1.16.6
        machine: "1"
        open-ports:
        - 8080/tcp
        public-address: 172.31.44.6

Revision history for this message
Martin Packman (gz) wrote :

The root-disk was not supported in 1.16 and there is a known bug that an invalid constraint causes all constraints to be ignored and the defaults used instead.

Try not specifuing root-disk and the mem constraint should then be obeyed.

Revision history for this message
Aaron Bentley (abentley) wrote :

root-disk has been documented for months, and there is no indication that it is not supported: https://juju.ubuntu.com/docs/reference- constraints.html

Even William Reade recommends using it:
http://askubuntu.com/questions/425710/how-can-i-determine-the-available-amount-of-disk-space-when-using-a-charm/427029#427029

We have been using it since at least December, but I believe we started using it much earlier.

On Canonistack, with no root-disk constraint, we get 2.2 G, and with the constraint we get 9.9G.

Do you have evidence that this is *not* a supported feature? AFAICT, it *is* supported.

Revision history for this message
John A Meinel (jameinel) wrote : Re: [Bug 1285343] Re: Completely fails to honour constraints

It has been in trunk for a long time. But you were using 1.16.6 which does
not have it.

John
=:->
On Mar 3, 2014 10:50 PM, "Aaron Bentley" <email address hidden>
wrote:

> root-disk has been documented for months, and there is no indication
> that it is not supported: https://juju.ubuntu.com/docs/reference-
> constraints.html
>
> Even William Reade recommends using it:
>
> http://askubuntu.com/questions/425710/how-can-i-determine-the-available-amount-of-disk-space-when-using-a-charm/427029#427029
>
> We have been using it since at least December, but I believe we started
> using it much earlier.
>
> On Canonistack, with no root-disk constraint, we get 2.2 G, and with the
> constraint we get 9.9G.
>
> Do you have evidence that this is *not* a supported feature? AFAICT, it
> *is* supported.
>
> --
> You received this bug notification because you are subscribed to juju-
> core.
> https://bugs.launchpad.net/bugs/1285343
>
> Title:
> Completely fails to honour constraints
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/juju-core/+bug/1285343/+subscriptions
>

Revision history for this message
Aaron Bentley (abentley) wrote :

1.16.6 does have it. As I showed, I get 2.2 G without it, and 9.9 G with it on Canonistack. If the constraint wasn't in stable, I would get an error like this:
~$ juju bootstrap --constraints "rot-disk=10G mem=8G"
error: invalid value "rot-disk=10G mem=8G" for flag --constraints: unknown constraint "rot-disk"

"root-disk" is accepted by 1.16.6 and earlier, and on Canonistack it has the intended effect.

Revision history for this message
Martin Packman (gz) wrote :

Did you verify on the machine if it really had the lower root-disk and memory values juju reported? This may be bug 1183259 with nova reporting flavors incorrectly when deletes are involved.

Revision history for this message
Aaron Bentley (abentley) wrote :

I got the lower values with the ec2 provider, so I don't think a nova bug could be the cause.

Revision history for this message
Martin Packman (gz) wrote :

Geh, should have seen that. Okay, so r1972 added root-disk support for EC2, which is not in the 1.16 branch.

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.