OpenStack组件系列☞glance简介
Glance项目提供虚拟机镜像的发现,注册,取得服务。
Glance提供restful API可以查询虚拟机镜像的metadata,并且可以获得镜像。
通过Glance,虚拟机镜像可以被存储到多种存储上,比如简单的文件存储或者对象存储(比如OpenStack中swiftx项目)。
Glance,像所有的OpenStack项目一样,遵循以下思想:
1.基于组件的架构 便于快速增加新特性
2.高可用性 支持大负荷
3.容错性 独立的进程避免串行错误
4.开放标准 对社区驱动的API提供参考实现
Glance的几个重要概念:
1.Image identifiers Image使用URI作为唯一标识,URL符合以下格式:
<Glance Server Location>/images/<ID>
Glance Server Location是镜像的所在位置, ID是镜像在Glance的唯一标识。
2.Image Statuses 共四种状态。
queued 标识该镜像ID已经被保留,但是镜像还未上传。
saving 标识镜像正在被上传。
active 标识镜像在Glance中完全可用。
killed 标识镜像上传过程中出错,镜像完全不可用。
3.Disk and Container format
Disk Format:raw vhd vmdk vdi iso qcow2 aki ari ami
Container Format: ovf bare aki ari ami
当disk format为aki ari ami时,disk format 和container format一致。
4.Image Registries
使用Glance,镜像metadata可以注册至image registries。
只要为image metadata提供了rest like API,任何web程序可以作为image registries与Glance对接。
当然,Glance也提供了参考实现。
更多信息可以参考on
Controlling Servers,来自于Glance提供的Glance registry server。
Glance提供了如下Rest-like API:
GET /images Return brief information about public images
GET /images/detail Return detailed information about public images
GET /images/<ID> Return metadata about an image in HTTP headers
POST /images Register metadata about a new image
PUT /images/<ID> Update metadata about an existing image
DELETE /images/<ID> Remove an image's metadata from the registry
通过 GET /images and GET /images/detail对镜像过滤查询
name=NAME
Filters images having a name attribute
matching NAME.container_format=FORMAT
Filters images having a container_format attribute
matching FORMATFor more information, see About Disk and Container Formats
disk_format=FORMAT
Filters images having a disk_format attribute
matching FORMATFor more information, see About Disk and Container Formats
status=STATUS
Filters images having a status attribute
matching STATUSFor more information, see About Image Statuses
size_min=BYTES
Filters images having a size attribute
greater than or equal to BYTESsize_max=BYTES
Filters images having a size attribute
less than or equal to BYTES
These two resources also accept sort parameters:
sort_key=KEY
Results will be ordered by the specified image attribute KEY.
Accepted values include id, name, status, disk_format,container_format, size, created_at (default)
and updated_at.sort_dir=DIR
Results will be sorted in the direction DIR.
Accepted values are asc for
ascending or desc (default)
for descending.
POST /images
{'image':
{'id': <ID>|None,
'name': <NAME>,
'status': <STATUS>,
'disk_format': <DISK_FORMAT>,
'container_format': <CONTAINER_FORMAT>,
'properties': [ ... ]
}
}
如果输入不满足以下条件,将返回400错误:
- status must
be non-empty, and must be one of active, saving, queued, or killed - disk_format must
be non-empty, and must be one of ari, aki, ami, raw, iso, vhd, vdi, qcow2, or vmdk - container_format must
be non-empty, and must be on of ari, aki, ami, bare, or ovf - If disk_format or container_format is ari, aki, ami,
then both disk_format and container_format must
be the same.
Glance的架构:
Glance被设计为可以使用多种后端存储。
前端通过API Server向多个Client提供服务。

Glance目前提供的参考实现中Registry Server仅是使用Sql数据库存储metadata
Glance目前支持S3,Swift,简单的文件存储及只读的HTTPS存储。
后续也可能支持其他后端,如分布式存储系统(SheepDog或Ceph)。
OpenStack组件系列☞glance简介的更多相关文章
- OpenStack组件系列☞glance搭建
第一步:glance关于数据库的操作 mysql -u root -p #登入数据库 CREATE DATABASE glance; #新建库keystone GRANT ALL PRIVILEGES ...
- OpenStack组件系列☞Keystone搭建
一:版本信息 官网:http://docs.openstack.org/newton/install-guide-rdo/keystone.html 二:部署keystone 官网文档:http:// ...
- OpenStack组件系列☞Keystone
Keystone(OpenStack Identity Service)是 OpenStack 框架中负责管理身份验证.服务规则和服务令牌功能的模块.用户访问资源需要验证用户的身份与权限,服务执行操作 ...
- OpenStack组件系列☞horizon搭建
第一步:部署horizon环境: 安装部署memcache 安装软件包 yum install memcached python-memcached 启动memcache并且设置开机自启动 syste ...
- OpenStack实践系列①openstack简介及基础环境部署
OpenStack实践系列①openstack简介及基础环境部署 一.OpenStack初探1.1 OpenStack简介 OpenStack是一整套开源软件项目的综合,它允许企业或服务提供者建立.运 ...
- Openstack Sahara组件和架构简介
1.简介 Apache Hadoop是目前被广泛使用的主流大数据处理计算框架,Sahara项目旨在使用用户能够在Openstack平台上便于创建和管理Hadoop以及其他计算框架集群,实现类似AWS的 ...
- OpenStack实践系列③镜像服务Glance
OpenStack实践系列③镜像服务Glance 3.5 Glance部署 修改glance-api和glance-registry的配置文件,同步数据库 [root@node1 ~]# vim /e ...
- Openstack组件实现原理 — Glance架构(V1/V2)
目录 目录 Glance 安装列表 Glance Image service Image service 的组件 Glance-Api Glance-Registry Glance-db Image ...
- Openstack组件部署 — Overview和前期环境准备
目录 目录 前言 软件环境 Openstack 简介 Openstack 架构 Openstack Install Overview 创建Node虚拟机 环境准备 基础设置 Install OpenS ...
随机推荐
- Centos系统Python环境搭建和项目部署
目录 一.Python 1. 源安装 Python3 2. SCL安装 Python3 3. 虚拟环境venv 4. 安装Flask 5. 安装gunicorn 二.安装Nginx 1. 安装Ngin ...
- python的工具pip进行安装时出现 No module named 'pip'
现象: 解决: python -m ensurepip easy_install pip python -m pip install --upgrade pip #用于更新pip,默认安装的是pip9 ...
- DIV+CSS网页布局常用的一些基础知识整理
CSS命名规范 一.文件命名规范 全局样式:global.css: 框架布局:layout.css: 字体样式:font.css: 链接样式:link.css: 打印样式:print.css: 二.常 ...
- 【python爬虫】加密代理IP的使用与设置一套session请求头
1:代理ip请求,存于redis: # 请求ip代理连接,更新redis的代理ip def proxy_redis(): sr = redis.Redis(connection_pool=Pool) ...
- FZU 1575 小学生的游戏【模拟二分】
某天,无聊的小斌叫上几个同学玩游戏,其中有比较笨的小兴,比较傻的小雪,可爱的小霞和自以为是的小楠.他们去找聪明的小明去给他们当裁判.判定谁取得游戏胜利. 而这个游戏是由小斌想个1到10000000的数 ...
- delete records in table A not in table B
转)A.B两表,找出ID字段中,存在A表,但是不存在B表的数据.A表总共13w数据,去重后大约3W条数据,B表有2W条数据,且B表的ID字段有索引. 方法一 使用 not in ,容易理解,效率低 ...
- onethink二级导航调用
<ul class="nav-main">//添加tree参数 <think:nav name="nav" tree="true&q ...
- 【JZOJ4786】【NOIP2016提高A组模拟9.17】小a的强迫症
题目描述 输入 输出 样例输入 3 2 2 1 样例输出 3 数据范围 样例解释 解法 先假定每种颜色的珠子取一个按顺序排列. 设这n个珠子就是每一种颜色的珠子的最后一个. 考虑逐个把珠子放入. 对于 ...
- ELK学习之jdk和jre的区别
JRE: Java Runtime EnvironmentJDK:Java Development KitJRE顾名思义是java运行时环境,包含了java虚拟机,java基础类库.是使用java语言 ...
- oracle-Mount
执行nomount的所有工作,另外附加数据结构并与这些数据结构进行交互.这时,oracle从控制文件中获得信息. 可以执行的任务是: 执行数据库的完全恢复操作 重命名数据文件 改变数据库的归档状态. ...