Fixed issues with identity and image

* Removes an unused TENANT=... line
* Added a missing \ in a keystone command
* Moved glance database sync to before restarting service
* Added some semantic markup

Change-Id: Ice95034c99d9cd4f3951a16d03db166e0bd26f21
This commit is contained in:
Lorin Hochstein
2012-05-15 10:05:28 -04:00
parent 58c1513531
commit eb3af6a872
2 changed files with 34 additions and 40 deletions

View File

@@ -8,14 +8,12 @@
to the other servers you intend to use for OpenStack
services, as root:</para>
<screen><prompt>#</prompt> <userinput>apt-get install keystone</userinput></screen>
<para>After installing, you need to delete the sqlite database it
creates, then change the configuration to point to a MySQL
database. This configuration enables easier scaling scenarios
since you can bring up multiple Keystone front ends when needed,
and configure them all to point back to the same database. Plus a
database backend has built-in data replication features and
documentation surrounding high availability and data redundancy
configurations. </para>
<para>After installing, you need to delete the sqlite database it creates, then change the
configuration to point to a MySQL database. This configuration enables easier scaling scenarios
since you can bring up multiple Keystone front ends when needed, and configure them all to point
back to the same database. Plus a database backend has built-in data replication features and
documentation surrounding high availability and data redundancy configurations.
doc/src/docbkx/openstack-install/identity-install-keystone.xml</para>
<para>Delete the <filename>keystone.db</filename> file created in
the <filename>/var/lib/keystone</filename>
directory.<screen><prompt>#</prompt> <userinput>rm /var/lib/keystone/keystone.db</userinput></screen></para>
@@ -439,7 +437,6 @@ service-create \
| type | volume |
+-------------+----------------------------------+
</computeroutput>
<prompt>$</prompt> <userinput>TENANT=eb7e0c10a99446cfa14c244374549e9d</userinput>
<prompt>$</prompt> <userinput>keystone --token 012345SECRET99TOKEN012345 \
--endpoint http://192.168.206.130:35357/v2.0/ \
endpoint-create \
@@ -483,7 +480,7 @@ service-create \
+-------------+----------------------------------+
</computeroutput>
<prompt>$</prompt> <userinput>keystone --token 012345SECRET99TOKEN012345 \
--endpoint http://192.168.206.130:35357/v2.0/
--endpoint http://192.168.206.130:35357/v2.0/ \
endpoint-create \
--region RegionOne \
--service_id=7d5258c490144c8c92505267785327c1 \

View File

@@ -8,33 +8,32 @@
version="5.0">
<title>Installing and Configuring the Image Service</title>
<para>Install the Image service.</para>
<screen>sudo apt-get install glance</screen>
<para>After installing,
you need to delete the sqlite database it creates, then change
the configuration to point to the mysql database. </para>
<para>Delete the <filename>glance.sqlite</filename> file created in the /var/lib/glance/
directory.</para>
<screen>sudo rm /var/lib/glance/glance.sqlite</screen>
<para>Install the Image service, as root:</para>
<screen><prompt>#</prompt> <userinput>apt-get install glance</userinput></screen>
<para>After installing, you need to delete the sqlite database it creates, then change the
configuration to point to the MySQL database. </para>
<para>Delete the <filename>glance.sqlite</filename> file created in the
<filename>/var/lib/glance/</filename> directory.</para>
<screen><prompt>#</prompt> <userinput>rm /var/lib/glance/glance.sqlite</userinput></screen>
<section xml:id="configure-glance-mysql"><title>Configuring the Image Service database backend</title>
<para>Configure the backend data store. For MySQL, create a glance MySQL database and a glance MySQL user. Grant the "glance" user full
access to the glance MySQL database.</para><para>Start the MySQL command line client by running:</para>
<para><literallayout class="monospaced">mysql -u root -p</literallayout></para><para>Enter the mysql root user's password when prompted.</para>
<para>To configure the MySQL database, create the glance database. </para><para><literallayout class="monospaced">mysql> CREATE DATABASE glance;</literallayout>
<para><screen><prompt>$</prompt> <userinput>mysql -u root -p</userinput></screen></para><para>Enter the MySQL root user's password when prompted.</para>
<para>To configure the MySQL database, create the glance database. </para><para><screen><prompt>mysql></prompt> <userinput>CREATE DATABASE glance;</userinput></screen>
</para><para>Create a MySQL user for the newly-created glance database that has full control of the database. </para>
<para><literallayout class="monospaced">mysql> GRANT ALL ON glance.* TO 'glance'@'%' IDENTIFIED BY 'yourpassword';</literallayout></para>
<para>Enter quit at the mysql> prompt to exit MySQL.</para><para><literallayout class="monospaced">mysql> quit</literallayout></para></section>
<para><screen><prompt>mysql></prompt> <userinput>GRANT ALL ON glance.* TO 'glance'@'%' IDENTIFIED BY 'yourpassword';</userinput></screen></para>
<para>Enter <literal>quit </literal>at the <literal>mysql></literal> prompt to exit
MySQL.</para><para><literallayout class="monospaced">mysql> quit</literallayout></para></section>
<section xml:id="configure-glance-files"><title>Edit the Glance configuration files and paste ini middleware files</title>
<para> Update
<filename>/etc/glance/glance-api-paste.ini</filename>
and configure the admin_* values under
[filter:authtoken].</para>
<para> Update <filename>/etc/glance/glance-api-paste.ini</filename> and configure the
<literal>admin_<replaceable>*</replaceable></literal> values under
<literal>[filter:authtoken]</literal>.</para>
<screen>[filter:authtoken]
admin_tenant_name = service
admin_user = glance
admin_password = glance</screen>
<para>Ensure that the glance-api pipeline section includes
authtoken:</para>
<literal>authtoken</literal>:</para>
<screen>[pipeline:glance-api]
pipeline = versionnegotiation authtoken auth-context apiv1app</screen>
<para>Add this to the end of <filename>/etc/glance/glance-api.conf</filename>.</para>
@@ -65,18 +64,16 @@ pipeline = authtoken auth-context context registryapp</screen>
<filename>/etc/glance/glance-scrubber.conf</filename>
files point to the MySQL database rather than
sqlite.<programlisting>sql_connection = mysql://glance:yourpassword@192.168.206.130/glance</programlisting></para>
<para>Restart glance-registry and glance-api services.</para>
<screen>sudo service glance-registry restart
sudo service glance-api restart</screen>
<para>On Ubuntu 12.04, the database tables are under version control and you must do these
steps on a new install to prevent the Image service from breaking possible upgrades, as
root:
<screen><prompt>#</prompt> <userinput>glance-manage version_control 0</userinput>
<prompt>#</prompt> <userinput>glance-manage db_sync</userinput></screen></para>
<note><para>Any time you change the .conf files, restart the
corresponding service.</para></note>
<para>On Ubuntu 12.04, the database tables are under version
control and you must do these steps on a new install to
prevent the Image service from breaking possible upgrades.
<screen>glance-manage version_control 0
glance-manage db_sync</screen></para>
<note><para>Also note that this guide does not configure image
caching, refer to <link
xlink:href="http://glance.openstack.org"
>http://glance.openstack.org</link> for more
information.</para></note></section></section>
<para>Restart glance-registry and glance-api services, as root:</para>
<screen><prompt>#</prompt> <userinput>service glance-registry restart</userinput>
<prompt>#</prompt> <userinput>service glance-api restart</userinput></screen>
<note><para>This guide does not configure image caching, refer to <link
xlink:href="http://glance.openstack.org">http://glance.openstack.org</link> for
more information.</para></note></section></section>