Ubuntu Pastebin

Paste from Marco Ceppi at Wed, 10 Feb 2016 22:01:27 +0000

Download as text
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
marco@T430:~/Projects/go/bin$ ./juju bootstrap
ERROR the name of the model must be specified
marco@T430:~/Projects/go/bin$ ./juju bootstrap aws-us-east1
error: unrecognized args: ["aws-us-east1"]
marco@T430:~/Projects/go/bin$ ./juju bootstrap --help
usage: juju bootstrap [options]
purpose: start up an environment from scratch

options:
--agent-version (= "")
    the version of tools to use for Juju agents
--auto-upgrade  (= false)
    upgrade to the latest patch release tools on first bootstrap
--bootstrap-constraints  (= )
    specify bootstrap machine constraints
--bootstrap-series (= "")
    specify the series of the bootstrap machine
--constraints  (= )
    set model constraints
--keep-broken  (= false)
    do not destroy the model if bootstrap fails
-m, --model (= "")
    juju model to operate in
--metadata-source (= "")
    local path to use as tools and/or metadata source
--to (= "")
    a placement directive indicating an instance to bootstrap
--upload-tools  (= false)
    upload local version of tools before bootstrapping

bootstrap starts a new model of the current type (it will return an error
if the model has already been bootstrapped).  Bootstrapping a model
will provision a new machine in the model and run the juju controller on
that machine.

If boostrap-constraints are specified in the bootstrap command, 
they will apply to the machine provisioned for the juju controller, 
and any future controllers provisioned for HA.

If constraints are specified, they will be set as the default constraints 
on the model for all future workload machines, 
exactly as if the constraints were set with juju set-constraints.

It is possible to override constraints and the automatic machine selection
algorithm by using the "--to" flag. The value associated with "--to" is a
"placement directive", which tells Juju how to identify the first machine to use.
For more information on placement directives, see "juju help placement".

Bootstrap initialises the cloud environment synchronously and displays information
about the current installation steps.  The time for bootstrap to complete varies
across cloud providers from a few seconds to several minutes.  Once bootstrap has
completed, you can run other juju commands against your model. You can change
the default timeout and retry delays used during the bootstrap by changing the
following settings in your environments.yaml (all values represent number of seconds):

    # How long to wait for a connection to the controller
    bootstrap-timeout: 600 # default: 10 minutes
    # How long to wait between connection attempts to a controller address.
    bootstrap-retry-delay: 5 # default: 5 seconds
    # How often to refresh controller addresses from the API server.
    bootstrap-addresses-delay: 10 # default: 10 seconds

Private clouds may need to specify their own custom image metadata, and
possibly upload Juju tools to cloud storage if no outgoing Internet access is
available. In this case, use the --metadata-source parameter to point
bootstrap to a local directory from which to upload tools and/or image
metadata.

If agent-version is specifed, this is the default tools version to use when running the Juju agents.
Only the numeric version is relevant. To enable ease of scripting, the full binary version
is accepted (eg 1.24.4-trusty-amd64) but only the numeric version (eg 1.24.4) is used.
By default, Juju will bootstrap using the exact same version as the client.

See Also:
   juju help switch
   juju help constraints
   juju help set-constraints
   juju help placement         
marco@T430:~/Projects/go/bin$ ./juju create-controller
ERROR unrecognized command: juju create-controller
marco@T430:~/Projects/go/bin$ ./juju bootstrap -m obaam
ERROR open /home/marco/.local/share/juju/environments.yaml: no such file or directory
marco@T430:~/Projects/go/bin$ ./juju init
A boilerplate model configuration file has been written to /home/marco/.local/share/juju/environments.yaml.
Edit the file to configure your juju model and run bootstrap.
marco@T430:~/Projects/go/bin$ cp ~/.juju/environments.yaml ~/.local/share/juju/
marco@T430:~/Projects/go/bin$ ./juju bootstrap -m obaam
Bootstrap failed, cleaning up the model.
ERROR there was an issue examining the model: model "obaam" not found
marco@T430:~/Projects/go/bin$ ./juju bootstrap
ERROR the name of the model must be specified
marco@T430:~/Projects/go/bin$ ./juju bootstrap -m aws-us-east1
Bootstrapping model "aws-us-east1"
Bootstrap failed, destroying model
WARNING cannot delete default security group: cannot retrieve default security group: "juju-33fb7cc9-5024-40c7-8d4a-d9317df118bb": The security group 'juju-33fb7cc9-5024-40c7-8d4a-d9317df118bb' does not exist in default VPC 'vpc-c18a66a5' (InvalidGroup.NotFound)
ERROR failed to bootstrap model: cannot read product data, invalid URL "https://juju-dist.s3.amazonaws.com/tools/streams/v1/com.ubuntu.juju-devel-tools.sjson" not found
marco@T430:~/Projects/go/bin$ ./juju bootstrap -m aws-us-east1 --upload-tools
Bootstrapping model "aws-us-east1"
Starting new instance for initial controller
Launching instance
 - i-a6f28326
Building tools to upload (2.0-alpha2.1-trusty-amd64)
Installing Juju agent on bootstrap instance
Waiting for address
Attempting to connect to 54.210.173.37:22
Attempting to connect to 172.31.56.233:22
Logging to /var/log/cloud-init-output.log on remote host
Running apt-get update
Running apt-get upgrade
Installing package: curl
Installing package: cpu-checker
Installing package: bridge-utils
Installing package: rsyslog-gnutls
Installing package: cloud-utils
Installing package: cloud-image-utils
Installing package: tmux
Bootstrapping Juju machine agent
Starting Juju machine agent (jujud-machine-0)
Bootstrap agent installed
-> aws-us-east1
Waiting for API to become available
Waiting for API to become available
Waiting for API to become available
Bootstrap complete
marco@T430:~/Projects/go/bin$ ./juju status
[Services] 
NAME       STATUS EXPOSED CHARM 

[Units] 
ID      WORKLOAD-STATE AGENT-STATE VERSION MACHINE PORTS PUBLIC-ADDRESS MESSAGE 

[Machines] 
ID         STATE   DNS           INS-ID     SERIES AZ         
0          started 54.210.173.37 i-a6f28326 trusty us-east-1b 

marco@T430:~/Projects/go/bin$ ./juju create-model foobar
ERROR provider validation failed: invalid EC2 provider config: model has no access-key or secret-key
marco@T430:~/Projects/go/bin$ ./juju create-model foobar --debug
2016-02-10 21:54:24 INFO juju.cmd supercommand.go:59 running juju [2.0-alpha2 gc go1.6rc2]
2016-02-10 21:54:24 DEBUG juju.api api.go:155 trying cached API connection settings - endpoints [54.210.173.37:17070 172.31.56.233:17070]
2016-02-10 21:54:24 INFO juju.api api.go:267 connecting to API addresses: [54.210.173.37:17070 172.31.56.233:17070]
2016-02-10 21:54:24 INFO juju.api apiclient.go:484 dialing "wss://54.210.173.37:17070/model/104679a0-40a5-44d5-8879-019fb988e32a/api"
2016-02-10 21:54:24 INFO juju.api apiclient.go:484 dialing "wss://172.31.56.233:17070/model/104679a0-40a5-44d5-8879-019fb988e32a/api"
2016-02-10 21:54:24 INFO juju.api apiclient.go:277 connection established to "wss://54.210.173.37:17070/model/104679a0-40a5-44d5-8879-019fb988e32a/api"
2016-02-10 21:54:24 DEBUG juju.api api.go:484 API hostnames unchanged - not resolving
2016-02-10 21:54:24 DEBUG juju.api api.go:514 cacheChangedAPIInfo: serverUUID="104679a0-40a5-44d5-8879-019fb988e32a"
2016-02-10 21:54:24 DEBUG juju.api.modelmanager modelmanager.go:28 base.clientFacade{facadeCaller:base.facadeCaller{facadeName:"ModelManager", bestVersion:2, caller:(*api.state)(0xc820206640)}, closer:(*api.state)(0xc820206640)}
2016-02-10 21:54:24 DEBUG juju.cmd.juju.controller createmodel.go:134 create cache entry for "foobar"
2016-02-10 21:54:24 DEBUG juju.environs.configstore disk.go:349 writing jenv file
2016-02-10 21:54:24 DEBUG juju.environs.configstore disk.go:473 writing jenv file to /home/marco/.local/share/juju/models/foobar.jenv
2016-02-10 21:54:24 DEBUG juju.cmd.juju.controller createmodel.go:158 error found, remove cache entry
2016-02-10 21:54:24 DEBUG juju.api apiclient.go:510 health ping failed: connection is shut down
2016-02-10 21:54:24 ERROR cmd supercommand.go:448 provider validation failed: invalid EC2 provider config: model has no access-key or secret-key
Download as text