设为首页 收藏本站
查看: 1910|回复: 0

[经验分享] vSphere部署Cloud Foundry V2 (3) ---- micro bosh 部署

[复制链接]

尚未签到

发表于 2016-1-8 09:21:56 | 显示全部楼层 |阅读模式
Cloud Foundry V2 的文章目录在 Cloud Foundry V2 相关文章目录
我会不定期的做一些文章的更改,如有不便之处还要谅解。
在部署中遇到了什么问题可以在下面留言。
本博客的所有yml stemcell 和 release 都能在百度云上下载 http://pan.baidu.com/s/1pJHkPYV
 
如果你有对配置文件或者CF运维有什么更好的想法请联系我,我非常需要你的帮助

1、下载 stemcells
  创建2个文件夹 deployments 和 stemcells。

mkdir -p deployments
mkdir -p stemcells
  进入stemcells文件夹下载 stemcell

cd ~/stemcells
  显示stemcell 版本 

bosh public stemcells
| Name |
+-----------------------------------------------------------------+
| bosh-stemcell-2427-aws-xen-ubuntu.tgz |
| bosh-stemcell-2652-aws-xen-centos.tgz |
| bosh-stemcell-2739-aws-xen-centos-go_agent.tgz |
| bosh-stemcell-2427-aws-xen-ubuntu-go_agent.tgz |
| bosh-stemcell-2710-aws-xen-ubuntu-lucid-go_agent.tgz |
| bosh-stemcell-2652-aws-xen-ubuntu-lucid.tgz |
| bosh-stemcell-2739-aws-xen-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.1-aws-xen-centos-go_agent.tgz |
| bosh-stemcell-2719.1-aws-xen-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.2-aws-xen-centos-go_agent.tgz |
| bosh-stemcell-2719.2-aws-xen-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.3-aws-xen-ubuntu-trusty-go_agent.tgz |
| light-bosh-stemcell-2427-aws-xen-ubuntu.tgz |
| light-bosh-stemcell-2652-aws-xen-centos.tgz |
| light-bosh-stemcell-2739-aws-xen-centos-go_agent.tgz |
| light-bosh-stemcell-2427-aws-xen-ubuntu-go_agent.tgz |
| light-bosh-stemcell-2710-aws-xen-ubuntu-lucid-go_agent.tgz |
| light-bosh-stemcell-2652-aws-xen-ubuntu-lucid.tgz |
| light-bosh-stemcell-2739-aws-xen-ubuntu-trusty-go_agent.tgz |
| light-bosh-stemcell-2719.1-aws-xen-centos-go_agent.tgz |
| light-bosh-stemcell-2719.1-aws-xen-ubuntu-trusty-go_agent.tgz |
| light-bosh-stemcell-2719.2-aws-xen-centos-go_agent.tgz |
| light-bosh-stemcell-2719.2-aws-xen-ubuntu-trusty-go_agent.tgz |
| light-bosh-stemcell-2719.3-aws-xen-ubuntu-trusty-go_agent.tgz |
| light-bosh-stemcell-2739-aws-xen-hvm-centos-go_agent.tgz |
| light-bosh-stemcell-2739-aws-xen-hvm-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2427-openstack-kvm-ubuntu.tgz |
| bosh-stemcell-2624-openstack-kvm-centos.tgz |
| bosh-stemcell-2624-openstack-kvm-ubuntu-lucid.tgz |
| bosh-stemcell-2739-openstack-kvm-centos-go_agent.tgz |
| bosh-stemcell-2739-openstack-kvm-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2652-openstack-kvm-ubuntu-lucid-go_agent.tgz |
| bosh-stemcell-2719.1-openstack-kvm-centos-go_agent.tgz |
| bosh-stemcell-2719.1-openstack-kvm-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.2-openstack-kvm-centos-go_agent.tgz |
| bosh-stemcell-2719.2-openstack-kvm-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.3-openstack-kvm-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2427-vcloud-esxi-ubuntu.tgz |
| bosh-stemcell-2652-vcloud-esxi-ubuntu-lucid.tgz |
| bosh-stemcell-2732-vcloud-esxi-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2710-vcloud-esxi-ubuntu-lucid-go_agent.tgz |
| bosh-stemcell-2427-vsphere-esxi-ubuntu.tgz |
| bosh-stemcell-2624-vsphere-esxi-centos.tgz |
| bosh-stemcell-2739-vsphere-esxi-centos-go_agent.tgz |
| bosh-stemcell-2427-vsphere-esxi-ubuntu-go_agent.tgz |
| bosh-stemcell-2710-vsphere-esxi-ubuntu-lucid-go_agent.tgz |
| bosh-stemcell-2624-vsphere-esxi-ubuntu-lucid.tgz |
| bosh-stemcell-2739-vsphere-esxi-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.1-vsphere-esxi-centos-go_agent.tgz |
| bosh-stemcell-2719.1-vsphere-esxi-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.2-vsphere-esxi-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-2719.2-vsphere-esxi-centos-go_agent.tgz |
| bosh-stemcell-2719.3-vsphere-esxi-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-370-warden-boshlite-ubuntu-trusty-go_agent.tgz |
| bosh-stemcell-53-warden-boshlite-ubuntu.tgz |
| bosh-stemcell-370-warden-boshlite-centos-go_agent.tgz |
| bosh-stemcell-64-warden-boshlite-ubuntu-lucid-go_agent.tgz |
+-----------------------------------------------------------------+
  选择合适的版本下载

bosh download public stemcell bosh-stemcell-2427-vsphere-esxi-ubuntu.tgz
  等待下载完成 

bosh-stemcell: 9% |ooo             | 35.9MB 128.5KB/s ETA: 00:46:51
  

2、配置vSphere
  1、新建文件夹对虚拟机分组: 从 vCenter 的导航栏中,选择“主页”(Home) ->“清单”(Inventory) ->“虚拟机和模板”(VMs and Templates) 视图,然后按如下所示创建文件夹:


  这些文件夹随后将用来对 BOSH 和 Cloud Foundry 的虚拟机进行分组。在上例中,“templatefolderbosh”用来存放 BOSH stemcell。“vmfolderbosh”用来存放 BOSH 节点。“templatefolder”用来存放 Cloud Foundry stemcell。“vmfolder”用来存放 Cloud Foundry 节点。
  
  2、从“主页”(Home) ->“清单”(Inventory) ->“数据存储”(Datastores) 视图中,选择NFSDataStore数据存储,并浏览该存储。

  创建一个用来存储虚拟机的子文件夹。在本例中,我们将此子文件夹命名为“boshdeployer”。此文件夹名称将成为我们部署清单中的“disk_path”参数的值

  

3、配置bosh模板
  进入deployments目录创建micro01的文件夹

cd ~/deployments/
mkdir micro01
  编写micro_bosh的配置文件

vim micro_bosh.yml
  一下内容可以参考

---
name: micro
network:
ip: 192.168.1.100
netmask: 255.255.255.0
gateway: 192.168.1.1
dns:
- 8.8.8.8
cloud_properties:
name: VM Network
resources:
persistent_disk: 16384
cloud_properties:
ram: 2048
disk: 16384
cpu: 2
cloud:
plugin: vsphere
properties:
agent:
ntp:
- time.bnu.edu.cn
- ntp02.las01.emcatmos.com
vcenters:
- host: 192.168.1.6
user: administrator
password: ******
datacenters:
- name: vDataCenter
vm_folder: zhangqiaoqi_CF/vm_folder
template_folder: zhangqiaoqi_CF/template_folder
disk_path: boshdeployer
datastore_pattern: NFSDataStore
persistent_datastore_pattern: NFSDataStore
allow_mixed_datastores: true
clusters:
- vCluster
  检测配置文件是否正确

bosh micro deployment ~/deployments/micro01
WARNING! Your target has been changed to `https://192.168.1.203:25555'!
Deployment set to '/home/base/deployments/micro01/micro_bosh.yml'
  

3、部署 micro—bosh

bosh micro deploy ~/stemcells/bosh-stemcell-2427-vsphere-esxi-ubuntu.tgz
Deploying new micro BOSH instance `micro01/micro_bosh.yml' to `https://192.168.1.203:25555' (type 'yes' to continue): yes
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: 2427
Started deploy micro bosh
Started deploy micro bosh > Unpacking stemcell. Done (00:00:05)
Started deploy micro bosh > Uploading stemcellat depth 0 - 20: unable to get local issuer certificate
at depth 0 - 20: unable to get local issuer certificate
. Done (00:00:38)
Started deploy micro bosh > Creating VM from sc-10f0b41d-d477-49b7-a9bd-d4ac150d5549at depth 0 - 20: unable to get local issuer certificate
at depth 0 - 20: unable to get local issuer certificate
. Done (00:03:57)
Started deploy micro bosh > Waiting for the agentat depth 0 - 20: unable to get local issuer certificate
. Done (00:00:49)
Started deploy micro bosh > Updating persistent disk
Started deploy micro bosh > Create disk. Done (00:00:00)at depth 0 - 20: unable to get local issuer certificate
at depth 0 - 20: unable to get local issuer certificate
at depth 0 - 20: unable to get local issuer certificate
Started deploy micro bosh > Mount disk. Done (00:00:11)
Done deploy micro bosh > Updating persistent disk (00:00:27)
Started deploy micro bosh > Stopping agent services. Done (00:00:01)
Started deploy micro bosh > Applying micro BOSH specat depth 0 - 20: unable to get local issuer certificate
. Done (00:00:57)
Started deploy micro bosh > Starting agent services. Done (00:00:00)
Started deploy micro bosh > Waiting for the directorat depth 0 - 20: unable to get local issuer certificate
. Done (00:00:17)
Done deploy micro bosh (00:07:11)
Deployed `micro01/micro_bosh.yml' to `https://192.168.1.203:25555', took 00:07:11 to complete
  
  

运维网声明 1、欢迎大家加入本站运维交流群:群②:261659950 群⑤:202807635 群⑦870801961 群⑧679858003
2、本站所有主题由该帖子作者发表,该帖子作者与运维网享有帖子相关版权
3、所有作品的著作权均归原作者享有,请您和我们一样尊重他人的著作权等合法权益。如果您对作品感到满意,请购买正版
4、禁止制作、复制、发布和传播具有反动、淫秽、色情、暴力、凶杀等内容的信息,一经发现立即删除。若您因此触犯法律,一切后果自负,我们对此不承担任何责任
5、所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其内容的准确性、可靠性、正当性、安全性、合法性等负责,亦不承担任何法律责任
6、所有作品仅供您个人学习、研究或欣赏,不得用于商业或者其他用途,否则,一切后果均由您自己承担,我们对此不承担任何法律责任
7、如涉及侵犯版权等问题,请您及时通知我们,我们将立即采取措施予以解决
8、联系人Email:admin@iyunv.com 网址:www.yunweiku.com

所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其承担任何法律责任,如涉及侵犯版权等问题,请您及时通知我们,我们将立即处理,联系人Email:kefu@iyunv.com,QQ:1061981298 本贴地址:https://www.yunweiku.com/thread-161699-1-1.html 上篇帖子: vSphere ESX 4 安装图解 (转载) 下篇帖子: vSphere vCenter Server 安装简介(转载)
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

扫码加入运维网微信交流群X

扫码加入运维网微信交流群

扫描二维码加入运维网微信交流群,最新一手资源尽在官方微信交流群!快快加入我们吧...

扫描微信二维码查看详情

客服E-mail:kefu@iyunv.com 客服QQ:1061981298


QQ群⑦:运维网交流群⑦ QQ群⑧:运维网交流群⑧ k8s群:运维网kubernetes交流群


提醒:禁止发布任何违反国家法律、法规的言论与图片等内容;本站内容均来自个人观点与网络等信息,非本站认同之观点.


本站大部分资源是网友从网上搜集分享而来,其版权均归原作者及其网站所有,我们尊重他人的合法权益,如有内容侵犯您的合法权益,请及时与我们联系进行核实删除!



合作伙伴: 青云cloud

快速回复 返回顶部 返回列表