cloudfoundry-attic / bosh-sample-release

Apache License 2.0
34 stars 4 forks source link

install cloudfoundry in process of bosh upload stemcell fails with(Error 100: execution expired) . How to do it? #10

Closed angJohn closed 10 years ago

angJohn commented 10 years ago

I installed cloudfoundry in process of bosh upload stemcell fails with(Error 100: execution expired) . How to do it? Thanks.

518 bosh upload stemcell bosh-stemcell-1525-vsphere-esxi-ubuntu.tgz 519 history root@CF-01:~/stemcells# !518 bosh upload stemcell bosh-stemcell-1525-vsphere-esxi-ubuntu.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-vsphere-esxi-ubuntu Version: 1525

Checking if stemcell already exists... No

Uploading stemcell...

bosh-stemcell: 100% |ooooooooooooooooooooooooooooooooooooooooooooooooooooooo| 409.7MB 24.6MB/s Time: 00:00:16

Director task 3

Error 100: execution expired

Task 3 error

For a more detailed error report, run: bosh task 3 --debug root@CF-01:~/stemcells#

How to do it? Thanks. Yanghu 杨虎

angJohn commented 10 years ago

Some detailed information below:

For a more detailed error report, run: bosh task 3 --debug root@CF-01:~/stemcells# bosh task 3 --debug

Director task 3

Logfile created on 2013-12-17 06:04:25 +0000 by logger.rb/31641

I, [2013-12-17T06:04:25.693589 #2330] INFO -- : Director Version : 1.5.0.pre.1525 I, [2013-12-17T06:04:25.693626 #2330] INFO -- : Enqueuing task: 3 I, [2013-12-17T06:04:27.056095 #3054] [0x136a08c] INFO -- : Starting task: 3 I, [2013-12-17T06:04:27.056165 #3054] [task:3] INFO -- : Creating job D, [2013-12-17T06:04:27.928615 #3054] [task:3] DEBUG -- : Acquired connection: 27264280 D, [2013-12-17T06:04:27.928807 #3054] [task:3] DEBUG -- : Released connection: 27264280 D, [2013-12-17T06:04:27.928888 #3054] [task:3] DEBUG -- : Acquired connection: 27264280 D, [2013-12-17T06:04:27.928928 #3054] [task:3] DEBUG -- : Released connection: 27264280 D, [2013-12-17T06:04:27.929004 #3054] [task:3] DEBUG -- : Acquired connection: 27264280 D, [2013-12-17T06:04:27.930887 #3054] [task:3] DEBUG -- : (0.001802s) SELECT "pg_attribute"."attname" AS "name", CAST("pg_attribute"."atttypid" AS integer) AS "oid", format_type("pg_type"."oid", "pg_attribute"."atttypmod") AS "db_type", pg_get_expr("pg_attrdef"."adbin", "pg_class"."oid") AS "default", NOT "pg_attribute"."attnotnull" AS "allow_null", COALESCE(("pg_attribute"."attnum" = ANY("pg_index"."indkey")), false) AS "primary_key", "pg_namespace"."nspname" FROM "pg_class" INNER JOIN "pg_attribute" ON ("pg_attribute"."attrelid" = "pg_class"."oid") INNER JOIN "pg_type" ON ("pg_type"."oid" = "pg_attribute"."atttypid") INNER JOIN "pg_namespace" ON ("pg_namespace"."oid" = "pg_class"."relnamespace") LEFT OUTER JOIN "pg_attrdef" ON (("pg_attrdef"."adrelid" = "pg_class"."oid") AND ("pg_attrdef"."adnum" = "pg_attribute"."attnum")) LEFT OUTER JOIN "pg_index" ON (("pg_index"."indrelid" = "pg_class"."oid") AND ("pg_index"."indisprimary" IS TRUE)) WHERE (("pg_attribute"."attisdropped" IS FALSE) AND ("pg_attribute"."attnum" > 0) AND ("pg_class"."relname" = 'vsphere_disk') AND ("pgnamespace"."nspname" !~* 'pg*|information_schema')) ORDER BY "pg_attribute"."attnum" D, [2013-12-17T06:04:27.931097 #3054] [task:3] DEBUG -- : Released connection: 27264280 E, [2013-12-17T06:04:31.935896 #3054] [task:3] ERROR -- : execution expired /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient/session.rb:775:in initialize' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient/session.rb:775:innew' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient/session.rb:775:in create_socket' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient/session.rb:732:inblock in connect' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient/session.rb:731:in connect' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient/session.rb:594:inquery' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient/session.rb:161:in query' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient.rb:1060:indo_get_block' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient.rb:869:in block in do_request' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient.rb:956:inprotect_keep_alive_disconnected' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient.rb:868:in do_request' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient.rb:756:inrequest' /var/vcap/packages/director/gem_home/gems/httpclient-2.2.4/lib/httpclient.rb:666:in post' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/soap/stub_adapter.rb:29:ininvoke_method' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/vmodl/managed_object.rb:13:in invoke_method' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/vmodl/managed_object.rb:45:inblock (3 levels) in finalize' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/soap/stub_adapter.rb:57:in invoke_property' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/vmodl/managed_object.rb:17:ininvoke_property' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/vmodl/managed_object.rb:30:in block (3 levels) in finalize' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/cloud/vsphere/client.rb:32:ininitialize' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/cloud/vsphere/config.rb:225:in new' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/cloud/vsphere/config.rb:225:inconfigure' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/cloud/vsphere/cloud.rb:30:in initialize' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/cloud/vsphere.rb:25:innew' /var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/cloud/vsphere.rb:25:in initialize' /var/vcap/packages/director/gem_home/gems/bosh_cpi-1.5.0.pre.1525/lib/cloud/provider.rb:11:innew' /var/vcap/packages/director/gem_home/gems/bosh_cpi-1.5.0.pre.1525/lib/cloud/provider.rb:11:in create' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/config.rb:190:inblock in cloud' /var/vcap/packages/ruby/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/config.rb:186:incloud' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/jobs/update_stemcell.rb:20:in initialize' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/job_runner.rb:83:innew' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/job_runner.rb:83:in perform_job' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/job_runner.rb:29:inblock in run' /var/vcap/packages/director/gem_home/gems/bosh_common-1.5.0.pre.1525/lib/common/thread_formatter.rb:46:in with_thread_name' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/job_runner.rb:29:inrun' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/lib/bosh/director/jobs/base_job.rb:12:in perform' /var/vcap/packages/director/gem_home/gems/resque-1.23.1/lib/resque/job.rb:125:inperform' /var/vcap/packages/director/gem_home/gems/resque-1.23.1/lib/resque/worker.rb:186:in perform' /var/vcap/packages/director/gem_home/gems/resque-1.23.1/lib/resque/worker.rb:149:inblock in work' /var/vcap/packages/director/gem_home/gems/resque-1.23.1/lib/resque/worker.rb:128:in loop' /var/vcap/packages/director/gem_home/gems/resque-1.23.1/lib/resque/worker.rb:128:inwork' /var/vcap/packages/director/gem_home/gems/bosh-director-1.5.0.pre.1525/bin/bosh-director-worker:76:in <top (required)>' /var/vcap/packages/director/bin/bosh-director-worker:23:inload' /var/vcap/packages/director/bin/bosh-director-worker:23:in `

' D, [2013-12-17T06:04:31.936248 #3054] [task:3] DEBUG -- : Acquired connection: 27264280 D, [2013-12-17T06:04:31.936503 #3054] [task:3] DEBUG -- : (0.000131s) BEGIN D, [2013-12-17T06:04:31.937472 #3054] [task:3] DEBUG -- : (0.000366s) UPDATE "tasks" SET "state" = 'error', "timestamp" = '2013-12-17 06:04:31.936066+0000', "description" = 'create stemcell', "result" = 'execution expired', "output" = '/var/vcap/store/director/tasks/3', "user_id" = NULL, "checkpoint_time" = '2013-12-17 06:04:25.540290+0000', "type" = 'update_stemcell' WHERE ("id" = 3) D, [2013-12-17T06:04:31.983408 #3054] [task:3] DEBUG -- : (0.045818s) COMMIT D, [2013-12-17T06:04:31.983479 #3054] [task:3] DEBUG -- : Released connection: 27264280 I, [2013-12-17T06:04:31.983565 #3054] [0x136a08c] INFO -- : Task took 4.927380744 seconds to process.

Task 3 error root@CF-01:~/stemcells#

caseymct commented 10 years ago

Hi @angJohn,

A quick note on ease of use - log cuts are great, but they're a mess in issue comments - please paste them into a gist and put the url in the comments.

It looks like you're not talking to your vCenter. The stack trace with timeout shows you in this method:

bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/soap/stub_adapter.rb:29:in invoke_method'
/var/vcap/packages/director/gem_home/gems/bosh_vsphere_cpi-1.5.0.pre.1525/lib/ruby_vim_sdk/vmodl/managed_object.rb:13:in invoke_method'

Check your setup in your microbosh deploy and try accessing your vCenter with the rvc gem. It'll help show that your id/passwd are good and that your api access works. If that is all working as expected, it would help us to see the microbosh manifest.

The docs for installing with vSphere are here. A key step is getting the vSphere permissions setup correctly to allow the API to manage vms.

~ @thansmann & @caseymct

angJohn commented 10 years ago

Hi @thansmann & @caseymct, Another question, How to do it? Thanks.

root@CF-01:/home/bosh_user# root@CF-01:/home/bosh_user# root@CF-01:/home/bosh_user# bosh deployment bosh.yml Deployment set to /home/bosh_user/bosh.yml' root@CF-01:/home/bosh_user# bosh deploy Getting deployment properties from director... Unable to get properties list from director, trying without it... Compiling deployment manifest... Cannot get current deployment information from director, possibly a new deployment Please review all changes carefully Deployingbosh.yml' to `micro01' (type 'yes' to continue): yes

Director task 46

Preparing deployment binding deployment (00:00:00)
binding releases (00:00:00)
binding existing deployment (00:00:00)
binding resource pools (00:00:00)
binding stemcells (00:00:00)
binding templates (00:00:00)
binding properties (00:00:00)
binding unallocated VMs (00:00:01)
binding instance networks (00:00:00)
Done 9/9 00:00:01

Preparing package compilation

Preparing DNS binding DNS (00:00:00)
Done 1/1 00:00:00

Creating bound missing VMs small/2 (00:02:16)
small/3 (00:02:19)
small/4 (00:02:20)
small/0 (00:02:22)
small/1 (00:02:24)
director/0 (00:02:30)
Done 6/6 00:02:30

Binding instance VMs nats/0 (00:00:01)
postgres/0 (00:00:01)
blobstore/0 (00:00:01)
health_monitor/0 (00:00:01)
redis/0 (00:00:01)
director/0 (00:00:01)
Done 6/6 00:00:01

Preparing configuration binding configuration: Error filling in template director.yml.erb.erb' fordirector/0' (line 31: Can't find property `["director.db.password"]') (00:00:00) Error 1/1 00:00:00

Error 80006: Error filling in template director.yml.erb.erb' fordirector/0' (line 31: Can't find property `["director.db.password"]')

Task 46 error

For a more detailed error report, run: bosh task 46 --debug root@CF-01:/home/bosh_user# root@CF-01:/home/bosh_user#

D, [2013-12-19T10:02:09.636069 #16220] [task:46] DEBUG -- : Redis >> DEL lock:deployment:example01 D, [2013-12-19T10:02:09.636103 #16220] [task:46] DEBUG -- : Redis >> EXEC D, [2013-12-19T10:02:09.636247 #16220] [task:46] DEBUG -- : Redis >> 0.10ms D, [2013-12-19T10:02:09.636314 #16220] [task:46] DEBUG -- : Deleted lock: lock:deployment:example01 E, [2013-12-19T10:02:09.636523 #16220] [task:46] ERROR -- : Error filling in template director.yml.erb.erb' fordirector/0' (line 3

my bosh.yml file bellow, Thanks.

angJohn commented 10 years ago

bosh.yml file:

name: example01 director_uuid: 88bd52e2-91a1-4430-810e-3acae09adf5c release: name: bosh version: 16 # change this when the version of BOSH changes

networks:

all of these settings depend on your own infrastructure setup

resource_pools:

compilation: workers: 6 network: default cloud_properties: ram: 2048 disk: 4048 cpu: 4

update: canaries: 1 canary_watch_time: 60000 update_watch_time: 60000 max_in_flight: 1

jobs:

properties: env:

blobstore: address: 10.10.10.53 port: 25251 backend_port: 25552 agent: user: agent # this creates a read only user for BOSH agents password: AgenT # this creates a password for BOSH agents director: user: director # this creates a read / write user for the BOSH Director password: DirectoR # this creates a password BOSH Director

networks: apps: default management: default

nats: user: nats password: NatS address: 10.10.10.49 port: 4222

postgres: user: bosh password: BosH address: 10.10.10.50 port: 5432 database: bosh

redis: address: 10.10.10.51 port: 25255 password: RediS

director: db: user: director password: DirectoR name: bosh-director address: 10.10.10.52 port: 25555 encryption: false

hm: http: port: 25923 user: admin #can be whatever password: admin # can be whatever director_account: user: admin # can be whatever password: admin # can be whatever intervals: poll_director: 60 poll_grace_period: 30 log_stats: 300 analyze_agents: 60 agent_timeout: 180 rogue_agent_alert: 180 loglevel: info email_notifications: false # if this is false you don't need to worry about the smtp section below email_recipients:

Thanks! yanghu

caseymct commented 10 years ago

@angJohn Please don't paste log cuts and config files here - make a new https://gist.github.com and put the link here.

The errors binding configuration: Error filling in template director.yml.erb.erb' fordirector/0' (line 31: Can't find property `["director.db.password"]') (00:00:00)

mean your bosh.yml does not have the director password. The manifest above doesn't look like it's got the right indenting, please open a gist, set the language as yaml and paste it in.

dajulia3 commented 10 years ago

@angJohn - we're going to close this as a misconfig. If you need any more help please join the Bosh Users Mailing List and ask there.