手机版
你好,游客 登录 注册 搜索
背景:
阅读新闻

Cloud Foundry使用dev_setup部署多节点之排错分析

[日期:2012-10-19] 来源:Linux社区  作者:wearenoth [字体:大 中 小]

问题1:VMC无法登陆

问题描述如下:大致情况就是,我可以注册,但是在登陆过程中出现了404错误。

  1. root@arch3:~/cloudfoundry/vcap/dev_setup/bin# vmc target api.vcap.me 
  2. Successfully targeted to [http://api.vcap.me] 
  3. root@arch3:~/cloudfoundry/vcap/dev_setup/bin# vmc register 
  4. Email: y...@...com 
  5. Password: *** 
  6. Verify Password: *** 
  7. Creating New User: OK 
  8. Attempting login to [http://api.vcap.me] 
  9. Problem with login to 'http://api.vcap.me', 404: entity not found or 
  10. inaccessible, try again or register for an account. 

解决方法:这个问题我找到的答案就是-将vmc重0.3.21版本降级到0.3.18版本,为什么会这样,我就不明白了。

问题2:部署的应用无法启动:

问题描述如下:这个是从网上copy下来的,当时情况是我执行vmc push hello,然后在Staging Application的时候出现了下面的这个错误。

  1. root@Ubuntu:/home/cloudfoundry# vmc start hello 
  2.  
  3. Staging Application: .............Error (JSON 504):<html><head><title>504 Gatewa... 
  4.  
  5. root@ubuntu:/home/cloudfoundry#  vmc update hello 
  6.  
  7. Uploading Application: 
  8.  
  9.     Checking for available resources:  ok 
  10.  
  11.    Processing resources:  ok 
  12.  
  13.    Packing application:  ok 
  14.  
  15.    Uploading (706K): ok 
  16.  
  17. Error (JSON 504):<html> 
  18.  
  19. <head><title>504 Gatewa... 

解决方法:这个东西我在网上没有找到答案,然后我们返回看我们开始部署的时候是怎么写的配置文件:

  1. --- 
  2. deployment: 
  3.   name: "rest" 
  4. jobs: 
  5.   install: 
  6.     - nats_server 
  7.     - cloud_controller: 
  8.         builtin_services: 
  9.           - redis 
  10.           - mongodb 
  11.           - mysql 
  12.     - router 
  13.     - health_manager 
  14.     - ccdb 
  15.     - redis_node: 
  16.         index: "0" 
  17.     - redis_gateway 
  18.     - mysql_gateway 
  19.     - mongodb_node: 
  20.         index: "0" 
  21.     - mongodb_gateway       

问题就是在于,新的CF已经将stager(打包)这个功能从原有的Cloud Controller中剥离开了。

所以我们需要做的事情就很简单了,重新装一次rest,只是这次记得将stager给添加上就可以了。

  1. vm@vm:~/test$ vim /home/vm/cloudfoundry/vcap/dev_setup/deployments/sample/multihos 
  2. t_mysql/rest.yml   
  3.  
  4. --- 
  5. deployment: 
  6.   name: "rest" 
  7. jobs: 
  8.   install: 
  9.     - nats_server 
  10.     - cloud_controller: 
  11.         builtin_services: 
  12.           - redis 
  13.           - mongodb 
  14.           - mysql 
  15.     - router 
  16.     - stager 
  17.     - health_manager 
  18.     - ccdb 
  19.     - redis_node: 
  20.         index: "0" 
  21.     - redis_gateway 
  22.     - mysql_gateway 
  23.     - mongodb_node: 
  24.         index: "0" 
  25.     - mongodb_gateway 

然后再试试看

vm@vm:~/cloudfoundry/vcap/dev_setup$ vmc start hello 
Staging Application 'hello': OK   

linux
相关资讯       Cloud Foundry  节点  dev_setup  多节点 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款