storage -cinder(2)
来源:互联网 发布:游族影业 游族网络 编辑:程序博客网 时间:2024/06/06 06:54
在storage -cinder(1)中说过,知道host的情况下,直接使用rpc call在指定host上创建volume,否则则需要调度,就是是提到的volume_scheduler,到调度host
上create volume。
self.scheduler_rpcapi.create_volume #这里的scheduler_rpcapi即 cinder/scheduler/rpcapi.py
在rpcapi.py中cast的消息,被cinder/scheduler/manager.py收到:
self._wait_for_scheduler()
flow_engine = create_volume.get_flow(context,
db, self.driver,
request_spec,
filter_properties,
volume_id,
snapshot_id,
image_id)
需要指出的是,这里的self.driver默认为:cinder.scheduler.filter_scheduler.FilterScheduler
在cinder中大量使用了task flow,看来一开始写cinder的人很喜欢这个库:), 在taskflow中ScheduleCreateVolumeTask的execute里:
self.driver_api.schedule_create_volume(context, request_spec, filter_properties), 即调用FilterScheduler中的scheduler_create_volume方法
其中最主要的_schedule方法,关于cinder中所有调度的部分都在这里。
如果是各个厂商自己的存储,用厂商自己的client对存储池中进行操作,这些个schedule的动作就没有必要了。
和nova生成instance一样,cinder的调度最终也是为了决定存储的位置,对应的host是哪个,因此有host_manager, 而host_manager中
则调用很多的filter进行过滤,过滤之后用weight打分,决定最终的位置。
hosts = self.host_manager.get_all_host_states
hosts = self.host_manager.get_filtered_hosts#过滤
weighed_hosts = self.host_manager.get_weighed_hosts#打分
在mark link中,对cinder的架构讲的很好,末尾也提到了不足,实际上,对Cinder的无数的driver来说(每个有存储的厂家,一般的都有自己的块存储产品),目前Ceph
是十分火的,我曾经听人说,以后搞Ceph的会比openstack本身要更火,本来Ceph也是开源的,Redhat以其在开源社区的影响力,自己在推glusterfs。看cinder部分的
源码,我们除了能在cinder/volume/drivers/中看到Ceph的影子(RBD Driver), 也能在cinder/backup/drivers中看到Ceph Driver,Ceph以其同时支持块存储和对象
存储而受到很多人的亲睐(对于很多想使用openstack的人而言,并非所有人都想要自己的对象存储,可能干脆就不要swift模块,Ceph的这一特点,使得客户在选择的时候
更加倾向)。
前一篇中cinder/volume/drivers中块存储可以用来放镜像,用户数据,虚机等,提高了openstack的可用性,而backup driver中的主要功能,我们可以从openstack
官方wiki中看到,其对volume进行备份(提供增量/差异化的备份策略)
mark link
http://www.storageonline.com.cn/storage/san-storage/openstack-hanvan-block-service-cinder-installation-and-configuration-guide/
http://specs.openstack.org/openstack/cinder-specs/specs/kilo/incremental-backup.html
加一句,整合openstack和ceph,在ceph的官网有详细教程 http://ceph.com/docs/master/rbd/rbd-openstack/
- storage, especially cinder(2)
- storage -cinder(2)
- OpenStack Storage Services --- Cinder
- storage, especially cinder(1)
- storage - cinder(1)
- openstack Storage 组件 Swift 和 Cinder
- OpenStack: Storage 组件 Swift 和 Cinder(转)
- 发现 OpenStack: Storage 组件 Swift 和 Cinder
- Cinder
- Implementing OpenStack Cinder with NetApp Storage on the Rackspace Private Cloud Software
- Check of pool cinder-volumes/cinder-volumes-pool failed (status:2). Manual repair required!
- 2、storage主流程
- Torch教程(2)-Storage
- Storage
- Openstack liberty 中Cinder-api启动过程源码分析2
- Openstack、Cinder
- cinder error_deleting
- cinder流程图
- 字符串中正则表达式应用
- 三种快速排序算法以及快速排序的优化
- 自定义表单的类
- 黑马day09 mysql基本语法
- c语言模拟函数画图
- storage -cinder(2)
- 给定一个整数s=1+1/(1+2)+1/(1+2+3)+...+1/(1+2+3+...+n)
- codesign returns User Interaction is not allowed
- 华为机试—手机电量
- poj 2000 Gold Coins
- spring ldap pool 连接池
- 浅谈Java分布式计算
- 使用Maven编译的时候跳过运行测试
- usb鼠标驱动