OpenStack Pike Minimal安装:三、镜像管理

1.创建服务凭据

#先使用脚本登陆admin
[[email protected] ~]# . admin-openstack.sh

①创建glance user

openstack user create --domain default --password-prompt glance

②关联

openstack role add --project service --user glance admin

③创建glance service

openstack service create --name glance --description "OpenStack Image" image

④创建服务API

openstack endpoint create --region RegionOne image public http://controller:9292
openstack endpoint create --region RegionOne image internal http://controller:9292
openstack endpoint create --region RegionOne image admin http://controller:9292

2.在controller节点上安装glance

[[email protected] ~]#  yum install openstack-glance -y

3.配置glance-api.conf

[[email protected] ~]# vim /etc/glance/glance-api.conf
[database]
connection = mysql+pymysql://glance:[email protected]/glance

[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = glance
password = glance

[paste_deploy]
flavor = keystone

[glance_store]
stores = file,http
default_store = file
filesystem_store_datadir = /var/lib/glance/images/

4.配置glance-registry.conf

[[email protected] ~]# vim /etc/glance/glance-registry.conf
[database]
connection = mysql+pymysql://glance:[email protected]/glance

[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = glance
password = glance

[paste_deploy]
flavor = keystone

5.填充数据库

[[email protected] ~]# su -s /bin/sh -c "glance-manage db_sync" glance
[[email protected] ~]# mysql -h controller -uglance -pglance -e "use glance;show tables;"

6.启动服务

[[email protected] ~]# systemctl enable openstack-glance-api.service openstack-glance-registry.service
[[email protected] ~]# systemctl start openstack-glance-api.service openstack-glance-registry.service

7.上传镜像验证

①下载测试镜像

[[email protected] ~]# wget http://download.cirros-cloud.net/0.3.5/cirros-0.3.5-x86_64-disk.img

②上传镜像到glance

openstack image create "cirros" --file cirros-0.3.5-x86_64-disk.img --disk-format qcow2 --container-format bare --public

③查看镜像列表

原文地址:http://blog.51cto.com/lullaby/2170256

时间: 2024-11-09 00:45:37

OpenStack Pike Minimal安装:三、镜像管理的相关文章

OpenStack Pike Minimal安装:六、管理界面

Ⅰ.配置dashboard 1.在controller上安装dashboard [[email protected] ~]# yum install openstack-dashboard -y 2.配置 ①修改local_settings文件 [[email protected] ~]# vim /etc/openstack-dashboard/local_settings OPENSTACK_HOST = "controller" OPENSTACK_KEYSTONE_URL =

OpenStack Pike Minimal安装:一、环境准备

1.关闭防火墙和selinux 2.配置hosts [[email protected] ~]# cat /etc/hosts 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 20.0.20.21 controller 20.0.20.22 compu

OpenStack Pike Minimal安装:二、身份认证

1.在controller节点上安装keystone [email protected] ~]# yum install openstack-keystone httpd mod_wsgi -y 2.配置 [[email protected] ~]# vim /etc/keystone/keystone.conf [database] connection = mysql+pymysql://keystone:[email protected]/keystone [token] provider

OpenStack Pike Minimal安装:四、计算服务

Ⅰ.在controller节点上配置nova 1.创建nova服务凭据 #先使用脚本登陆admin [[email protected] ~]# . admin-openstack.sh ①创建nova user openstack user create --domain default --password-prompt nova ②关联 openstack role add --project service --user nova admin ③创建nova service openst

OpenStack pike版 安装openstack服务(4) 续安装openstack服务(3)    

Compute service overview 计算服务概述 OpenStack用于对主机的计算和管理云计算系统.OpenStack的计算是一个基础设施即服务(IaaS)系统的一个重要组成部分.主要模块是用python实现的. OpenStack计算与OpenStack身份验证交互用来完成认证:OpenStack镜像服务用于磁盘和服务器镜像:用户和管理接口为OpenStack Dashboard.镜像访问受到项目和用户的限制,每个项目的配额是有限的(例如,实例的数量).OpenStack计算可

OpenStack pike版 安装openstack服务(3) 续基本环境部署(2)

安装openstack服务 所有openstack服务的安装指南链接:https://docs.openstack.org/pike/install/ 最小化部署,需要按照下面指定的顺序安装以下服务: Identity service – keystone installation for Pike Image service – glance installation for Pike Compute service – nova installation for Pike Networkin

Docker安装与镜像管理(一)

一.安装docker yum install epel-resase yum install docker-io  (RHEL6) yum install docker (RHEL7) 系统: [[email protected] ~]# uname -a Linux kvm.huangming.org 2.6.32-573.el6.x86_64 #1 SMP Thu Jul 23 15:44:03 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux [[email 

Docker安装及镜像管理

1.docker简介 容器虚拟化,比传统虚拟化轻量 2013年出现,发展非常迅猛 Redhat在6.5版本开始支持docker 使用GO语言开发,基于apache2.0协议 开源软件,项目代码在github维护 2.容器虚拟化和传统虚拟化比较 3.Docker的优势 启动非常快,秒级实现 资源利用率很高,一台机器可以跑上千个docker容器 更快的交付和部署,一次创建和配置后,可以在任意 地方运行 内核级别的虚拟化,不需要额外的hypevisor支持,会有更高的性能和效率 易迁移,平台依赖性不强

Docker的安装及镜像管理

1. 安装Docker Docker开源的容器引擎,可以让开发者打包应用以及依赖的库,然后发布到任何流行的linux发行版上,移植很方便: 由go语言编写,基于apache2.0协议发布: 基于linux kernel,要想在win下运行需要借助一个vm(虚拟机)来实现: 自2013年开始,近些年发展迅猛: docker从1.13x开始,版本分为社区版ce和企业版ee,并且基于年月的时间线形式: 优点: 启动非常快,秒级实现 资源利用率高,一台高配置服务器可以跑上千个docker容器 更快的交付