中文
注册

向Image服务上传镜像

用户参考本节操作步骤向Image服务上传镜像之前,需要提前准备好所需的虚拟机镜像。

  1. 导入环境变量。
    source ~/.admin-openrc
  2. 下载镜像。以下载华为开源镜像站上的openEuler-22.03-LTS-SP2虚拟机镜像为例。
    wget --no-check-certificate https://mirrors.huaweicloud.com/openeuler/openEuler-22.03-LTS-SP2/virtual_machine_img/aarch64/openEuler-22.03-LTS-SP2-aarch64.qcow2.xz
    xz -d openEuler-22.03-LTS-SP2-aarch64.qcow2.xz
  3. 查询记录镜像的虚拟磁盘大小。
    qemu-img info openEuler-22.03-LTS-SP2-aarch64.qcow2

    查询结果中的virtual size即为镜像的虚拟磁盘大小。

  4. 向Image服务上传镜像。
    openstack image create --disk-format qcow2 --container-format bare --file openEuler-22.03-LTS-SP2-aarch64.qcow2 --public $image_name

    将image_name替换为所创建镜像的名称,请根据实际情况填写。

搜索结果
找到“0”个结果

当前产品无相关内容

未找到相关内容,请尝试其他搜索词