找回密码
 注册
查看: 1719|回复: 4

openstack上传镜像命令image create

[复制链接]

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
发表于 2021-10-31 17:08:51 | 显示全部楼层 |阅读模式
openstack image create ubuntu-20-hdd-raw --file /usr/src/ubuntu-20-x86_64.raw --disk-format raw --container-format bare  --public
2 y7 j* ^# A; Z
# q7 b6 s' Y6 J* {5 yopenstack image create "centos7.4" \
6 l( x$ S( {- k* ~3 U7 F3 I/ _1 d8 U --file centos7.4-.qcow2 \; v* @% P' Y- d3 ]
--disk-format qcow2 --container-format bare \! _/ {) i' w. n
--property hw_qemu_guest_agent=yes \4 H# j7 T; q; K) Q$ l
--public
9 L/ E7 {5 O3 x& d+ A3 _

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2021-10-31 17:33:05 | 显示全部楼层
openstack image create ubuntu-20-ssd-raw --file /usr/src/ubuntu-20-x86_64.raw --disk-format raw --container-format bare  --public
7 r" g; W6 ~, t2 g% f: A+------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
! {- Z* ]% ]+ r& l$ R7 ~  z  Q| Field            | Value                                                                                                                                                                                                                                                                                                                                                                                                                               |
: C4 x+ a" p  z2 Q+------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+  H2 G/ t3 v- [7 U
| checksum         | e489e3ac004516835459af551b76d2c2                                                                                                                                                                                                                                                                                                                                                                                                    |
! @( f8 ~8 x3 O! j# Q9 S1 v  H| container_format | bare                                                                                                                                                                                                                                                                                                                                                                                                                                |) ^' J) p$ {  @, {% {
| created_at       | 2021-10-31T09:29:12Z                                                                                                                                                                                                                                                                                                                                                                                                                |
0 b/ }: a# S/ ^/ H% C| disk_format      | raw                                                                                                                                                                                                                                                                                                                                                                                                                                 |, G- q) k( s! n! x, p- Z, p
| file             | /v2/images/1a982e8b-af67-4358-a9df-a706e91edf2d/file                                                                                                                                                                                                                                                                                                                                                                                |
1 W; }$ z5 M( p( R$ O7 e( n$ Y| id               | 1a982e8b-af67-4358-a9df-a706e91edf2d                                                                                                                                                                                                                                                                                                                                                                                                |
) I* j- J, C5 U. g| min_disk         | 0                                                                                                                                                                                                                                                                                                                                                                                                                                   |% @' {1 C6 r  |. [4 Q3 Q3 _% u
| min_ram          | 0                                                                                                                                                                                                                                                                                                                                                                                                                                   |3 z( k  ^% C2 v. y5 x) \
| name             | ubuntu-20-ssd-raw                                                                                                                                                                                                                                                                                                                                                                                                                   |/ n! i1 `1 [" b8 q6 n  a+ n
| owner            | 165d201028964584b5d105cfef581c21                                                                                                                                                                                                                                                                                                                                                                                                    |3 a# J) n# U3 S; P2 |. V; u
| properties       | locations='[{u'url': u'rbd://8daade9f-1db5-4e9e-a0ac-cbe1b3abafd1/images/1a982e8b-af67-4358-a9df-a706e91edf2d/snap', u'metadata': {}}]', owner_specified.openstack.md5='e489e3ac004516835459af551b76d2c2', owner_specified.openstack.object='images/ubuntu-20-ssd-raw', owner_specified.openstack.sha256='9fd9d9afd387f154de4066066139b5823fb99a18afb9ddd816c1225d2895f907', self='/v2/images/1a982e8b-af67-4358-a9df-a706e91edf2d' |2 K5 c+ |9 Y3 |4 B! J
| protected        | False                                                                                                                                                                                                                                                                                                                                                                                                                               |/ y4 L- z# ?* Y/ L' |
| schema           | /v2/schemas/image                                                                                                                                                                                                                                                                                                                                                                                                                   |: Z$ F4 _3 d7 p
| size             | 4294967296                                                                                                                                                                                                                                                                                                                                                                                                                          |) x: t$ a& T3 o3 c. z1 ~/ V9 d. R
| status           | active                                                                                                                                                                                                                                                                                                                                                                                                                              |: r  D7 r4 Z' W$ T! c' m5 Z
| tags             |                                                                                                                                                                                                                                                                                                                                                                                                                                     |
: s; p# V7 A8 D* y8 T2 r7 J: \3 _% O| updated_at       | 2021-10-31T09:30:47Z                                                                                                                                                                                                                                                                                                                                                                                                                |
* V! @0 v, y. Y4 V( C5 M, o| visibility       | public                                                                                                                                                                                                                                                                                                                                                                                                                              |& D: |- i- z/ L! n$ e: ]
+------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2021-10-31 17:53:33 | 显示全部楼层
也可以加入些别的参数:
3 J& [: R4 Z0 i--property hw_qemu_guest_agent=yes --property hw_ovirt_guest_agent=yes
) w$ A; x! n/ A# [! {

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2021-11-3 13:06:34 | 显示全部楼层
$ glance image-create --name mySignedImage --container-format bare --disk-format qcow2 --property img_signature="$image_signature" --property img_signature_certificate_uuid="$cert_uuid" --property img_signature_hash_method='SHA-256' --property img_signature_key_type='RSA-PSS' < myimage
* h/ m7 h7 N, p7 M/ `; _/ d

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2021-11-3 13:46:18 | 显示全部楼层
openstack image create  "CentOS-7.9_x86_64-1" --file /usr/src/CentOS7.9-x86.raw --disk-format raw --container-format bare --property hw_qemu_guest_agent=yes --property hw_ovirt_guest_agent=yes --property cinder_img_volume_type=volumes --public
您需要登录后才可以回帖 登录 | 注册

本版积分规则

返回首页|Archiver|手机版|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )

GMT+8, 2026-6-12 02:20 , Processed in 0.013642 second(s), 23 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

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