找回密码
 注册
查看: 1718|回复: 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  --public9 v) ~7 P/ N0 E6 o
* N( H3 @! x) o" [% c: i' V" W
openstack image create "centos7.4" \, q8 O* a. c! b8 J, T
--file centos7.4-.qcow2 \6 k% |4 M1 I! p' h7 Z) V
--disk-format qcow2 --container-format bare \
2 y$ J3 L& q& h) V& J9 [- i --property hw_qemu_guest_agent=yes \! r7 y% [4 W* D
--public. A& a9 ?* ?5 H' p' Y3 V1 B& v6 y, F* U

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
( _% o4 j0 _1 B; G+ L- C5 `+------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+  V, z9 v4 q0 w3 B3 z
| Field            | Value                                                                                                                                                                                                                                                                                                                                                                                                                               |
0 [/ b/ X% {" _- b: o+------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+% Z- @3 [  S" m8 {3 v
| checksum         | e489e3ac004516835459af551b76d2c2                                                                                                                                                                                                                                                                                                                                                                                                    |
7 @9 V8 p7 V/ f2 Y| container_format | bare                                                                                                                                                                                                                                                                                                                                                                                                                                |
1 {1 Y% H+ ~, G/ [9 Z# M; d| created_at       | 2021-10-31T09:29:12Z                                                                                                                                                                                                                                                                                                                                                                                                                |
$ l7 @* e, p5 x$ V' Z( \) D6 K| disk_format      | raw                                                                                                                                                                                                                                                                                                                                                                                                                                 |5 f- O* `8 d3 L- y9 X" h- A
| file             | /v2/images/1a982e8b-af67-4358-a9df-a706e91edf2d/file                                                                                                                                                                                                                                                                                                                                                                                |8 p. s. Y5 y) l. F
| id               | 1a982e8b-af67-4358-a9df-a706e91edf2d                                                                                                                                                                                                                                                                                                                                                                                                |% r6 D3 s: ~7 D
| min_disk         | 0                                                                                                                                                                                                                                                                                                                                                                                                                                   |
5 v8 l" e  \% c  H| min_ram          | 0                                                                                                                                                                                                                                                                                                                                                                                                                                   |: X2 H, B, d* q; O
| name             | ubuntu-20-ssd-raw                                                                                                                                                                                                                                                                                                                                                                                                                   |( V$ o4 T6 F4 o  `3 w  O, K
| owner            | 165d201028964584b5d105cfef581c21                                                                                                                                                                                                                                                                                                                                                                                                    |$ I3 `6 [4 A9 |
| 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' |1 `* r' K% Z3 l1 U/ @9 S6 J8 B
| protected        | False                                                                                                                                                                                                                                                                                                                                                                                                                               |2 z: R1 p7 k+ O' o2 ]
| schema           | /v2/schemas/image                                                                                                                                                                                                                                                                                                                                                                                                                   |. ]! S/ I. v7 i# n
| size             | 4294967296                                                                                                                                                                                                                                                                                                                                                                                                                          |, z) e! ^. l/ S) S, p( y
| status           | active                                                                                                                                                                                                                                                                                                                                                                                                                              |
& C( z& a3 [. d+ [7 @4 _: x" H| tags             |                                                                                                                                                                                                                                                                                                                                                                                                                                     |
0 [. R# b5 Q( \. t* `* ?| updated_at       | 2021-10-31T09:30:47Z                                                                                                                                                                                                                                                                                                                                                                                                                |* v9 e4 D* l- X* E
| visibility       | public                                                                                                                                                                                                                                                                                                                                                                                                                              |9 h! F7 f# p7 U, O% W
+------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2021-10-31 17:53:33 | 显示全部楼层
也可以加入些别的参数:
& i6 F4 s6 s* `2 u- O--property hw_qemu_guest_agent=yes --property hw_ovirt_guest_agent=yes
( |9 k4 R7 B- g# O9 h

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
6 h6 G% A) u# `; h7 g, i

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 01:23 , Processed in 0.016956 second(s), 22 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

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