glance image-create --copy-from command returns an error

Bug #1700169 reported by Gary Richards
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
Undecided
junboli

Bug Description

- [x] This doc is inaccurate in this way:
I have been following the install guide for ocata on RedHat/CentOS without issue up until running the command provided to create the manila-service-image. It fails with the following error:

[root@controller ~]# glance image-create \
> --copy-from http://tarballs.openstack.org/manila-image-elements/images/manila-service-image-master.qcow2 \
> --name "manila-service-image" \
> --disk-format qcow2 \
> --container-format bare \
> --visibility public --progress
usage: glance [--version] [-d] [-v] [--get-schema] [--no-ssl-compression] [-f]
              [--os-image-url OS_IMAGE_URL]
              [--os-image-api-version OS_IMAGE_API_VERSION]
              [--profile HMAC_KEY] [--key-file OS_KEY] [--ca-file OS_CACERT]
              [--cert-file OS_CERT] [--os-region-name OS_REGION_NAME]
              [--os-auth-token OS_AUTH_TOKEN]
              [--os-service-type OS_SERVICE_TYPE]
              [--os-endpoint-type OS_ENDPOINT_TYPE] [--insecure]
              [--os-cacert <ca-certificate>] [--os-cert <certificate>]
              [--os-key <key>] [--timeout <seconds>] [--os-auth-type <name>]
              [--os-auth-url OS_AUTH_URL] [--os-domain-id OS_DOMAIN_ID]
              [--os-domain-name OS_DOMAIN_NAME]
              [--os-project-id OS_PROJECT_ID]
              [--os-project-name OS_PROJECT_NAME]
              [--os-project-domain-id OS_PROJECT_DOMAIN_ID]
              [--os-project-domain-name OS_PROJECT_DOMAIN_NAME]
              [--os-trust-id OS_TRUST_ID]
              [--os-default-domain-id OS_DEFAULT_DOMAIN_ID]
              [--os-default-domain-name OS_DEFAULT_DOMAIN_NAME]
              [--os-user-id OS_USER_ID] [--os-username OS_USERNAME]
              [--os-user-domain-id OS_USER_DOMAIN_ID]
              [--os-user-domain-name OS_USER_DOMAIN_NAME]
              [--os-password OS_PASSWORD]
              <subcommand> ...
glance: error: unrecognized arguments: --copy-from http://tarballs.openstack.org/manila-image-elements/images/manila-service-image-master.qcow2

- [ ] This is a doc addition request.

- [x] I have a fix to the document that I can paste below including example: input and output.
I tested two alternatives to the above command, both appear to work:

$ glance --os-image-api-version 1 image-create --copy-from http://tarballs.openstack.org/manila-image-elements/images/manila-service-image-master.qcow2 --name "manila-service-image2" --disk-format qcow2 --container-format bare --progress
(ie. the addition of --os-image-api-version 1, but the removal of --visibility public)

$ curl https://tarballs.openstack.org/manila-image-elements/images/manila-service-image-master.qcow2 | glance image-create --name "manila-service-image" --disk-format qcow2 --container-format bare --visibility public --progress
(ie. removing --copy-from and the url, using curl and the url then piping the output to the remaining glance command)

-----------------------------------
Release: 0.1 on 2017-06-09 04:53
SHA: 529f638c241a058993940fc9a797d9a063b29ee1
Source: http://git.openstack.org/cgit/openstack/manila/tree/install-guide/source/post-install.rst
URL: https://docs.openstack.org/project-install-guide/shared-file-systems/ocata/post-install.html

junboli (junboli)
Changed in manila:
assignee: nobody → junboli (junboli)
Tom Barron (tpb)
tags: added: doc
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila (master)

Fix proposed to branch: master
Review: https://review.openstack.org/582828

Changed in manila:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (master)

Reviewed: https://review.openstack.org/582828
Committed: https://git.openstack.org/cgit/openstack/manila/commit/?id=cfc5edf0ee875b24f8a07eaf17f34246d0c878ab
Submitter: Zuul
Branch: master

commit cfc5edf0ee875b24f8a07eaf17f34246d0c878ab
Author: lijunbo <email address hidden>
Date: Mon Jul 16 12:16:00 2018 +0800

    Docs: glance image-create returns an error issue

    glance image-create --copy-from command returns an error
    --copy-from is not allowed in glance default v2 version.

    Change-Id: Ied78435ae927c8c1b6b92740aca7596950a244ff
    Closes-bug: #1700169

Changed in manila:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila 7.0.0.0rc1

This issue was fixed in the openstack/manila 7.0.0.0rc1 release candidate.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.