Updates to User Guide / Havana testing

Updates also clouddocs-maven-plugin to 1.11.1

Change-Id: Id5b325d5ad7d33f0b5e1bb1a63d9b48178aa45f4
author: diane fleming
This commit is contained in:
Diane Fleming 2013-10-15 14:12:50 -05:00 committed by Andreas Jaeger
parent 2326e2d501
commit ee146d0112
11 changed files with 250 additions and 383 deletions

View File

@ -4,21 +4,28 @@
xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0"
xml:id="app_community_support">
<?dbhtml stop-chunking?>
<title>Community Support</title>
<title>Community support</title>
<para>There are many resources available that will help you
further with running and using OpenStack. Many OpenStack
community members can answer questions and help with bug
suspicions. We are constantly improving and adding to the main
features of OpenStack, but if you have any problems, do not
hesitate to ask. Use the following resources to get OpenStack
support and troubleshoot your existing installations.</para>
<para>To help you run and use OpenStack, many resources are
available. Many OpenStack community members can answer
questions and help with bug suspicions. We are constantly
improving and adding to the main features of OpenStack, but if
you have any problems, do not hesitate to ask. Use the
following resources to get OpenStack support and troubleshoot
your existing installations.</para>
<section xml:id="support-documentation">
<title>Documentation</title>
<para>For the available OpenStack documentation, see <link
xlink:href="http://docs.openstack.org"
>docs.openstack.org</link>.</para>
<para>To provide feedback on documentation, join and use the
<email>openstack-docs@lists.openstack.org</email>
mailing list at <link
xlink:href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-docs"
>OpenStack Documentation Mailing List</link>, or <link
xlink:href="https://bugs.launchpad.net/openstack-manuals/+filebug"
>report a bug</link>.</para>
<para>The following books explain how to install an OpenStack cloud
and its components:
@ -112,6 +119,41 @@
</para>
</listitem>
</itemizedlist>
<para>The following documentation provides reference and
guidance information for the OpenStack APIs:</para>
<itemizedlist><listitem><para><link xlink:href="http://api.openstack.org/api-ref.html">OpenStack API Reference</link></para></listitem>
<listitem>
<para><link
xlink:href="http://docs.openstack.org/api/openstack-block-storage/2.0/content/"
><citetitle>OpenStack Block Storage
Service API v2
Reference</citetitle></link></para>
</listitem>
<listitem>
<para><link
xlink:href="http://docs.openstack.org/api/openstack-compute/2/content/"
><citetitle>OpenStack Compute API v2 and Extensions Reference</citetitle></link></para>
</listitem>
<listitem>
<para><link
xlink:href="http://docs.openstack.org/api/openstack-identity-service/2.0/content/"
><citetitle>OpenStack Identity Service API v2.0 Reference</citetitle></link></para>
</listitem>
<listitem>
<para><link
xlink:href="http://docs.openstack.org/api/openstack-image-service/2.0/content/"
><citetitle>OpenStack Image Service API v2 Reference</citetitle></link></para>
</listitem>
<listitem>
<para><link
xlink:href="http://docs.openstack.org/api/openstack-network/2.0/content/"
><citetitle>OpenStack Networking API v2.0 Reference</citetitle></link></para>
</listitem>
<listitem>
<para><link
xlink:href="http://docs.openstack.org/api/openstack-object-storage/1.0/content/"
><citetitle>OpenStack Object Storage API v1 Reference</citetitle></link></para>
</listitem></itemizedlist>
</section>
<section xml:id="support-ask_openstack">
@ -148,7 +190,7 @@ and so on.</para>
>http://wiki.openstack.org/MailingLists</link>.</para>
</section>
<section xml:id="support-wiki">
<title>The OpenStack Wiki</title>
<title>The OpenStack wiki</title>
<para>The <link xlink:href="http://wiki.openstack.org/"
>OpenStack wiki</link> contains content on a broad
range of topics but some of it sits a bit below the
@ -242,10 +284,9 @@ xlink:href="https://bugs.launchpad.net/ceilometer"
<title>The OpenStack IRC channel</title>
<para>The OpenStack community lives and breathes in the
#openstack IRC channel on the Freenode network. You can
come by to hang out, ask questions, or get immediate
feedback for urgent and pressing issues. To get into the
IRC channel, you must install an IRC client or use a
browser-based client by going to <link
hang out, ask questions, or get immediate feedback for
urgent and pressing issues. To install an IRC client or
use a browser-based client, go to <link
xlink:href="http://webchat.freenode.net"
>http://webchat.freenode.net/</link>. You can also use
Colloquy (Mac OS X, <link
@ -266,17 +307,4 @@ xlink:href="https://bugs.launchpad.net/ceilometer"
xlink:href="https://wiki.openstack.org/wiki/IRC"
>https://wiki.openstack.org/wiki/IRC</link>.</para>
</section>
<section xml:id="support-documentation-feedback">
<title>Documentation feedback</title>
<para>To provide feedback on documentation, join and use the
<email>openstack-docs@lists.openstack.org</email>
mailing list at <link
xlink:href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-docs"
>OpenStack Documentation Mailing List</link>,
or <link
xlink:href="https://bugs.launchpad.net/openstack-manuals/+filebug"
>report a bug</link>.
</para>
</section>
</appendix>

0
doc/common/section_cinder_cli_manage_volumes.xml Normal file → Executable file
View File

View File

@ -34,10 +34,9 @@
<itemizedlist>
<listitem>
<para><emphasis role="bold">ceilometer</emphasis>
(<application>python-ceilometerclient</application>).
Client for Monitoring/Metering
API that lets you create and collect measurements
across all OpenStack components.</para>
(<application>python-ceilometerclient</application>).
Client for the Metering API that lets you create and
collect measurements across OpenStack.</para>
</listitem>
<listitem>
<para><emphasis role="bold">cinder</emphasis>

View File

@ -14,6 +14,6 @@
<screen><prompt>#</prompt> <userinput>source openrc</userinput></screen>
<para>Next you can try creating some stacks, using the samples.</para>
<xi:include href="../user-guide/section_heat_cli.xml"/>
<xi:include href="../user-guide/section_cli_heat.xml"/>
</section>

View File

@ -47,7 +47,7 @@
<plugin>
<groupId>com.rackspace.cloud.api</groupId>
<artifactId>clouddocs-maven-plugin</artifactId>
<version>1.11.0</version>
<version>1.11.1</version>
</plugin>
</plugins>
</build>

View File

@ -37,8 +37,8 @@
<?hard-pagebreak?>
<xi:include href="section_swift_cli_howto.xml"/>
<?hard-pagebreak?>
<xi:include href="section_heat_cli.xml"/>
<?hard-pagebreak?>
<xi:include href="section_cli_heat.xml"/>
<?hard-pagebreak?>
<xi:include href="section_ceilometer_cli.xml"/>
<?hard-pagebreak?>
<xi:include href="../common/section_cinder_cli_manage_volumes.xml"/>

View File

@ -5,17 +5,25 @@
xmlns:svg="http://www.w3.org/2000/svg"
xmlns:html="http://www.w3.org/1999/xhtml" version="5.0"
xml:id="ceilometer_cli_commands">
<title>Metering</title>
<para>Metering is the service that measures cloud resources within OpenStack. It collects information about what, who, when and how much regarding anything that can be billed. For Havana, metering is available to the user using only the CLI.</para>
<para>As an example, we create a heat autoscaling stack and see some of the ceilometer command outputs.</para>
<title>Measure cloud resources</title>
<para>The Metering service measures cloud resources within
OpenStack.</para>
<para>It collects information about how much, who, what, and when
with regards to billing. For Havana, metering is available
through only the <command>ceilometer</command> command-line interface
(CLI).</para>
<para>The following example uses the <command>heat</command> client to create an
auto-scaling stack and the <command>ceilometer</command> client to measure
resources.</para>
<procedure>
<step><para>Create a heat autoscaling stack, using the following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>heat stack-create -f cfn/F17/AutoScalingCeilometer.yaml -P "KeyName=heat_key"</userinput></screen>
</step>
<step><para>To see the list of heat resources created, run the following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>heat resource-list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>
+--------------------------+-----------------------------------------+-----------------+----------------------+
<step>
<para>Create an auto-scaling stack:</para>
<screen><prompt>$</prompt> <userinput>heat stack-create -f cfn/F17/AutoScalingCeilometer.yaml -P "KeyName=heat_key"</userinput></screen>
</step>
<step>
<para>List the heat resources that were created:</para>
<screen><prompt>$</prompt> <userinput>heat resource-list</userinput>
<computeroutput>+--------------------------+-----------------------------------------+-----------------+----------------------+
| resource_name | resource_type |resource_status | updated_time |
+--------------------------+-----------------------------------------+-----------------+----------------------+
| CfnUser | AWS::IAM::User |CREATE_COMPLETE | 2013-10-02T05:53:41Z |
@ -28,47 +36,45 @@
| CPUAlarmHigh | OS::Ceilometer::Alarm |CREATE_COMPLETE | 2013-10-02T05:56:02Z |
| CPUAlarmLow | OS::Ceilometer::Alarm |CREATE_COMPLETE | 2013-10-02T05:56:02Z |
+--------------------------+-----------------------------------------+-----------------+----------------------+</computeroutput></screen>
</step>
<step><para>To see the list of alarms set, run the following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>ceilometer alarm-list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>
+--------------------------------------+------------------------------+-------------------+---------+------------+-------------------------------+
</step>
<step>
<para>List the alarms that are set:</para>
<screen><prompt>$</prompt> <userinput>ceilometer alarm-list</userinput>
<computeroutput>+--------------------------------------+------------------------------+-------------------+---------+------------+-------------------------------+
| Alarm ID | Name | State | Enabled | Continuous | Alarm condition |
+--------------------------------------+------------------------------+-------------------+---------+------------+-------------------------------+
| 4f896b40-0859-460b-9c6a-b0d329814496 | as-CPUAlarmLow-i6qqgkf2fubs | insufficient data | True | False | cpu_util &lt; 15.0 during 1x 60s |
| 75d8ecf7-afc5-4bdc-95ff-19ed9ba22920 | as-CPUAlarmHigh-sf4muyfruy5m | insufficient data | True | False | cpu_util > 50.0 during 1x 60s |
+--------------------------------------+------------------------------+-------------------+---------+------------+-----------------------------+</computeroutput></screen>
</step>
<step><para>To see the list of meters set, run the following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>ceilometer meter-list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>
+--------------------------+------------+----------+-----------------------------------------------------------------------+------------------------------------+
| 75d8ecf7-afc5-4bdc-95ff-19ed9ba22920 | as-CPUAlarmHigh-sf4muyfruy5m | insufficient data | True | False | cpu_util &gt; 50.0 during 1x 60s |
+--------------------------------------+------------------------------+-------------------+---------+------------+-----------------------------+</computeroutput></screen>
</step>
<step>
<para>List the meters that are set:</para>
<screen><prompt>$</prompt> <userinput>ceilometer meter-list</userinput>
<computeroutput>+--------------------------+------------+----------+-----------------------------------------------------------------------+------------------------------------+
| Name | Type | Unit | Resource ID | User ID | Project ID |
+--------------------------+------------+----------+-----------------------------------------------------------------------+------------------------------------+
| cpu | cumulative | ns | 3965b41b-81b0-4386-bea5-6ec37c8841c1 | d1a2996d3b1f4e0e8645ba9650308011 | bf03bf32e3884d489004ac995ff7a61c |
| cpu | cumulative | ns | 62520a83-73c7-4084-be54-275fe770ef2c | d1a2996d3b1f4e0e8645ba9650308011 | bf03bf32e3884d489004ac995ff7a61c |
| cpu_util | gauge | % | 3965b41b-81b0-4386-bea5-6ec37c8841c1 | d1a2996d3b1f4e0e8645ba9650308011 | bf03bf32e3884d489004ac995ff7a61c |
+--------------------------+------------+----------+-----------------------------------------------------------------------+------------------------------------+</computeroutput></screen>
</step>
<step><para>To see the list of samples, run the following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>ceilometer sample-list -m cpu_util</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>
+--------------------------------------+----------+-------+---------------+------+---------------------+
</step>
<step>
<para>List samples:</para>
<screen><prompt>$</prompt> <userinput>ceilometer sample-list -m cpu_util</userinput>
<computeroutput>+--------------------------------------+----------+-------+---------------+------+---------------------+
| Resource ID | Name | Type | Volume | Unit | Timestamp |
+--------------------------------------+----------+-------+---------------+------+---------------------+
| 3965b41b-81b0-4386-bea5-6ec37c8841c1 | cpu_util | gauge | 3.98333333333 | % | 2013-10-02T10:50:12 |
+--------------------------------------+----------+-------+---------------+------+---------------------+</computeroutput></screen>
</step>
<step><para>To see the statistics, run the following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>ceilometer statistics -m cpu_util</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>
+--------+---------------------+---------------------+-------+---------------+---------------+---------------+---------------+----------+---------------------+---------------------+
</step>
<step>
<para>View statistics:</para>
<screen><prompt>$</prompt> <userinput>ceilometer statistics -m cpu_util</userinput>
<computeroutput>+--------+---------------------+---------------------+-------+---------------+---------------+---------------+---------------+----------+---------------------+---------------------+
| Period | Period Start | Period End | Count | Min | Max | Sum | Avg | Duration | Duration Start | Duration End |
+--------+---------------------+---------------------+-------+---------------+---------------+---------------+---------------+----------+---------------------+---------------------+
| 0 | 2013-10-02T10:50:12 | 2013-10-02T10:50:12 | 1 | 3.98333333333 | 3.98333333333 | 3.98333333333 | 3.98333333333 | 0.0 | 2013-10-02T10:50:12 | 2013-10-02T10:50:12 |
+--------+---------------------+---------------------+-------+---------------+---------------+---------------+---------------+----------+---------------------+---------------------+</computeroutput></screen>
</step>
</step>
</procedure>
</section>
</section>

View File

@ -1,186 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0"
xml:id="cli_manage_volumes">
<title>Manage volumes</title>
<para>A volume is a detachable block storage device, similar to a
USB hard drive. You can attach a volume to only one instance.
To create and manage volumes, you use a combination of nova
and cinder client commands.</para>
<para>This example creates a volume named
<literal>my-volume</literal> based on an image.</para>
<procedure>
<title>To list volumes</title>
<step>
<para>To determine which image to use for your volume,
list images:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>nova image-list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+--------------------------------------+---------------------------------+--------+--------------------------------------+
| ID | Name | Status | Server |
+--------------------------------------+---------------------------------+--------+--------------------------------------+
| 397e713c-b95b-4186-ad46-6126863ea0a9 | cirros-0.3.1-x86_64-uec | ACTIVE | |
| df430cc2-3406-4061-b635-a51c16e488ac | cirros-0.3.1-x86_64-uec-kernel | ACTIVE | |
| 3cf852bd-2332-48f4-9ae4-7d926d50945e | cirros-0.3.1-x86_64-uec-ramdisk | ACTIVE | |
| 7e5142af-1253-4634-bcc6-89482c5f2e8a | myCirrosImage | ACTIVE | 84c6e57d-a6b1-44b6-81eb-fcb36afd31b5 |
| 89bcd424-9d15-4723-95ec-61540e8a1979 | mysnapshot | ACTIVE | f51ebd07-c33d-4951-8722-1df6aa8afaa4 |
+--------------------------------------+---------------------------------+--------+--------------------------------------+</computeroutput></screen>
<para>Note the ID of the image that you want to
use.</para>
</step>
<step>
<para>To determine which availability zone are available
in which to create your volume, list the availability
zones:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>nova availability-zone-list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+-----------------------+----------------------------------------+
| Name | Status |
+-----------------------+----------------------------------------+
| internal | available |
| |- devstack-grizzly | |
| | |- nova-conductor | enabled :-) 2013-07-25T16:50:44.000000 |
| | |- nova-consoleauth | enabled :-) 2013-07-25T16:50:44.000000 |
| | |- nova-scheduler | enabled :-) 2013-07-25T16:50:44.000000 |
| | |- nova-cert | enabled :-) 2013-07-25T16:50:44.000000 |
| | |- nova-network | enabled :-) 2013-07-25T16:50:44.000000 |
| nova | available |
| |- devstack-grizzly | |
| | |- nova-compute | enabled :-) 2013-07-25T16:50:39.000000 |
+-----------------------+----------------------------------------+</computeroutput></screen>
<para>Note the name of an available availability zone that
you want to use.</para>
</step>
<step>
<para>Create a volume with 8 GBs of space in the desired
availability zone and based on the desired image, as
follows:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>cinder create 8 --display-name my-new-volume --image-id 397e713c-b95b-4186-ad46-6126863ea0a9 --availability-zone nova</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+---------------------+--------------------------------------+
| Property | Value |
+---------------------+--------------------------------------+
| attachments | [] |
| availability_zone | nova |
| bootable | false |
| created_at | 2013-07-25T17:02:12.472269 |
| display_description | None |
| display_name | my-new-volume |
| id | 573e024d-5235-49ce-8332-be1576d323f8 |
| image_id | 397e713c-b95b-4186-ad46-6126863ea0a9 |
| metadata | {} |
| size | 8 |
| snapshot_id | None |
| source_volid | None |
| status | creating |
| volume_type | None |
+---------------------+--------------------------------------+</computeroutput></screen>
</step>
<step>
<para>To verify that your volume was created successfully,
list the available volumes:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>cinder list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| ID | Status | Display Name | Size | Volume Type | Bootable | Attached to |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| 573e024d-5235-49ce-8332-be1576d323f8 | available | my-new-volume | 8 | None | true | |
| bd7cf584-45de-44e3-bf7f-f7b50bf235e3 | available | my-bootable-vol | 8 | None | true | |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+</computeroutput></screen>
<para>If your volume was created successfully, its status
is <literal>available</literal>. If its status is
<literal>error</literal>, you might have tried to
create a volume outside of your quota.</para>
</step>
<step>
<para>Attach your volume to a server:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>nova volume-attach 84c6e57d-a6b1-44b6-81eb-fcb36afd31b5 573e024d-5235-49ce-8332-be1576d323f8 /dev/vdb</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+----------+--------------------------------------+
| Property | Value |
+----------+--------------------------------------+
| device | /dev/vdb |
| serverId | 84c6e57d-a6b1-44b6-81eb-fcb36afd31b5 |
| id | 573e024d-5235-49ce-8332-be1576d323f8 |
| volumeId | 573e024d-5235-49ce-8332-be1576d323f8 |
+----------+--------------------------------------+</computeroutput></screen>
<para>Note the ID of your volume.<note>
<para>If you see any I/O errors when attaching a volume, it is possible that the backend driver needs to be
configured for a custom block size, or that you are running an older version of libvirt. (Version 0.10.2+
is required for backends, such as SolidFire, that set a custom block size). Block Storage supports custom
block sizes on KVM and QEMU.</para>
</note></para>
</step>
<step>
<para>Show information for your volume:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>cinder show 573e024d-5235-49ce-8332-be1576d323f8</userinput></screen>
<screen><computeroutput><?db-font-size 65%?><?db-fontsize 75%?>+------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Property | Value |
+------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| attachments | [{u'device': u'/dev/vdb', u'server_id': u'84c6e57d-a6b1-44b6-81eb-fcb36afd31b5', u'id': u'573e024d-5235-49ce-8332-be1576d323f8', u'volume_id': u'573e024d-5235-49ce-8332-be1576d323f8'}] |
| availability_zone | nova |
| bootable | true |
| created_at | 2013-07-25T17:02:12.000000 |
| display_description | None |
| display_name | my-new-volume |
| id | 573e024d-5235-49ce-8332-be1576d323f8 |
| metadata | {} |
| os-vol-host-attr:host | devstack-grizzly |
| os-vol-tenant-attr:tenant_id | 66265572db174a7aa66eba661f58eb9e |
| size | 8 |
| snapshot_id | None |
| source_volid | None |
| status | in-use |
| volume_image_metadata | {u'kernel_id': u'df430cc2-3406-4061-b635-a51c16e488ac', u'image_id': u'397e713c-b95b-4186-ad46-6126863ea0a9', u'ramdisk_id': u'3cf852bd-2332-48f4-9ae4-7d926d50945e', u'image_name': u'cirros-0.3.1-x86_64-uec'} |
| volume_type | None |
+------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+</computeroutput></screen>
<para>From the output, you can see that the volume is
attached to the server with ID
<literal>84c6e57d-a6b1-44b6-81eb-fcb36afd31b5</literal>,
is in the nova availability zone, and is
bootable.</para>
</step>
<step>
<para>To delete your volume, you must first detach it from
the server.</para>
<para>To detach the volume from your server, pass the
server ID and volume ID to the command, as
follows:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>nova volume-detach 84c6e57d-a6b1-44b6-81eb-fcb36afd31b5 573e024d-5235-49ce-8332-be1576d323f8</userinput></screen>
<para>The <command>volume-detach</command> command does
not return any output.</para>
</step>
<step>
<para>List volumes:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>cinder list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| ID | Status | Display Name | Size | Volume Type | Bootable | Attached to |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| 573e024d-5235-49ce-8332-be1576d323f8 | available | my-new-volume | 8 | None | true | |
| bd7cf584-45de-44e3-bf7f-f7b50bf235e3 | available | my-bootable-vol | 8 | None | true | |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+</computeroutput></screen>
<para>Note that the volume is now available.</para>
</step>
<step>
<para>Now you can delete the volume, as follows:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>cinder delete my-new-volume</userinput></screen>
<para>The delete command does not return any
output.</para>
</step>
<step>
<para>List the volumes again, and note that the status of
your volume is <literal>deleting</literal>:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>cinder list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| ID | Status | Display Name | Size | Volume Type | Bootable | Attached to |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| 573e024d-5235-49ce-8332-be1576d323f8 | deleting | my-new-volume | 8 | None | true | |
| bd7cf584-45de-44e3-bf7f-f7b50bf235e3 | available | my-bootable-vol | 8 | None | true | |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+</computeroutput></screen>
<para>When the volume is fully deleted, it disappears from
the list of volumes:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>cinder list</userinput></screen>
<screen><computeroutput><?db-font-size 65%?>+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| ID | Status | Display Name | Size | Volume Type | Bootable | Attached to |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+
| bd7cf584-45de-44e3-bf7f-f7b50bf235e3 | available | my-bootable-vol | 8 | None | true | |
+--------------------------------------+-----------+-----------------+------+-------------+----------+-------------+</computeroutput></screen>
</step>
</procedure>
</section>

View File

@ -0,0 +1,126 @@
<?xml version="1.0" encoding="UTF-8"?>
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns:html="http://www.w3.org/1999/xhtml" version="5.0"
xml:id="heat-stack-create">
<?dbhtml stop-chunking?>
<title>Create and manage stacks</title>
<section xml:id="create_stack">
<title>Create a stack from an example template file</title>
<procedure>
<step>
<para>To create a stack, or template, from an <link
xlink:href="https://github.com/openstack/heat-templates"
>example template file</link>, run the following
command:</para>
<screen><prompt>$</prompt> <userinput>heat stack-create mystack --template-file=/<replaceable>PATH_TO_HEAT_TEMPLATES</replaceable>/WordPress_Single_Instance.template</userinput>
<userinput>--parameters="InstanceType=m1.large;DBUsername=<replaceable>USERNAME</replaceable>;DBPassword=<replaceable>PASSWORD</replaceable>;KeyName=<replaceable>HEAT_KEY</replaceable>;LinuxDistribution=F17"</userinput></screen>
<para>The <literal>--parameters</literal> values that
you specify depend on the parameters that are defined
in the template. If a website hosts the template file, you can specify the URL with the
<literal>--template-url</literal> parameter
instead of the <literal>--template-file</literal>
parameter.</para>
<para>The command returns the following output:</para>
<screen><computeroutput>+--------------------------------------+---------------+--------------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+---------------+--------------------+----------------------+
| 4c712026-dcd5-4664-90b8-0915494c1332 | mystack | CREATE_IN_PROGRESS | 2013-04-03T23:22:08Z |
+--------------------------------------+---------------+--------------------+----------------------+</computeroutput></screen>
</step>
<step>
<para>You can also use the
<command>stack-create</command> command to
validate a template file without creating a stack
from it.</para>
<para>To do so, run the following command:</para>
<screen><prompt>$</prompt> <userinput>heat stack-create mystack --template-file=/<replaceable>PATH_TO_HEAT_TEMPLATES</replaceable>/WordPress_Single_Instance.template</userinput></screen>
<para>If validation fails, the response returns an
error message.</para>
</step>
</procedure>
</section>
<section xml:id="stack_info">
<title>Get information about stacks</title>
<para>To explore the state and history of a particular stack,
you can run a number of commands.</para>
<itemizedlist>
<listitem>
<para>To see which stacks are visible to the current
user, run the following command:</para>
<screen><prompt>$</prompt> <userinput>heat stack-list</userinput>
<computeroutput>+--------------------------------------+---------------+-----------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+---------------+-----------------+----------------------+
| 4c712026-dcd5-4664-90b8-0915494c1332 | mystack | CREATE_COMPLETE | 2013-04-03T23:22:08Z |
| 7edc7480-bda5-4e1c-9d5d-f567d3b6a050 | my-otherstack | CREATE_FAILED | 2013-04-03T23:28:20Z |
+--------------------------------------+---------------+-----------------+----------------------+</computeroutput></screen>
</listitem>
<listitem>
<para>To show the details of a stack, run the
following command:</para>
<screen><prompt>$</prompt> <userinput>heat stack-show mystack</userinput></screen>
</listitem>
<listitem>
<para>A stack consists of a collection of
resources.</para>
<para>To list the resources and their status, run the
following command:</para>
<screen><prompt>$</prompt> <userinput>heat resource-list mystack</userinput>
<computeroutput>+---------------------+--------------------+-----------------+----------------------+
| logical_resource_id | resource_type | resource_status | updated_time |
+---------------------+--------------------+-----------------+----------------------+
| WikiDatabase | AWS::EC2::Instance | CREATE_COMPLETE | 2013-04-03T23:25:56Z |
+---------------------+--------------------+-----------------+----------------------+</computeroutput></screen>
</listitem>
<listitem>
<para>To show the details for the specified resource
in a stack, run the following command:</para>
<screen><prompt>$</prompt> <userinput>heat resource-show mystack WikiDatabase</userinput></screen>
<para>Some resources have associated metadata which
can change throughout the life-cycle of a
resource:</para>
<screen><prompt>$</prompt> <userinput>heat resource-metadata mystack WikiDatabase</userinput></screen>
</listitem>
<listitem>
<para>A series of events is generated during the
life-cycle of a stack.</para>
<para>To display life-cycle events, run::</para>
<screen><prompt>$</prompt> <userinput>heat event-list mystack</userinput>
<computeroutput>+---------------------+----+------------------------+-----------------+----------------------+
| logical_resource_id | id | resource_status_reason | resource_status | event_time |
+---------------------+----+------------------------+-----------------+----------------------+
| WikiDatabase | 1 | state changed | IN_PROGRESS | 2013-04-03T23:22:09Z |
| WikiDatabase | 2 | state changed | CREATE_COMPLETE | 2013-04-03T23:25:56Z |
+---------------------+----+------------------------+-----------------+----------------------+</computeroutput></screen>
</listitem>
<listitem>
<para>To show the details for a particular event, run
the following command:</para>
<screen><prompt>$</prompt> <userinput>heat event-show WikiDatabase 1</userinput></screen>
</listitem>
</itemizedlist>
</section>
<section xml:id="update_stack">
<title>Update a stack</title>
<procedure xml:id="heat-stack-update">
<step>
<para>To update an existing stack from a modified
template file, run a command like the following
command:</para>
<screen><prompt>$</prompt> <userinput>heat stack-update mystack --template-file=/path/to/heat/templates/WordPress_Single_Instance_v2.template</userinput>
<userinput>--parameters="InstanceType=m1.large;DBUsername=wp;DBPassword=verybadpassword;KeyName=heat_key;LinuxDistribution=F17"</userinput>
<computeroutput>+--------------------------------------+---------------+-----------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+---------------+-----------------+----------------------+
| 4c712026-dcd5-4664-90b8-0915494c1332 | mystack | UPDATE_COMPLETE | 2013-04-03T23:22:08Z |
| 7edc7480-bda5-4e1c-9d5d-f567d3b6a050 | my-otherstack | CREATE_FAILED | 2013-04-03T23:28:20Z |
+--------------------------------------+---------------+-----------------+----------------------+</computeroutput></screen>
<para>Some resources are updated in-place, while
others are replaced with new resources.</para>
</step>
</procedure>
</section>
</section>

View File

@ -1,108 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns:html="http://www.w3.org/1999/xhtml" version="5.0"
xml:id="heat-stack-create">
<title>Create and manage stacks</title>
<section xml:id="create_stacks_proc"> <title>Create a stack from an example template file</title>
<procedure>
<step>
<para>To create a stack, or template, from an <link
xlink:href="https://github.com/openstack/heat-templates">example template
file</link>, run following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>heat stack-create mystack --template-file=/path/to/heat/templates/WordPress_Single_Instance.template \
--parameters="InstanceType=m1.large;DBUsername=wp;DBPassword=verybadpassword;KeyName=heat_key;LinuxDistribution=F17"</userinput></screen>
<para>The <literal>--parameters</literal> values that you specify
depend on which parameters are defined in the
template. If the template file is hosted on a website,
you can specify the URL with
<literal>--template-url</literal> parameter
instead of the <literal>--template-file</literal>
parameter.</para>
<para>The command returns the following output:</para>
<screen><computeroutput><?db-font-size 65%?>+--------------------------------------+---------------+--------------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+---------------+--------------------+----------------------+
| 4c712026-dcd5-4664-90b8-0915494c1332 | mystack | CREATE_IN_PROGRESS | 2013-04-03T23:22:08Z |
+--------------------------------------+---------------+--------------------+----------------------+</computeroutput></screen>
</step>
<step>
<para>You can also use the <command>stack-create</command>
command to validate a template file without creating a
stack from it.</para>
<para>To do so, run the following command:</para>
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>heat stack-create mystack --template-file=/path/to/heat/templates/WordPress_Single_Instance.template</userinput></screen>
<para>If validation fails, the response returns an error
message.</para>
</step>
</procedure>
</section>
<section xml:id="stack_get_info"><title>Get information about stacks</title>
<para>To explore the state and history of a particular stack, you can
run a number of commands.</para>
<procedure>
<step>
<para>To see which stacks are visible to the current user,
run the following command:
<screen><prompt>$</prompt> <userinput><?db-font-size 75%?>heat stack-list</userinput></screen><screen><computeroutput><?db-font-size 65%?>+--------------------------------------+---------------+-----------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+---------------+-----------------+----------------------+
| 4c712026-dcd5-4664-90b8-0915494c1332 | mystack | CREATE_COMPLETE | 2013-04-03T23:22:08Z |
| 7edc7480-bda5-4e1c-9d5d-f567d3b6a050 | my-otherstack | CREATE_FAILED | 2013-04-03T23:28:20Z |
+--------------------------------------+---------------+-----------------+----------------------+</computeroutput></screen></para>
</step>
<step>
<para>To show the details of a stack, run the following
command:</para>
<screen><prompt>$</prompt> <userinput>heat stack-show mystack</userinput></screen></step>
<step><para>A stack consists of a collection of resources. To list the
resources and their status, run the following
command:</para>
<screen><prompt>$</prompt> <userinput>heat resource-list mystack</userinput></screen>
<screen><?db-font-size 65%?><computeroutput>+---------------------+--------------------+-----------------+----------------------+
| logical_resource_id | resource_type | resource_status | updated_time |
+---------------------+--------------------+-----------------+----------------------+
| WikiDatabase | AWS::EC2::Instance | CREATE_COMPLETE | 2013-04-03T23:25:56Z |
+---------------------+--------------------+-----------------+----------------------+</computeroutput></screen>
</step>
<step>
<para>To show the details for the specified resource in a
stack, run the following command:</para>
<screen><prompt>$</prompt> <userinput>heat resource-show mystack WikiDatabase</userinput></screen>
<para>Some resources have associated metadata which can
change throughout the life-cycle of a resource:</para>
<screen><prompt>$</prompt> <userinput>heat resource-metadata mystack WikiDatabase</userinput></screen></step>
<step><para>A series of events is generated during the life-cycle of a
stack. This command displays those events:</para>
<screen><prompt>$</prompt> <userinput>heat event-list mystack</userinput></screen><screen><computeroutput><?db-font-size 65%?>+---------------------+----+------------------------+-----------------+----------------------+
| logical_resource_id | id | resource_status_reason | resource_status | event_time |
+---------------------+----+------------------------+-----------------+----------------------+
| WikiDatabase | 1 | state changed | IN_PROGRESS | 2013-04-03T23:22:09Z |
| WikiDatabase | 2 | state changed | CREATE_COMPLETE | 2013-04-03T23:25:56Z |
+---------------------+----+------------------------+-----------------+----------------------+</computeroutput></screen>
</step><step><para>To show the details for a particular event, run the following
command:</para>
<screen><prompt>$</prompt> <userinput>heat event-show WikiDatabase 1</userinput></screen>
</step>
</procedure>
</section>
<section xml:id="heat-stack-update"><title>Update stacks</title>
<procedure>
<step>
<para>To update an existing stack from a modified template
file, run the following command:</para><screen><prompt>$</prompt> <userinput>heat stack-update mystack --template-file=/path/to/heat/templates/WordPress_Single_Instance_v2.template
--parameters="InstanceType=m1.large;DBUsername=wp;DBPassword=verybadpassword;KeyName=heat_key;LinuxDistribution=F17"</userinput></screen><screen><?db-font-size 65%?><computeroutput>+--------------------------------------+---------------+-----------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+---------------+-----------------+----------------------+
| 4c712026-dcd5-4664-90b8-0915494c1332 | mystack | UPDATE_COMPLETE | 2013-04-03T23:22:08Z |
| 7edc7480-bda5-4e1c-9d5d-f567d3b6a050 | my-otherstack | CREATE_FAILED | 2013-04-03T23:28:20Z |
+--------------------------------------+---------------+-----------------+----------------------+</computeroutput></screen>
<para>Some resources are updated in-place, while others
are replaced with new resources.</para>
</step>
</procedure>
</section>
</section>

View File

@ -6,33 +6,35 @@
version="5.0"
xml:id="managing-openstack-object-storage-with-swift-cli">
<title>Manage object storage</title>
<para>The OpenStack Object Storage service provides the swift
command-line interface (CLI) that enables you to gather
statistics, list items, update metadata, upload, download, and
delete files. This client is based on the native swift client
library, <literal>client.py</literal>, which seamlessly
re-authenticates if the current token expires during
processing, retries operations multiple times, and provides a
processing concurrency of 10.</para>
<para>The Object Storage service provides the
<command>swift</command> command-line interface (CLI) that
enables you to gather statistics, list items, update metadata,
upload, download, and delete files. This client is based on
the native swift client library, <literal>client.py</literal>,
which seamlessly re-authenticates if the current token expires
during processing, retries operations multiple times, and
provides a processing concurrency of 10.</para>
<para>Users have roles on accounts. For example, the admin
role enables full access to all containers and objects in an
account.</para>
<para>You can set access control lists (ACLs) are set at the container level
<para>You can set access control lists (ACLs) at the container level
and support lists for read and write access, which are set
with the <literal>X-Container-Read</literal> and
<literal>X-Container-Write</literal> header
respectively.</para>
<para>You can use the swift client to set the ACLs by using the
<command>post</command> subcommand with the <parameter>-r</parameter> parameter for the read access and
<parameter>-w</parameter> option for the write access. The following example enables the testuser user
to read objects in the container:</para>
<para>You can use the <command>swift</command> client to set
the ACLs by using the <command>post</command> subcommand with
the <parameter>-r</parameter> parameter for the read access
and <parameter>-w</parameter> parameter for the write access.
The following example enables the <literal>testuser</literal>
user to read objects in the container:</para>
<screen><prompt>$</prompt> <userinput>swift post -r 'testuser'</userinput></screen>
<para>You can also use this command with a list of users.</para>
<para>If you use the StaticWeb middleware to enable
OpenStack Object Storage to serve public web content,
be aware of the ACL syntax for
managing allowed referrers. The syntax is <literal>.r:</literal>
followed by a list of allowed referrers. For example,
the following command gives object access to all referring domains access:</para>
<para>If you use the StaticWeb middleware to enable Object
Storage to serve public web content, the syntax for allowed
referrers is <literal>.r:</literal> followed by a list of
allowed referrers.</para>
<para>The following command gives object access to all referring
domains:</para>
<screen><prompt>$</prompt> <userinput>swift post -r '.r:*'</userinput></screen>
</section>