Modify glance content for Kilo
Modify glance content for Kilo as follows: 1) Change python-keystoneclient with python-openstackclient. 2) Adjust CLI input and output for API version 2. 3) Add value to log_file option. 4) Remove version from value of auth_uri option. Change-Id: Ia0f88473b4600580c34c8a4b1664b86435c7bf06 Implements: blueprint installguide-kilo
This commit is contained in:
parent
337c0ab79f
commit
6e3f0c8edb
@ -55,65 +55,76 @@
|
||||
<substeps>
|
||||
<step>
|
||||
<para>Create the <literal>glance</literal> user:</para>
|
||||
<screen><prompt>$</prompt> <userinput>keystone user-create --name glance --pass <replaceable>GLANCE_PASS</replaceable></userinput>
|
||||
<computeroutput>+----------+----------------------------------+
|
||||
| Property | Value |
|
||||
<screen><prompt>$</prompt> <userinput>openstack user create --password-prompt glance</userinput>
|
||||
<computeroutput>User Password:
|
||||
Repeat User Password:
|
||||
+----------+----------------------------------+
|
||||
| email | |
|
||||
| enabled | True |
|
||||
| id | f89cca5865dc42b18e2421fa5f5cce66 |
|
||||
| name | glance |
|
||||
| username | glance |
|
||||
| Field | Value |
|
||||
+----------+----------------------------------+
|
||||
| email | None |
|
||||
| enabled | True |
|
||||
| id | 1dc206e084334db2bee88363745da014 |
|
||||
| name | glance |
|
||||
| username | glance |
|
||||
+----------+----------------------------------+</computeroutput></screen>
|
||||
<para>Replace <replaceable>GLANCE_PASS</replaceable> with a suitable
|
||||
password.</para>
|
||||
</step>
|
||||
<step>
|
||||
<para>Add the <literal>admin</literal> role to the
|
||||
<literal>glance</literal> user:</para>
|
||||
<screen><prompt>$</prompt> <userinput>keystone user-role-add --user glance --tenant service --role admin</userinput></screen>
|
||||
<note>
|
||||
<para>This command provides no output.</para>
|
||||
</note>
|
||||
<literal>glance</literal> user and <literal>service</literal>
|
||||
project:</para>
|
||||
<screen><prompt>$</prompt> <userinput>openstack role add --project service --user glance admin</userinput>
|
||||
<computeroutput>+-------+----------------------------------+
|
||||
| Field | Value |
|
||||
+-------+----------------------------------+
|
||||
| id | 1169d778631b4fd1aefd9d35314e1c56 |
|
||||
| name | admin |
|
||||
+-------+----------------------------------+</computeroutput></screen>
|
||||
</step>
|
||||
<step>
|
||||
<para>Create the <literal>glance</literal> service entity:</para>
|
||||
<screen><prompt>$</prompt> <userinput>keystone service-create --name glance --type image \
|
||||
--description "OpenStack Image Service"</userinput>
|
||||
<screen><prompt>$</prompt> <userinput>openstack service create --type image \
|
||||
--description "OpenStack Image Service" glance</userinput>
|
||||
<computeroutput>+-------------+----------------------------------+
|
||||
| Property | Value |
|
||||
| Field | Value |
|
||||
+-------------+----------------------------------+
|
||||
| description | OpenStack Image Service |
|
||||
| enabled | True |
|
||||
| id | 23f409c4e79f4c9e9d23d809c50fbacf |
|
||||
| name | glance |
|
||||
| type | image |
|
||||
| description | OpenStack Image Service |
|
||||
| enabled | True |
|
||||
| id | 178124d6081c441b80d79972614149c6 |
|
||||
| name | glance |
|
||||
| type | image |
|
||||
+-------------+----------------------------------+</computeroutput></screen>
|
||||
</step>
|
||||
</substeps>
|
||||
</step>
|
||||
<step>
|
||||
<para>Create the Image Service API endpoints:</para>
|
||||
<screen><prompt>$</prompt> <userinput>keystone endpoint-create \
|
||||
--service-id $(keystone service-list | awk '/ image / {print $2}') \
|
||||
<screen><prompt>$</prompt> <userinput>openstack endpoint create \
|
||||
--publicurl http://<replaceable>controller</replaceable>:9292 \
|
||||
--internalurl http://<replaceable>controller</replaceable>:9292 \
|
||||
--adminurl http://<replaceable>controller</replaceable>:9292 \
|
||||
--region regionOne</userinput>
|
||||
<computeroutput>+-------------+----------------------------------+
|
||||
| Property | Value |
|
||||
+-------------+----------------------------------+
|
||||
| adminurl | http://controller:9292 |
|
||||
| id | a2ee818c69cb475199a1ca108332eb35 |
|
||||
| internalurl | http://controller:9292 |
|
||||
| publicurl | http://controller:9292 |
|
||||
| region | regionOne |
|
||||
| service_id | 23f409c4e79f4c9e9d23d809c50fbacf |
|
||||
+-------------+----------------------------------+</computeroutput></screen>
|
||||
--region regionOne \
|
||||
image</userinput>
|
||||
<computeroutput>+--------------+----------------------------------+
|
||||
| Field | Value |
|
||||
+--------------+----------------------------------+
|
||||
| adminurl | http://controller:9292 |
|
||||
| id | 805b1dbc90ab47479111102bc6423313 |
|
||||
| internalurl | http://controller:9292 |
|
||||
| publicurl | http://controller:9292 |
|
||||
| region | regionOne |
|
||||
| service_id | 178124d6081c441b80d79972614149c6 |
|
||||
| service_name | glance |
|
||||
| service_type | image |
|
||||
+--------------+----------------------------------+</computeroutput></screen>
|
||||
</step>
|
||||
</procedure>
|
||||
<procedure os="ubuntu;rhel;centos;fedora;sles;opensuse">
|
||||
<title>To install and configure the Image Service components</title>
|
||||
<note>
|
||||
<para>Default configuration files vary by distribution. You might need
|
||||
to add these sections and options rather than modifying existing
|
||||
sections and options.</para>
|
||||
</note>
|
||||
<step>
|
||||
<para>Install the packages:</para>
|
||||
<screen os="ubuntu"><prompt>#</prompt> <userinput>apt-get install glance python-glanceclient</userinput></screen>
|
||||
@ -139,7 +150,7 @@ connection = mysql://glance:<replaceable>GLANCE_DBPASS</replaceable>@<replaceabl
|
||||
service access:</para>
|
||||
<programlisting language="ini">[keystone_authtoken]
|
||||
...
|
||||
auth_uri = http://<replaceable>controller</replaceable>:5000/v2.0
|
||||
auth_uri = http://<replaceable>controller</replaceable>:5000
|
||||
identity_uri = http://<replaceable>controller</replaceable>:35357
|
||||
admin_tenant_name = service
|
||||
admin_user = glance
|
||||
@ -177,6 +188,13 @@ notification_driver = noop</programlisting>
|
||||
<para>The Telemetry chapter provides an Image Service configuration
|
||||
that enables notifications.</para>
|
||||
</step>
|
||||
<step>
|
||||
<para>In the <literal>[DEFAULT]</literal> section, configure the
|
||||
log file:</para>
|
||||
<programlisting language="ini">[DEFAULT]
|
||||
...
|
||||
log_file = /var/log/glance/api.log</programlisting>
|
||||
</step>
|
||||
<step>
|
||||
<para>(Optional) To assist with troubleshooting,
|
||||
enable verbose logging in the <literal>[DEFAULT]</literal>
|
||||
@ -206,7 +224,7 @@ connection = mysql://glance:<replaceable>GLANCE_DBPASS</replaceable>@<replaceabl
|
||||
service access:</para>
|
||||
<programlisting language="ini">[keystone_authtoken]
|
||||
...
|
||||
auth_uri = http://<replaceable>controller</replaceable>:5000/v2.0
|
||||
auth_uri = http://<replaceable>controller</replaceable>:5000
|
||||
identity_uri = http://<replaceable>controller</replaceable>:35357
|
||||
admin_tenant_name = service
|
||||
admin_user = glance
|
||||
@ -236,7 +254,14 @@ notification_driver = noop</programlisting>
|
||||
<para>The Telemetry chapter provides an Image Service configuration
|
||||
that enables notifications.</para>
|
||||
</step>
|
||||
<step>
|
||||
<step>
|
||||
<para>In the <literal>[DEFAULT]</literal> section, configure the
|
||||
log file:</para>
|
||||
<programlisting language="ini">[DEFAULT]
|
||||
...
|
||||
log_file = /var/log/glance/registry.log</programlisting>
|
||||
</step>
|
||||
<step>
|
||||
<para>(Optional) To assist with troubleshooting,
|
||||
enable verbose logging in the <literal>[DEFAULT]</literal>
|
||||
section:</para>
|
||||
|
@ -5,8 +5,7 @@
|
||||
version="5.0"
|
||||
xml:id="glance-verify">
|
||||
<title>Verify operation</title>
|
||||
<para>This section describes how to verify operation of the Image
|
||||
Service using
|
||||
<para>Verify operation of the Image Service using
|
||||
<link xlink:href="http://launchpad.net/cirros">CirrOS</link>, a small
|
||||
Linux image that helps you test your OpenStack deployment.</para>
|
||||
<para>For more information about how to download and build images,
|
||||
@ -18,74 +17,75 @@
|
||||
xlink:href="http://docs.openstack.org/user-guide/content/index.html"
|
||||
><citetitle>OpenStack User Guide</citetitle></link>.</para>
|
||||
<procedure>
|
||||
<step>
|
||||
<para>Create and change into a temporary local directory:</para>
|
||||
<screen><prompt>$</prompt> <userinput>mkdir /tmp/images</userinput></screen>
|
||||
</step>
|
||||
<step>
|
||||
<para>Download the image to the temporary local directory:</para>
|
||||
<screen><prompt>$</prompt> <userinput>wget -P /tmp/images http://cdn.download.cirros-cloud.net/0.3.3/cirros-0.3.3-x86_64-disk.img</userinput></screen>
|
||||
</step>
|
||||
<step>
|
||||
<para>Source the <literal>admin</literal> credentials to gain access to
|
||||
admin-only CLI commands:</para>
|
||||
<screen><prompt>$</prompt> <userinput>source admin-openrc.sh</userinput></screen>
|
||||
</step>
|
||||
<step>
|
||||
<para>Upload the image to the Image Service:</para>
|
||||
<para>Create a temporary local directory:</para>
|
||||
<screen><prompt>$</prompt> <userinput>mkdir /tmp/images</userinput></screen>
|
||||
</step>
|
||||
<step>
|
||||
<para>Download the source image into it:</para>
|
||||
<screen><prompt>$</prompt> <userinput>wget -P /tmp/images http://cdn.download.cirros-cloud.net/0.3.3/cirros-0.3.3-x86_64-disk.img</userinput></screen>
|
||||
</step>
|
||||
<step>
|
||||
<para>Upload the image to the Image Service using the
|
||||
<glossterm baseform="QEMU Copy On Write 2 (QCOW2)">QCOW2</glossterm>
|
||||
disk format, <glossterm>bare</glossterm> container format, and
|
||||
public visibility so all projects can access it:</para>
|
||||
<screen><prompt>$</prompt> <userinput>glance image-create --name "cirros-0.3.3-x86_64" --file /tmp/images/cirros-0.3.3-x86_64-disk.img \
|
||||
--disk-format qcow2 --container-format bare --is-public True --progress</userinput>
|
||||
--disk-format qcow2 --container-format bare --visibility public --progress</userinput>
|
||||
<computeroutput>[=============================>] 100%
|
||||
+------------------+--------------------------------------+
|
||||
| Property | Value |
|
||||
+------------------+--------------------------------------+
|
||||
| checksum | 133eae9fb1c98f45894a4e60d8736619 |
|
||||
| container_format | bare |
|
||||
| created_at | 2014-10-10T13:14:42 |
|
||||
| deleted | False |
|
||||
| deleted_at | None |
|
||||
| created_at | 2015-03-26T16:52:10Z |
|
||||
| disk_format | qcow2 |
|
||||
| id | acafc7c0-40aa-4026-9673-b879898e1fc2 |
|
||||
| is_public | True |
|
||||
| id | 38047887-61a7-41ea-9b49-27987d5e8bb9 |
|
||||
| min_disk | 0 |
|
||||
| min_ram | 0 |
|
||||
| name | cirros-0.3.3-x86_64 |
|
||||
| owner | ea8c352d253443118041c9c8b8416040 |
|
||||
| owner | ae7a98326b9c455588edd2656d723b9d |
|
||||
| protected | False |
|
||||
| size | 13200896 |
|
||||
| status | active |
|
||||
| updated_at | 2014-10-10T13:14:43 |
|
||||
| tags | [] |
|
||||
| updated_at | 2015-03-26T16:52:10Z |
|
||||
| virtual_size | None |
|
||||
| visibility | public |
|
||||
+------------------+--------------------------------------+</computeroutput></screen>
|
||||
<para>For information about the parameters for the
|
||||
<command>glance image-create</command> command, see <link
|
||||
xlink:href="http://docs.openstack.org/cli-reference/content/glanceclient_commands.html#glanceclient_subcommand_image-create"
|
||||
>Image Service command-line client</link> in the
|
||||
<citetitle>OpenStack Command-Line Interface
|
||||
Reference</citetitle>.</para>
|
||||
<para>For information about the <command>glance image-create</command>
|
||||
parameters, see <link
|
||||
xlink:href="http://docs.openstack.org/cli-reference/content/glanceclient_commands.html#glanceclient_subcommand_image-create"
|
||||
>Image Service command-line client</link> in the
|
||||
<citetitle>OpenStack Command-Line Interface
|
||||
Reference</citetitle>.</para>
|
||||
<para>For information about disk and container formats for
|
||||
images, see <link
|
||||
xlink:href="http://docs.openstack.org/image-guide/content/image-formats.html"
|
||||
>Disk and container formats for images</link> in the
|
||||
xlink:href="http://docs.openstack.org/image-guide/content/image-formats.html"
|
||||
>Disk and container formats for images</link> in the
|
||||
<citetitle>OpenStack Virtual Machine Image Guide</citetitle>.</para>
|
||||
<note>
|
||||
<para>Because the returned image ID is generated dynamically,
|
||||
your deployment generates a different ID than the one shown
|
||||
in this example.</para>
|
||||
<para>OpenStack generates IDs dynamically, so you will see
|
||||
different values in the example command output.</para>
|
||||
</note>
|
||||
</step>
|
||||
<step>
|
||||
<para>Confirm upload of the image and validate
|
||||
attributes:</para>
|
||||
<screen><prompt>$</prompt> <userinput>glance image-list</userinput>
|
||||
<computeroutput>+--------------------------------------+---------------------+-------------+------------------+----------+--------+
|
||||
| ID | Name | Disk Format | Container Format | Size | Status |
|
||||
+--------------------------------------+---------------------+-------------+------------------+----------+--------+
|
||||
| acafc7c0-40aa-4026-9673-b879898e1fc2 | cirros-0.3.3-x86_64 | qcow2 | bare | 13200896 | active |
|
||||
+--------------------------------------+---------------------+-------------+------------------+----------+--------+</computeroutput></screen>
|
||||
<computeroutput>+--------------------------------------+---------------------+
|
||||
| ID | Name |
|
||||
+--------------------------------------+---------------------+
|
||||
| 38047887-61a7-41ea-9b49-27987d5e8bb9 | cirros-0.3.3-x86_64 |
|
||||
+--------------------------------------+---------------------+</computeroutput></screen>
|
||||
</step>
|
||||
<step>
|
||||
<para>Remove the temporary local directory:</para>
|
||||
<para>Remove the temporary local directory and source image:</para>
|
||||
<screen><prompt>$</prompt> <userinput>rm -r /tmp/images</userinput></screen>
|
||||
</step>
|
||||
</procedure>
|
||||
|
Loading…
Reference in New Issue
Block a user