Ask Your Question
0

how to properly pass image argument to glance

asked 2015-06-02 11:46:08 -0500

kevin-michael-lloyd gravatar image

updated 2015-08-18 12:13:53 -0500

smaffulli gravatar image

I'm following this documentation: http://docs.openstack.org/kilo/instal...

I'm running:

glance image-create --name "cirros-0.3.4-x86_64" --file /tmp/images/cirros-0.3.4-x86_64-disk.img \ --disk-format qcow2 --container-format bare --visibility public --progress

I get this error:

glance: error: unrecognized arguments: --name --disk-format qcow2 --container-format bare --visibility public

Glance version: 0.15.0

Is the documentation wrong or is my glance client out of date? I've been following every step without skipping, and all my configs are identical minus hostnames and IPs.

What is the correct string that would match the requirements here? I ran glance --help and I wasn't seeing any of those flags available. My glance client is current according to the http://ubuntu-cloud.archive.canonical.com trusty-updates/kilo/main repo.

edit retag flag offensive close merge delete

Comments

Hi, did you find a resolution? I am having exact issues, but using glance version 0.17.0 with centos

Rajan433 gravatar imageRajan433 ( 2015-08-18 11:20:13 -0500 )edit

3 answers

Sort by ยป oldest newest most voted
1

answered 2015-08-18 11:55:46 -0500

Rajan433 gravatar image

updated 2015-08-18 12:16:07 -0500

smaffulli gravatar image

I have found a resolution. It appears glance is not parsing " correctly. Just remove quotation from the image name and it should be good to go.

[Tue Aug 18 12:45:16 root@controller:~ ] # glance image-create --name cirros-0.3.4-x86_64 --file /tmp/images/cirros-0.3.4-x86_64-disk.img --disk-format qcow2 --container-format bare --visibility public --progress [=============================>] 100% +------------------+--------------------------------------+ | Property | Value | +------------------+--------------------------------------+ | checksum | ee1eca47dc88f4879d8a229cc70a07c6 | | container_format | bare | | created_at | 2015-08-18T16:45:40Z | | disk_format | qcow2 | | id | 7e08d6ef-2f91-4fcc-a367-23b9c3ff8433 | | min_disk | 0 | | min_ram | 0 | | name | cirros-0.3.4-x86_64 | | owner | 1a47d9d15c7640d09901da74700ddbd0 | | protected | False | | size | 13287936 | | status | active | | tags | [] | | updated_at | 2015-08-18T16:45:41Z | | virtual_size | None | | visibility | public | +------------------+--------------------------------------+
edit flag offensive delete link more

Comments

this may be a bug in the documentation. Thanks for sharing the solution.

smaffulli gravatar imagesmaffulli ( 2015-08-18 12:21:16 -0500 )edit

I removed the quotes, but it is not working for me. Getting the same error! (Version: Kilo-[10-Jan-2016])

Veerendra gravatar imageVeerendra ( 2016-01-13 06:57:47 -0500 )edit
0

answered 2016-03-11 04:47:19 -0500

aggholamyy gravatar image

Such a strange problem I think there is a uniq solution for each on of us.

By the way, I solved this problem by removing /etc/glance/glance-registry.conf , /etc/glance/glance-api.conf and finding source of these two file from http://docs.openstack.org/kilo/config-reference/content/section_glance-registry.conf.html (link text) and http://docs.openstack.org/kilo/config-reference/content/section_glance-registry.conf.html (link text).

copy both of them and create glance-registry.conf , glance-api.conf in the "/etc/glance/" directory and after that properly edit them. I think this problem caused by mistake(s) in process of editing them. Note : I do it on openstack Kiol.

edit flag offensive delete link more
0

answered 2015-08-04 08:03:23 -0500

crash gravatar image

Try add following exports to your environment script:

export OS_IMAGE_API_VERSION=2

export OS_VOLUME_API_VERSION=2

Looks like your issue caused by using incorrect API version. I had similar issue, it was caused by API version. Hope it will help you.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

2 followers

Stats

Asked: 2015-06-02 11:46:08 -0500

Seen: 1,661 times

Last updated: Mar 11 '16