Bosh Required Stemcell Not Found for Default Cpi

Stemcells¶

Cloud infrastructures require a pre-existing virtual filesystem, also called a machine prototype, to provision new deject servers. For example, to provision an AWS EC2 server you will need an AWS AMI.

The BOSH director expects that the deject servers information technology provisions volition behave in a certain way when it wants to interact with them. For example, the BOSH director expects that each cloud server will have a BOSH Agent installed and running. Nosotros will innovate the BOSH Agent below.

Towards this dual requirement - a preexisting machine paradigm, which is pre-populated with the BOSH Agent and other software and configuration - that we now introduce BOSH Stemcells.

Stemcells in Deployment Manifests¶

My standing objective with the Ultimate Guide to BOSH is that you lot feel adept as you are reading each section in sequence. Towards this goal, the abridged deployment manifests and cloud-config examples have omitted sections that are actually required by the BOSH director. We now introduce the peak-level stemcells attribute to our deployment manifests, and the stemcell attribute for each instance group.

                                                        proper name                    :                    zookeeper                    releases                    :                    -                    name                    :                    zookeeper                    version                    :                    0.0.7                    url                    :                    git+https://github.com/cppforlife/zookeeper-release                    stemcells                    :                    -                    alias                    :                    ubuntu                    bone                    :                    ubuntu-trusty                    version                    :                    latest                    instance_groups                    :                    -                    name                    :                    zookeeper                    instances                    :                    five                    stemcell                    :                    ubuntu                    -                    name                    :                    smoke-tests                    lifecycle                    :                    errand                    instances                    :                    ane                    stemcell                    :                    ubuntu                                  

Let'southward look at the stemcells section:

                                                        stemcells                    :                    -                    alias                    :                    ubuntu                    os                    :                    ubuntu-trusty                    version                    :                    latest                                  

Although each BOSH release will take an implicit preference for a stemcell (most BOSH releases are developed/tested/deployed against Ubuntu stemcells), there is no metadata or contract within a BOSH release to help bosh deploy fail fast or fail with helpful error messages if you use the incorrect stemcell.

In the case of the zookeeper deployment manifest, the selection of an bone: ubuntu-trusty stemcell tin be discovered from the project's own sample deployment manifest. Good BOSH releases or deployment projects volition provide sample BOSH deployment manifests.

The selection of bone: ubuntu-trusty means that the BOSH director must already have an ubuntu-trusty stemcell preloaded before running bosh deploy. At the time of writing at that place is no facilities in the BOSH CLI nor BOSH director to automatically detect, download, and install the required stemcell for a deployment manifest.

The version: latest means that the deployment will use the latest available stemcell that has been uploaded to the BOSH director.

To discover the available stemcells in your BOSH director:

An example output for a BOSH director with the Google CPI might be:

                                    Name                                    Version           OS             CPI  CID bosh-google-kvm-ubuntu-trusty-go_agent  3445.xi           ubuntu-trusty  -    stemcell-04231868... ~                                       3421.eleven           ubuntu-trusty  -    stemcell-61295c90... bosh-google-kvm-windows2012R2-go_agent  1200.5.0-build.ane  windows2012R2  -    ...packer-1499974558                                  

In this case we can see 2 ubuntu-trusty stemcells with the latest version 3445.11 available for deployments. We tin can likewise see a windows2012R2 stemcell has been uploaded and is available for deployments that include BOSH releases targeting Windows.

The allonym: ubuntu attribute gives the os and version combination a name that nosotros tin now employ within instance_groups. From our example manifest to a higher place, we added stemcell: ubuntu to each instance group:

                                                        instance_groups                    :                    -                    name                    :                    zookeeper                    instances                    :                    v                    stemcell                    :                    ubuntu                    -                    proper name                    :                    smoke-tests                    lifecycle                    :                    errand                    instances                    :                    1                    stemcell                    :                    ubuntu                                  

Updating Stemcells¶

Someday that bosh deploy is run, version: latest will exist adjusted to any newer stemcells that have been uploaded to the BOSH director. The BOSH managing director volition display this proposed update earlier commencing the deployment.

In this example, we have deployed a modest (2 instance) zookeeper deployment on AWS using version 3541.ix of the Ubuntu Trusty AWS Xen HVM stemcell.

                                    $ bosh stemcells Name                                     Version  Os             CPI  CID bosh-aws-xen-hvm-ubuntu-trusty-go_agent  3541.ix*  ubuntu-trusty  -    ami-3207964a light  $ bosh deployments Proper name       Release(s)       Stemcell(s)                                     Team(s)  Deject Config zookeeper  zookeeper/0.0.7  bosh-aws-xen-hvm-ubuntu-trusty-go_agent/3541.9  -        latest                                  

However since this stemcell was uploaded, a new version, 3541.10 has been released and then now we volition update our stemcell with the new version.

                                    bosh upload-stemcell https://bosh.io/d/stemcells/bosh-aws-xen-hvm-ubuntu-trusty-go_agent  Task 102  Task 102 | xv:37:21 | Update stemcell: Downloading remote stemcell (00:00:01) Task 102 | 15:37:22 | Update stemcell: Extracting stemcell annal (00:00:00) Task 102 | xv:37:22 | Update stemcell: Verifying stemcell manifest (00:00:00) Task 102 | fifteen:37:28 | Update stemcell: Checking if this stemcell already exists (00:00:00) Job 102 | 15:37:28 | Update stemcell: Uploading stemcell bosh-aws-xen-hvm-ubuntu-trusty-go_agent/3541.10 to the cloud (00:00:08) Task 102 | xv:37:36 | Update stemcell: Salve stemcell bosh-aws-xen-hvm-ubuntu-trusty-go_agent/3541.10 (ami-3fb42c47 light) (00:00:00)  Chore 102 Started  Thu Mar 29 xv:37:21 UTC 2018 Task 102 Finished Thu Mar 29 15:37:36 UTC 2018 Chore 102 Duration 00:00:15 Task 102 done  Succeeded  $ bosh stemcells Name                                     Version  OS             CPI  CID bosh-aws-xen-hvm-ubuntu-trusty-go_agent  3541.ten  ubuntu-trusty  -    ami-3fb42c47 lite ~                                        3541.9*  ubuntu-trusty  -    ami-3207964a light                                  

On the side by side deployment of zookeeper - it will exist rebuilt on the newer version of Ubuntu Trusty, 3541.10. This will crave a re-compile of the application and then the underlying VMs will be re-created once the new version is compiled.

                                    $ bosh deploy -d zookeeper manifests/zookeeper.yml  Using deployment 'zookeeper'  Release 'zookeeper/0.0.7' already exists.    stemcells: + - alias: default +   os: ubuntu-trusty +   version: '3541.10' - - alias: default -   bone: ubuntu-trusty -   version: '3541.9'  Keep? [yN]: y  Task 103  Job 103 | 15:39:08 | Preparing deployment: Preparing deployment (00:00:00) Job 103 | xv:39:08 | Preparing package compilation: Finding packages to compile (00:00:00) Task 103 | 15:39:08 | Compiling packages: golang-1.8-linux/3eac55db0483de642b1be389966327e931db3e3f (00:01:41) Task 103 | 15:forty:49 | Compiling packages: zookeeper/43ee655b89f8a05cc472ca997e8c8186457241c1 (00:00:10) Task 103 | 15:40:59 | Compiling packages: coffee/c524e46e61b37894935ae28016973e0e8644fcde (00:00:29) Job 103 | fifteen:41:28 | Compiling packages: smoke-tests/ec91e258c41471227a759c2749e7295cb65eff5a (00:00:13) Task 103 | xv:42:17 | Updating instance zookeeper: zookeeper/587013fa-a927-44b8-9ef4-1a2b73eca415 (0) (canary) (00:03:17) Task 103 | xv:45:34 | Updating instance zookeeper: zookeeper/d5f3430c-5393-44bf-8030-78732846bacd (ane) (canary) (00:03:21)  Task 103 Started  Thu Mar 29 xv:39:08 UTC 2018 Task 103 Finished Thu Mar 29 15:48:55 UTC 2018 Task 103 Elapsing 00:09:47 Task 103 washed  Succeeded                                  

Once this is consummate, we tin come across that the deployment is now running on stemcell version 3541.10.

                                    $ bosh deployments Name       Release(south)       Stemcell(southward)                                      Team(southward)  Cloud Config zookeeper  zookeeper/0.0.vii  bosh-aws-xen-hvm-ubuntu-trusty-go_agent/3541.10  -        latest                                  

Finding Stemcells¶

You can discover stemcells for your CPI at http://bosh.io/stemcells. At the time of writing, there are stemcells published for the following major operating arrangement distributions:

  • Ubuntu Linux
  • CentOS Linux
  • Windows

The Ubuntu stemcells are the most commonly used base images, are the most battle tested in product systems around the world, and seem to the author to have the almost security updates pushed out. I would recommend yous ever utilize an Ubuntu stemcell unless you have a strong requirement to choose an alternating.

The BOSH release you are deploying volition have a specific requirement for either a Linux or Windows stemcell. If the BOSH release specifically requires CentOS Linux, then it volition indicate this in its documentation and sample deployment manifests.

Low-cal Stemcells¶

On public deject infrastructures - AWS, GCP, Azure - the BOSH Core Squad publish shared motorcar images that are referenced by the stemcell file.

To rapidly confirm what I mean, let's download a stemcell for AWS and look inside information technology.

                                    ringlet -o stemcell-aws.tgz https://s3.amazonaws.com/bosh-aws-light-stemcells/low-cal-bosh-stemcell-3445.xi-aws-xen-hvm-ubuntu-trusty-go_agent.tgz                                  

The stemcell.MF file within the archive is a YAML file referencing each Amazon Motorcar Image (AMI) for each region:

                                    tar -axf stemcell-aws.tgz stemcell.MF -O                                  

The output will look like:

                                                        ---                    name                    :                    bosh-aws-xen-hvm-ubuntu-trusty-go_agent                    version                    :                    '3445.eleven'                    bosh_protocol                    :                    '1'                    sha1                    :                    da39a3ee5e6b4b0d3255bfef95601890afd80709                    operating_system                    :                    ubuntu-trusty                    cloud_properties                    :                    ami                    :                    us-gov-west-one                    :                    ami-4a0d8e2b                    ap-northeast-i                    :                    ami-17d61871                    ap-northeast-ii                    :                    ami-8f409be1                    ap-southward-1                    :                    ami-7076301f                    ap-southeast-1                    :                    ami-5bd9ae38                    ap-southeast-2                    :                    ami-eff81e8d                    ca-key-one                    :                    ami-31a41d55                    european union-cardinal-1                    :                    ami-de19afb1                    european union-west-1                    :                    ami-c0cf03b9                    eu-west-2                    :                    ami-eddbc889                    sa-east-one                    :                    ami-f89ce194                    usa-east-ane                    :                    ami-9a43afe0                    united states of america-east-ii                    :                    ami-ffab899a                    us-w-1                    :                    ami-5493a534                    us-west-two                    :                    ami-c03ec3b8                    cn-due north-1                    :                    ami-296cbc44                                  

We tin can confirm each AMI is a pre-created public AMI. For the us-eastward-one AMI:

aws-public-ami

For AWS alone, the BOSH Core Squad are creating xvi different AMIs in 16 unlike AWS regions for each AWS low-cal stemcell.

As a BOSH user, y'all exercise not need to correctly select the right ami-1234567 prototype. The BOSH director knows which region you lot are using and will utilize the advisable public automobile image from the list above.

On-Premise Stemcells¶

If you are using an on-premise deject infrastructure such as vSphere or OpenStack so your stemcells cannot reference pre-built machine images. Instead, the BOSH manager will take the job of creating automobile images within your deject infrastructure that it can use for provisioning cloud servers.

These stemcells will be essentially larger than "lite" stemcells as they contain the entire machine epitome. On-premise stemcells will exist 300+ MB in size, whereas "calorie-free" stemcells are tiny 20KB files (discussed in preceding department).

bosh-io-stemcell-sizes

Your cloud infrastructure BOSH CPI has the responsibility of converting a stemcell into a machine image.

For example, the OpenStack CPI volition collaborate with OpenStack Glance to catechumen a stemcell into an OpenStack Machine Image.

Agent¶

One of the primary reasons for BOSH stemcells, rather than allowing you to bring your own base of operations machine images, is that they have the BOSH amanuensis preinstalled.

coxcolowerve.blogspot.com

Source: https://ultimateguidetobosh.com/stemcells.html

Related Posts

0 Response to "Bosh Required Stemcell Not Found for Default Cpi"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel