Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uploading stemcell failed: unable to find AKI (using bosh-bootstrap) #755

Closed
aeneasr opened this issue Feb 19, 2015 · 26 comments
Closed

Uploading stemcell failed: unable to find AKI (using bosh-bootstrap) #755

aeneasr opened this issue Feb 19, 2015 · 26 comments

Comments

@aeneasr
Copy link

aeneasr commented Feb 19, 2015

I created a EC2 instance (ubuntu) in the eu-central-1 region with an elastic ip, ssh'd into it and ran:

sudo apt-get update
sudo apt-get install ruby 1.9.3
sudo apt-get install ruby-dev 1.9.3
sudo apt-get install libxml2 libxml2-dev libsqlite3-dev make libxslt1-dev g++ libpq-dev libmysqld-dev libmysqlclient-dev
sudo gem install bundle
sudo gem install bosh-bootstrap

After that I tried to deploy micro bosh on AWS, which resulted in: Uploading stemcellcreate stemcell failed: unable to find AKI:

bosh-bootstrap deploy
1. AWS
2. OpenStack
3. vSphere
Choose your infrastructure: 1

Using provider AWS

Access key: ****
Secret key: ****

1. *US East (Northern Virginia) Region (us-east-1)
2. US West (Oregon) Region (us-west-2)
3. US West (Northern California) Region (us-west-1)
4. EU (Ireland) Region (eu-west-1)
5. EU (Frankfurt) Region (eu-central-1)
6. Asia Pacific (Singapore) Region (ap-southeast-1)
7. Asia Pacific (Sydney) Region (ap-southeast-2)
8. Asia Pacific (Tokyo) Region (ap-northeast-1)
9. South America (Sao Paulo) Region (sa-east-1)
10. China (Beijing) Region (cn-north-1)
Choose AWS region: 5

Confirming: Using AWS EC2/eu-central-1
1. subnet-f3fb1b88 (172.31.0.0/20)
2. subnet-0834f561 (172.31.16.0/20)
Choose a subnet: 2

Choose IP |172.31.16.4| 

Confirming: Using address 172.31.16.4
Reusing security group ssh-vpc-53e9153a for the VPC
 -> no additional ports opened
Created security group dns-server-vpc-53e9153a for the VPC
 -> opened dns-server-vpc-53e9153a ports UDP 53..53 from IP range 0.0.0.0/0
Created security group bosh-vpc-53e9153a for the VPC
 -> opened bosh-vpc-53e9153a ports TCP 4222..4222 from IP range 0.0.0.0/0
 -> opened bosh-vpc-53e9153a ports TCP 6868..6868 from IP range 0.0.0.0/0
 -> opened bosh-vpc-53e9153a ports TCP 25250..25250 from IP range 0.0.0.0/0
 -> opened bosh-vpc-53e9153a ports TCP 25555..25555 from IP range 0.0.0.0/0
 -> opened bosh-vpc-53e9153a ports TCP 25777..25777 from IP range 0.0.0.0/0
Destroying key pair firstbosh... done
Acquiring a key pair firstbosh... done

Confirming: Using key pair firstbosh
Determining stemcell image/file to use... curl -O 'https://bosh-jenkins-artifacts.s3.amazonaws.com/bosh-stemcell/aws/bosh-stemcell-2847-aws-xen-ubuntu-trusty-go_agent.tgz'
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  442M  100  442M    0     0  12.7M      0  0:00:34  0:00:34 --:--:-- 16.5M
/home/ubuntu/bosh/deployments/firstbosh/bosh-stemcell-2847-aws-xen-ubuntu-trusty-go_agent.tgz
bosh micro deployment firstbosh
WARNING! Your target has been changed to `https://172.31.16.4:25555'!
Deployment set to '/home/ubuntu/bosh/deployments/firstbosh/micro_bosh.yml'
bosh -n micro deploy --update-if-exists /home/ubuntu/bosh/deployments/firstbosh/bosh-stemcell-2847-aws-xen-ubuntu-trusty-go_agent.tgz

Verifying stemcell...
File exists and readable                                     OK
Verifying tarball...
Read tarball                                                 OK
Manifest exists                                              OK
Stemcell image file                                          OK
Stemcell properties                                          OK

Stemcell info
-------------
Name:    bosh-aws-xen-ubuntu-trusty-go_agent
Version: 2847

  Started deploy micro bosh
  Started deploy micro bosh > Unpacking stemcell. Done (00:00:07)
  Started deploy micro bosh > Uploading stemcellcreate stemcell failed: unable to find AKI:
/var/lib/gems/1.9.1/gems/bosh_aws_cpi-1.2847.0/lib/cloud/aws/aki_picker.rb:15:in `pick'
/var/lib/gems/1.9.1/gems/bosh_aws_cpi-1.2847.0/lib/cloud/aws/stemcell_creator.rb:100:in `image_params'
/var/lib/gems/1.9.1/gems/bosh_aws_cpi-1.2847.0/lib/cloud/aws/stemcell_creator.rb:24:in `create'
/var/lib/gems/1.9.1/gems/bosh_aws_cpi-1.2847.0/lib/cloud/aws/cloud.rb:425:in `block in create_stemcell'
/var/lib/gems/1.9.1/gems/bosh_common-1.2847.0/lib/common/thread_formatter.rb:49:in `with_thread_name'
/var/lib/gems/1.9.1/gems/bosh_aws_cpi-1.2847.0/lib/cloud/aws/cloud.rb:405:in `create_stemcell'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:228:in `block (2 levels) in create_stemcell'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:85:in `step'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:227:in `block in create_stemcell'
/usr/lib/ruby/1.9.1/tmpdir.rb:83:in `mktmpdir'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:213:in `create_stemcell'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:118:in `create'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:98:in `block in create_deployment'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:92:in `with_lifecycle'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/deployer/instance_manager.rb:98:in `create_deployment'
/var/lib/gems/1.9.1/gems/bosh_cli_plugin_micro-1.2847.0/lib/bosh/cli/commands/micro.rb:179:in `perform'
/var/lib/gems/1.9.1/gems/bosh_cli-1.2847.0/lib/cli/command_handler.rb:57:in `run'
/var/lib/gems/1.9.1/gems/bosh_cli-1.2847.0/lib/cli/runner.rb:56:in `run'
/var/lib/gems/1.9.1/gems/bosh_cli-1.2847.0/lib/cli/runner.rb:16:in `run'
/var/lib/gems/1.9.1/gems/bosh_cli-1.2847.0/bin/bosh:7:in `<top (required)>'
/usr/local/bin/bosh:23:in `load'
/usr/local/bin/bosh:23:in `<main>'
/usr/lib/ruby/1.9.1/rake/file_utils.rb:53:in `block in create_shell_runner': Command failed with status (1): [bosh -n micro deploy --update-if-exists /h...] (RuntimeError)
    from /usr/lib/ruby/1.9.1/rake/file_utils.rb:45:in `call'
    from /usr/lib/ruby/1.9.1/rake/file_utils.rb:45:in `sh'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/helpers/bundle.rb:18:in `block in run'
    from /var/lib/gems/1.9.1/gems/bundler-1.8.2/lib/bundler.rb:247:in `block in with_clean_env'
    from /var/lib/gems/1.9.1/gems/bundler-1.8.2/lib/bundler.rb:234:in `with_original_env'
    from /var/lib/gems/1.9.1/gems/bundler-1.8.2/lib/bundler.rb:240:in `with_clean_env'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/helpers/bundle.rb:16:in `run'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:54:in `block in deploy_or_update'
    from /usr/lib/ruby/1.9.1/fileutils.rb:125:in `chdir'
    from /usr/lib/ruby/1.9.1/fileutils.rb:125:in `cd'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:52:in `deploy_or_update'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:42:in `block in deploy'
    from /usr/lib/ruby/1.9.1/fileutils.rb:125:in `chdir'
    from /usr/lib/ruby/1.9.1/fileutils.rb:125:in `cd'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:40:in `deploy'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/commands/deploy.rb:77:in `perform_microbosh_deploy'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/commands/deploy.rb:24:in `perform'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/thor_cli.rb:11:in `deploy'
    from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
    from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
    from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
    from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
    from /var/lib/gems/1.9.1/gems/bosh-bootstrap-0.16.1/bin/bosh-bootstrap:13:in `<top (required)>'
    from /usr/local/bin/bosh-bootstrap:23:in `load'
    from /usr/local/bin/bosh-bootstrap:23:in `<main>'

I've also tried to use the elastic ip but it didn't change anything:

Choose IP |172.31.0.4| 54.93.119.***

Confirming: Using address 54.93.119.***

You can find the original issue here: cloudfoundry-community-attic/bosh-bootstrap#305


The commands above are the only ones I executed on the freshly created VM

@aeneasr aeneasr changed the title Uploading stemcell failed: unable to find AKI Uploading stemcell failed: unable to find AKI (using bosh-bootstrap) Feb 19, 2015
@cppforlife
Copy link
Contributor

Can you try this in us-east-1? I'm pretty sure this is related to our pre-built stemcells. They only work in us-east-1 at this point.

@drnic: I'm not sure if/how you can pass in full aws stemcell to bosh-boostrap.

@drnic
Copy link
Contributor

drnic commented Feb 23, 2015

bosh-bootstrap should use non-light stemcell in other regions.

On Mon, Feb 23, 2015 at 3:43 PM, Dmitriy Kalinin [email protected]
wrote:

Can you try this in us-east-1? I'm pretty sure this is related to our pre-built stemcells. They only work in us-east-1 at this point.

@drnic: I'm not sure if/how you can pass in full aws stemcell to bosh-boostrap.

Reply to this email directly or view it on GitHub:
#755 (comment)

@drnic
Copy link
Contributor

drnic commented Feb 24, 2015

Should. You know. That's what it should do :) But perhaps it's discovery technique is broken? Has bosh team changed how/where stemcells are uploaded?

On Mon, Feb 23, 2015 at 3:44 PM, Dr Nic Williams [email protected]
wrote:

bosh-bootstrap should use non-light stemcell in other regions.
On Mon, Feb 23, 2015 at 3:43 PM, Dmitriy Kalinin [email protected]
wrote:

Can you try this in us-east-1? I'm pretty sure this is related to our pre-built stemcells. They only work in us-east-1 at this point.

@drnic: I'm not sure if/how you can pass in full aws stemcell to bosh-boostrap.

Reply to this email directly or view it on GitHub:
#755 (comment)

@bosh-ci-push-pull
Copy link

Nope, didn't change.

On Mon, Feb 23, 2015 at 4:31 PM, Dr Nic Williams [email protected]
wrote:

Should. You know. That's what it should do :) But perhaps it's discovery
technique is broken? Has bosh team changed how/where stemcells are uploaded?

On Mon, Feb 23, 2015 at 3:44 PM, Dr Nic Williams [email protected]
wrote:

bosh-bootstrap should use non-light stemcell in other regions.
On Mon, Feb 23, 2015 at 3:43 PM, Dmitriy Kalinin <
[email protected]>
wrote:

Can you try this in us-east-1? I'm pretty sure this is related to our
pre-built stemcells. They only work in us-east-1 at this point.
@drnic: I'm not sure if/how you can pass in full aws stemcell to

bosh-boostrap.

Reply to this email directly or view it on GitHub:
#755 (comment)


Reply to this email directly or view it on GitHub
#755 (comment).

@aeneasr
Copy link
Author

aeneasr commented Feb 24, 2015

I'll have a closer look into it tomorrow, thanks for the help :)

@simonjohansson
Copy link

I'm hitting the same issue when trying to deploy in Frankfurt.

ubuntu@vm-in-us-east-1:~$ rvm list gemsets

rvm gemsets

   ruby-2.0.0-p598 [ x86_64 ]
=> ruby-2.0.0-p598@bosh [ x86_64 ]
   ruby-2.0.0-p598@global [ x86_64 ]
ubuntu@vm-in-us-east-1:~$ gem list

*** LOCAL GEMS ***

agent_client (1.2858.0)
aws-sdk (1.60.2)
aws-sdk-v1 (1.60.2)
bigdecimal (1.2.0)
blobstore_client (1.2858.0)
bosh-bootstrap (0.16.1)
bosh-director-core (1.2858.0)
bosh-registry (1.2858.0)
bosh-stemcell (1.2858.0)
bosh-template (1.2858.0)
bosh_aws_cpi (1.2858.0)
bosh_cli (1.2858.0)
bosh_cli_plugin_micro (1.2858.0)
bosh_common (1.2858.0)
bosh_cpi (1.2858.0)
bosh_openstack_cpi (1.2858.0)
bosh_vcloud_cpi (0.7.2)
bosh_vsphere_cpi (1.2858.0)
builder (3.1.4)
bundler (1.7.6)
bundler-unload (1.0.2)
CFPropertyList (2.3.0)
cyoi (0.11.3)
daemons (1.1.9)
eventmachine (1.0.7)
excon (0.44.3)
executable-hooks (1.3.2)
fission (0.5.0)
fog (1.27.0)
fog-atmos (0.1.0)
fog-aws (0.1.1)
fog-brightbox (0.7.1)
fog-core (1.29.0)
fog-ecloud (0.0.2)
fog-json (1.0.0)
fog-profitbricks (0.0.1)
fog-radosgw (0.0.3)
fog-sakuracloud (1.0.0)
fog-serverlove (0.1.1)
fog-softlayer (0.4.1)
fog-storm_on_demand (0.1.0)
fog-terremark (0.0.4)
fog-vmfusion (0.0.1)
fog-voxel (0.0.2)
fog-xml (0.1.1)
formatador (0.2.5)
gem-wrappers (1.2.7)
highline (1.6.21)
httpclient (2.4.0)
inflecto (0.0.2)
io-console (0.4.2)
ipaddress (0.8.0)
json (1.7.7)
json_pure (1.8.2)
little-plugger (1.1.3)
log4r (1.1.10)
logging (1.8.2)
membrane (1.1.0)
mime-types (1.25.1)
minitar (0.5.4)
minitest (4.3.2)
mono_logger (1.1.0)
multi_json (1.10.1)
mysql2 (0.3.18)
net-scp (1.1.2)
net-ssh (2.9.2)
net-ssh-gateway (1.2.0)
netaddr (1.5.0)
nokogiri (1.5.11)
pg (0.15.1)
progressbar (0.9.2)
psych (2.0.0)
rack (1.6.0)
rack-protection (1.5.3)
rake (0.9.6)
rbvmomi (1.8.2)
rdoc (4.0.0)
readwritesettings (3.0.1)
redcard (1.1.0)
rest-client (1.6.8)
ruby-atmos-pure (1.0.5)
ruby-hmac (0.4.0)
rubygems-bundler (1.4.4)
rvm (1.11.3.9)
semi_semantic (1.1.0)
sequel (3.43.0)
sinatra (1.4.5)
sqlite3 (1.3.10)
terminal-table (1.4.5)
test-unit (2.0.0.0)
thin (1.5.1)
thor (0.19.1)
tilt (1.4.1)
trollop (2.1.1)
yajl-ruby (1.2.1)
ubuntu@vm-in-us-east-1:~$ bosh-bootstrap deploy
1. AWS
2. OpenStack
3. vSphere
Choose your infrastructure: 1

Using provider AWS

Access key: snippety-snip
Secret key: snippety-snip

1. *US East (Northern Virginia) Region (us-east-1)
2. US West (Oregon) Region (us-west-2)
3. US West (Northern California) Region (us-west-1)
4. EU (Ireland) Region (eu-west-1)
5. EU (Frankfurt) Region (eu-central-1)
6. Asia Pacific (Singapore) Region (ap-southeast-1)
7. Asia Pacific (Sydney) Region (ap-southeast-2)
8. Asia Pacific (Tokyo) Region (ap-northeast-1)
9. South America (Sao Paulo) Region (sa-east-1)
10. China (Beijing) Region (cn-north-1)
Choose AWS region: 5

Confirming: Using AWS EC2/eu-central-1
1. vpc-cfba5ba6 (172.31.0.0/16)
2. bosh (10.0.0.0/16)
3. EC2 only
Choose a VPC: 3
Using EC2...
Acquiring a public IP address... aaa.bbb.ccc.ddd

Confirming: Using address aaa.bbb.ccc.ddd
Reusing security group ssh
 -> no additional ports opened
Reusing security group dns-server
 -> no additional ports opened
Reusing security group bosh
 -> no additional ports opened
Destroying key pair firstbosh... done
Acquiring a key pair firstbosh... done

Confirming: Using key pair firstbosh
Determining stemcell image/file to use... curl -O 'https://bosh-jenkins-artifacts.s3.amazonaws.com/bosh-stemcell/aws/bosh-stemcell-2858-aws-xen-ubuntu-trusty-go_agent.tgz'
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  442M  100  442M    0     0  68.5M      0  0:00:06  0:00:06 --:--:-- 70.5M
/home/ubuntu/deployments/firstbosh/bosh-stemcell-2858-aws-xen-ubuntu-trusty-go_agent.tgz
bosh micro deployment firstbosh
WARNING! Your target has been changed to `https://aaa.bbb.ccc.ddd:25555'!
Deployment set to '/home/ubuntu/deployments/firstbosh/micro_bosh.yml'
bosh -n micro deploy --update-if-exists /home/ubuntu/deployments/firstbosh/bosh-stemcell-2858-aws-xen-ubuntu-trusty-go_agent.tgz

Verifying stemcell...
File exists and readable                                     OK
Verifying tarball...
Read tarball                                                 OK
Manifest exists                                              OK
Stemcell image file                                          OK
Stemcell properties                                          OK

Stemcell info
-------------
Name:    bosh-aws-xen-ubuntu-trusty-go_agent
Version: 2858

  Started deploy micro bosh
  Started deploy micro bosh > Unpacking stemcell. Done (00:00:06)
  Started deploy micro bosh > Uploading stemcelllog writing failed. can't be called from trap context
create stemcell failed: The instance ID 'i-af97f555' does not exist:
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/core/client.rb:375:in `return_or_raise'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/core/client.rb:476:in `client_request'
(eval):3:in `describe_instances'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/ec2/resource.rb:72:in `describe_call'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/ec2/instance.rb:787:in `get_resource'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/core/resource.rb:235:in `block (2 levels) in define_attribute_getter'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/core/cacheable.rb:63:in `retrieve_attribute'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/ec2/resource.rb:66:in `retrieve_attribute'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/core/resource.rb:235:in `block in define_attribute_getter'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/aws-sdk-v1-1.60.2/lib/aws/ec2/instance.rb:527:in `availability_zone'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_aws_cpi-1.2858.0/lib/cloud/aws/availability_zone_selector.rb:19:in `select_availability_zone'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_aws_cpi-1.2858.0/lib/cloud/aws/cloud.rb:172:in `block in create_disk'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_common-1.2858.0/lib/common/thread_formatter.rb:49:in `with_thread_name'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_aws_cpi-1.2858.0/lib/cloud/aws/cloud.rb:166:in `create_disk'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_aws_cpi-1.2858.0/lib/cloud/aws/cloud.rb:417:in `block in create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_common-1.2858.0/lib/common/thread_formatter.rb:49:in `with_thread_name'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_aws_cpi-1.2858.0/lib/cloud/aws/cloud.rb:405:in `create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:228:in `block (2 levels) in create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:85:in `step'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:227:in `block in create_stemcell'
/home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/tmpdir.rb:88:in `mktmpdir'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:213:in `create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:118:in `create'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:98:in `block in create_deployment'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:92:in `with_lifecycle'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/deployer/instance_manager.rb:98:in `create_deployment'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli_plugin_micro-1.2858.0/lib/bosh/cli/commands/micro.rb:179:in `perform'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli-1.2858.0/lib/cli/command_handler.rb:57:in `run'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli-1.2858.0/lib/cli/runner.rb:56:in `run'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh_cli-1.2858.0/bin/bosh:14:in `<top (required)>'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/bosh:23:in `load'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/bosh:23:in `<main>'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/ruby_executable_hooks:15:in `eval'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/ruby_executable_hooks:15:in `<main>'
/home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/rake/file_utils.rb:53:in `block in create_shell_runner': Command failed with status (1): [bosh -n micro deploy --update-if-exists /h...] (RuntimeError)
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/rake/file_utils.rb:45:in `call'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/rake/file_utils.rb:45:in `sh'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/helpers/bundle.rb:18:in `block in run'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@global/gems/bundler-1.7.6/lib/bundler.rb:236:in `block in with_clean_env'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@global/gems/bundler-1.7.6/lib/bundler.rb:223:in `with_original_env'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@global/gems/bundler-1.7.6/lib/bundler.rb:229:in `with_clean_env'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/helpers/bundle.rb:16:in `run'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:54:in `block in deploy_or_update'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/fileutils.rb:125:in `chdir'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/fileutils.rb:125:in `cd'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:52:in `deploy_or_update'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:42:in `block in deploy'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/fileutils.rb:125:in `chdir'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p598/lib/ruby/2.0.0/fileutils.rb:125:in `cd'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:40:in `deploy'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/commands/deploy.rb:77:in `perform_microbosh_deploy'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/commands/deploy.rb:24:in `perform'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/thor_cli.rb:11:in `deploy'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/gems/bosh-bootstrap-0.16.1/bin/bosh-bootstrap:13:in `<top (required)>'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/bosh-bootstrap:23:in `load'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/bosh-bootstrap:23:in `<main>'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/ruby_executable_hooks:15:in `eval'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p598@bosh/bin/ruby_executable_hooks:15:in `<main>'

ubuntu@vm-in-us-east-1:~$ du -sch deployments/firstbosh/bosh-stemcell-2858-aws-xen-ubuntu-trusty-go_agent.tgz 
443M    deployments/firstbosh/bosh-stemcell-2858-aws-xen-ubuntu-trusty-go_agent.tgz
443M    total
ubuntu@vm-in-us-east-1:~$ tar -tvf deployments/firstbosh/bosh-stemcell-2858-aws-xen-ubuntu-trusty-go_agent.tgz 
-rw-r--r-- root/root      7911 2015-02-24 21:40 apply_spec.yml
-rw-r--r-- root/root 468107204 2015-02-24 21:43 image
-rw-rw-r-- ubuntu/ubuntu   380 2015-02-24 21:43 stemcell.MF
ubuntu@vm-in-us-east-1:~$ tar zxf deployments/firstbosh/bosh-stemcell-2858-aws-xen-ubuntu-trusty-go_agent.tgz stemcell.MF
ubuntu@vm-in-us-east-1:~$ cat stemcell.MF 
---
name: bosh-aws-xen-ubuntu-trusty-go_agent
version: '2858'
bosh_protocol: 1
sha1: 1d1d26b06127dc8248211f7fb5be95987b49d36c
cloud_properties:
  name: bosh-aws-xen-ubuntu-trusty-go_agent
  version: '2858'
  infrastructure: aws
  hypervisor: xen
  disk_format: raw
  container_format: bare
  os_type: linux
  os_distro: ubuntu
  architecture: x86_64
  root_device_name: /dev/sda1

@aeneasr
Copy link
Author

aeneasr commented Feb 26, 2015

Okay so i didn't try it on us-east but i tried it in ireland - the error does not happen there so it seems to be frankfurt specific

@simonjohansson
Copy link

Anyone know what might be missing for this to work with the Frankfurt region?

The close proximity to our DCs in Netherland make it much more viable than Ireland from a connection standpoint.

@aeneasr
Copy link
Author

aeneasr commented Feb 26, 2015

The close proximity to our DCs in Netherland make it much more viable than Ireland from a connection standpoint.

+1

@drnic
Copy link
Contributor

drnic commented Feb 27, 2015

@cppforlife the log above confirms they're using the 400Mb stemcell rather than a small light stemcell.

On Thu, Feb 26, 2015 at 1:55 PM, arekkas [email protected] wrote:

The close proximity to our DCs in Netherland make it much more viable than Ireland from a connection standpoint.

+1

Reply to this email directly or view it on GitHub:
#755 (comment)

@simonjohansson
Copy link

For my own reference,
here is a thread in the bosh-dev list about producing light stemcells for all regions.

https://groups.google.com/a/cloudfoundry.org/forum/#!topic/bosh-dev/eS-ZKJaFiJw

@simonjohansson
Copy link

Hi. Any updates on this?

@cppforlife
Copy link
Contributor

@simonjohansson I think I figured out what may be the problem. You are using full stemcell which means bosh micro deploy will try to create an AMI on the fly. Now your jumpbox instance is in us-east-1 -- guessing from vm-in-us-east-1 hostname. When AWS CPI tries to make an AMI on the fly it actually uses instance it's running on as a bootstrapping env and to do that it needs to find it in the AWS by id. That's not going to work since you have picked completely different region.

I think if you move your jumpbox to the same region where you are trying to deploy, AWS CPI will properly create a stemcell.

Please reopen if this is not the case.

@simonjohansson
Copy link

@cppforlife good catch!
I will try with a jumpbox in Frankfurt and see if I have better luck :)

@simonjohansson
Copy link

Still an issue(seems to be the same as @arekkas now)

ubuntu@machine-in-frankfurt:~$ bosh-bootstrap deploy
1. AWS
2. OpenStack
3. vSphere
Choose your infrastructure: 1

Using provider AWS

Access key: asdf
Secret key: asdf

1. *US East (Northern Virginia) Region (us-east-1)
2. US West (Oregon) Region (us-west-2)
3. US West (Northern California) Region (us-west-1)
4. EU (Ireland) Region (eu-west-1)
5. EU (Frankfurt) Region (eu-central-1)
6. Asia Pacific (Singapore) Region (ap-southeast-1)
7. Asia Pacific (Sydney) Region (ap-southeast-2)
8. Asia Pacific (Tokyo) Region (ap-northeast-1)
9. South America (Sao Paulo) Region (sa-east-1)
10. China (Beijing) Region (cn-north-1)
Choose AWS region: 5

Confirming: Using AWS EC2/eu-central-1
1. vpc-cfba5ba6 (172.31.0.0/16)
2. bosh (10.0.0.0/16)
3. EC2 only
Choose a VPC: 2
1. public (10.0.0.0/24)
2. subnet-61b6b619 (172.31.0.0/20)
3. subnet-779d7d1e (172.31.16.0/20)
Choose a subnet: 1

Choose IP |10.0.0.4| 

Confirming: Using address 10.0.0.4
Reusing security group ssh-vpc-0ff20a66 for the VPC
 -> no additional ports opened
Reusing security group dns-server-vpc-0ff20a66 for the VPC
 -> no additional ports opened
Reusing security group bosh-vpc-0ff20a66 for the VPC
 -> no additional ports opened
Destroying key pair firstbosh... done
Acquiring a key pair firstbosh... done

Confirming: Using key pair firstbosh
Determining stemcell image/file to use... curl -O 'https://bosh-jenkins-artifacts.s3.amazonaws.com/bosh-stemcell/aws/bosh-stemcell-2881-aws-xen-ubuntu-trusty-go_agent.tgz'
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  445M  100  445M    0     0  12.7M      0  0:00:34  0:00:34 --:--:-- 17.0M
/home/ubuntu/deployments/firstbosh/bosh-stemcell-2881-aws-xen-ubuntu-trusty-go_agent.tgz
bosh micro deployment firstbosh
WARNING! Your target has been changed to `https://10.0.0.4:25555'!
Deployment set to '/home/ubuntu/deployments/firstbosh/micro_bosh.yml'
bosh -n micro deploy --update-if-exists /home/ubuntu/deployments/firstbosh/bosh-stemcell-2881-aws-xen-ubuntu-trusty-go_agent.tgz

Verifying stemcell...
File exists and readable                                     OK
Verifying tarball...
Read tarball                                                 OK
Manifest exists                                              OK
Stemcell image file                                          OK
Stemcell properties                                          OK

Stemcell info
-------------
Name:    bosh-aws-xen-ubuntu-trusty-go_agent
Version: 2881

  Started deploy micro bosh
  Started deploy micro bosh > Unpacking stemcell. Done (00:00:07)
  Started deploy micro bosh > Uploading stemcelllog writing failed. can't be called from trap context
create stemcell failed: unable to find AKI:
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_aws_cpi-1.2881.0/lib/cloud/aws/aki_picker.rb:15:in `pick'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_aws_cpi-1.2881.0/lib/cloud/aws/stemcell_creator.rb:100:in `image_params'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_aws_cpi-1.2881.0/lib/cloud/aws/stemcell_creator.rb:24:in `create'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_aws_cpi-1.2881.0/lib/cloud/aws/cloud.rb:425:in `block in create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_common-1.2881.0/lib/common/thread_formatter.rb:49:in `with_thread_name'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_aws_cpi-1.2881.0/lib/cloud/aws/cloud.rb:405:in `create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:228:in `block (2 levels) in create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:85:in `step'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:227:in `block in create_stemcell'
/home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/tmpdir.rb:88:in `mktmpdir'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:213:in `create_stemcell'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:118:in `create'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:98:in `block in create_deployment'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:92:in `with_lifecycle'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/deployer/instance_manager.rb:98:in `create_deployment'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli_plugin_micro-1.2881.0/lib/bosh/cli/commands/micro.rb:179:in `perform'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli-1.2881.0/lib/cli/command_handler.rb:57:in `run'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli-1.2881.0/lib/cli/runner.rb:56:in `run'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh_cli-1.2881.0/bin/bosh:16:in `<top (required)>'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/bosh:23:in `load'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/bosh:23:in `<main>'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/ruby_executable_hooks:15:in `eval'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/ruby_executable_hooks:15:in `<main>'
/home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/rake/file_utils.rb:53:in `block in create_shell_runner': Command failed with status (1): [bosh -n micro deploy --update-if-exists /h...] (RuntimeError)
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/rake/file_utils.rb:45:in `call'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/rake/file_utils.rb:45:in `sh'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/helpers/bundle.rb:18:in `block in run'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@global/gems/bundler-1.8.5/lib/bundler.rb:247:in `block in with_clean_env'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@global/gems/bundler-1.8.5/lib/bundler.rb:234:in `with_original_env'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@global/gems/bundler-1.8.5/lib/bundler.rb:240:in `with_clean_env'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/helpers/bundle.rb:16:in `run'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:54:in `block in deploy_or_update'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/fileutils.rb:125:in `chdir'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/fileutils.rb:125:in `cd'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:52:in `deploy_or_update'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:42:in `block in deploy'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/fileutils.rb:125:in `chdir'
    from /home/ubuntu/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/fileutils.rb:125:in `cd'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/microbosh.rb:40:in `deploy'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/commands/deploy.rb:77:in `perform_microbosh_deploy'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/cli/commands/deploy.rb:24:in `perform'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/lib/bosh-bootstrap/thor_cli.rb:11:in `deploy'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/gems/bosh-bootstrap-0.16.1/bin/bosh-bootstrap:13:in `<top (required)>'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/bosh-bootstrap:23:in `load'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/bosh-bootstrap:23:in `<main>'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/ruby_executable_hooks:15:in `eval'
    from /home/ubuntu/.rvm/gems/ruby-2.0.0-p643@bosh/bin/ruby_executable_hooks:15:in `<main>'
ubuntu@asdf:~$ du -sch deployments/firstbosh/bosh-stemcell-2881-aws-xen-ubuntu-trusty-go_agent.tgz 
446M    deployments/firstbosh/bosh-stemcell-2881-aws-xen-ubuntu-trusty-go_agent.tgz
446M    total
ubuntu@asdf:~$ tar zxf deployments/firstbosh/bosh-stemcell-2881-aws-xen-ubuntu-trusty-go_agent.tgz stemcell.MF
ubuntu@asdf:~$ cat stemcell.MF
---
name: bosh-aws-xen-ubuntu-trusty-go_agent
version: '2881'
bosh_protocol: 1
sha1: d6e9c2aa7b1df7ea2d4b314c0f57f49fb13f855a
cloud_properties:
  name: bosh-aws-xen-ubuntu-trusty-go_agent
  version: '2881'
  infrastructure: aws
  hypervisor: xen
  disk_format: raw
  container_format: bare
  os_type: linux
  os_distro: ubuntu
  architecture: x86_64
  root_device_name: /dev/sda1

@djvdorp
Copy link

djvdorp commented May 27, 2015

We're running into the exact same issue as described above by @arekkas .

@cppforlife cppforlife reopened this May 27, 2015
@riccardomc
Copy link

The problem seems to be in bosh_aws_cpi aki_picker module. It expects to find a kernel image (AKI) with a name matching a certain regex.

In Frankfurt such an AKI is not available. It easy to verify it with:

aws ec2 --region=eu-central-1 describe-images --filters \
        Name=image-type,Values=kernel    \
        Name=owner-alias,Values=amazon \
        Name=architecture,Values=x86_64 | grep ImageLocation | grep pv-grub

which returns:

"ImageLocation": "amzn-ami-eu-central-1/pv-grub-hd0_1.04-x86_64.gz.manifest.xml", 
"ImageLocation": "amzn-ami-eu-central-1/pv-grub2-hd0_2.02-1.b2-x86_64.xz.manifest.xml",

This patch bypasses the problem, and a way to monkey patch the module can be found in this fork.

However, this is far from being a solution. The same issue pops up again later on in the bosh prepare deployment step.

@drnic
Copy link
Contributor

drnic commented May 28, 2015 via email

@drnic
Copy link
Contributor

drnic commented May 28, 2015

Ahh, you're patching terraform-aws-cf-install. It might be that you need to
run the patching inside the created jumpbox and run the commands manually.

/cc @longnguyen11288

On Thu, May 28, 2015 at 9:35 AM, Dr Nic Williams [email protected]
wrote:

The command bosh prepare deployment is from bosh-workspace - its entirely
optional to use it to upload stemcells. Manually upload the new stemcell to
your bosh.

Dr Nic Williams
Stark & Wayne LLC - consultancy for Cloud Foundry users
http://drnicwilliams.com
http://starkandwayne.com
cell +1 (415) 860-2185
twitter @drnic

@riccardomc
Copy link

Thanks for the reply.

Yes, you are right, but the provision.sh script is uploaded to the jump/bastion instance. Is this what you mean?

@drnic
Copy link
Contributor

drnic commented May 28, 2015

Correct. After it fails, you should be able Ssh into the jumpbox and continue.

On Thu, May 28, 2015 at 9:38 AM, Riccardo M. Cefala
[email protected] wrote:

Thanks for the reply.

Yes, you are right, but the provision.sh script is uploaded to the jump/bastion instance. Is this what you mean?

Reply to this email directly or view it on GitHub:
#755 (comment)

@lnguyen
Copy link
Member

lnguyen commented May 28, 2015

you can ssh into jumpbox and return provision.sh

make provision should be able to run it again from terraform folder

@riccardomc
Copy link

Another update.

Executing again make provision fails while trying bosh -n deploy with:

Started preparing deployment > Binding stemcells. Failed: Stemcell `bosh-aws-xen-ubuntu-trusty-go_agent/2977' doesn't exist (00:00:00)

So I tried to upload the stemcell manually from the bastion instance:

bosh upload stemcell ./workspace/deployments/microbosh/deployments/bosh-vpc-8c28eee5/bosh-stemcell-2977-aws-xen-ubuntu-trusty-go_agent.tgz

Which also fails with Uploading stemcellcreate stemcell failed: unable to find AKI. This means that aki_picker.rb on the BOSH instance needs to be patched as well. After applying the patch, make provision continues.

Sadly, now I am running into this:
cloudfoundry-attic/bosh-lite#265

djvdorp added a commit to djvdorp/terraform-aws-cf-install that referenced this issue Oct 24, 2015
@dpb587-pivotal
Copy link
Contributor

@ljfranklin, I vaguely recall some work and refactoring around AKI selection since this issue was created. Do you happen to know if this is still an issue or can it be closed?

@ljfranklin
Copy link
Contributor

@dpb587 possibly related to this change from March 2016, but honestly I have no idea. I definitely haven't seen this in the last 6 months. You're probably safe to close this out.

@dpb587-pivotal
Copy link
Contributor

Closing - feel free to open an issue on https://github.com/cloudfoundry-incubator/bosh-aws-cpi-release and reference this if you continue seeing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants