| Dean Troyer | 0986a7b | 2014-10-29 22:08:13 -0500 | [diff] [blame] | 1 | === | 
 | 2 | FAQ | 
 | 3 | === | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 4 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 5 | .. contents:: | 
 | 6 |    :local: | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 7 |  | 
 | 8 | General Questions | 
| Sean Dague | 3293046 | 2014-11-18 06:51:16 -0500 | [diff] [blame] | 9 | ================= | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 10 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 11 | Can I use DevStack for production? | 
 | 12 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 13 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 14 | DevStack is targeted at developers and CI systems to use the raw | 
 | 15 | upstream code.  It makes many choices that are not appropriate for | 
 | 16 | production systems. | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 17 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 18 | Your best choice is probably to choose a `distribution of OpenStack | 
| Isao Yamagata | 7aaaf90 | 2015-07-11 16:07:22 +0000 | [diff] [blame] | 19 | <https://www.openstack.org/marketplace/distros/>`__. | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 20 |  | 
| Sylvain Bauza | b75a492 | 2015-10-16 15:57:50 +0200 | [diff] [blame] | 21 | Can I use DevStack as a development environment? | 
 | 22 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 23 |  | 
 | 24 | Sure, you can. That said, there are a couple of things you should note before | 
 | 25 | doing so: | 
 | 26 |  | 
 | 27 | - DevStack makes a lot of configuration changes to your system and should not | 
 | 28 |   be run in your main development environment. | 
 | 29 |  | 
 | 30 | - All the repositories that DevStack clones when deploying are considered | 
 | 31 |   volatile by default and thus are subject to hard resets. This is necessary to | 
 | 32 |   keep you in sync with the latest upstream, which is what you want in a CI | 
 | 33 |   situation, but it can result in branches being overwritten and files being | 
 | 34 |   removed. | 
 | 35 |  | 
 | 36 |   The corollary of this is that if you are working on a specific project, using | 
 | 37 |   the DevStack project repository (defaulted to ``/opt/stack/<project>``) as | 
 | 38 |   the single master repository for storing all your work is not recommended. | 
 | 39 |   This behavior can be overridden by setting the ``RECLONE`` config option to | 
 | 40 |   ``no``.  Alternatively, you can avoid running ``stack.sh`` to redeploy by | 
 | 41 |   restarting services manually. In any case, you should generally ensure work | 
 | 42 |   in progress is pushed to Gerrit or otherwise backed up before running | 
 | 43 |   ``stack.sh``. | 
 | 44 |  | 
 | 45 | - If you use DevStack within a VM, you may wish to mount a local OpenStack | 
 | 46 |   directory, such as ``~/src/openstack``, inside the VM and configure DevStack | 
 | 47 |   to use this as the clone location using the ``{PROJECT}_REPO`` config | 
 | 48 |   variables. For example, assuming you're using Vagrant and sharing your home | 
 | 49 |   directory, you should place the following in ``local.conf``: | 
 | 50 |  | 
 | 51 |   .. code-block:: shell | 
 | 52 |  | 
 | 53 |      NEUTRON_REPO=/home/vagrant/src/neutron | 
 | 54 |      NOVA_REPO=/home/vagrant/src/nova | 
 | 55 |      KEYSTONE_REPO=/home/vagrant/src/keystone | 
 | 56 |      GLANCE_REPO=/home/vagrant/src/glance | 
 | 57 |      SWIFT_REPO=/home/vagrant/src/swift | 
 | 58 |      HORIZON_REPO=/home/vagrant/src/horizon | 
 | 59 |      CINDER_REPO=/home/vagrant/src/cinder | 
 | 60 |      HEAT_REPO=/home/vagrant/src/heat | 
 | 61 |      TEMPEST_REPO=/home/vagrant/src/tempest | 
 | 62 |      HEATCLIENT_REPO=/home/vagrant/src/python-heatclient | 
 | 63 |      GLANCECLIENT_REPO=/home/vagrant/src/python-glanceclient | 
 | 64 |      NOVACLIENT_REPO=/home/vagrant/src/python-novaclient | 
 | 65 |      NEUTRONCLIENT_REPO=/home/vagrant/src/python-neutronclient | 
 | 66 |      OPENSTACKCLIENT_REPO=/home/vagrant/src/python-openstackclient | 
 | 67 |      HEAT_CFNTOOLS_REPO=/home/vagrant/src/heat-cfntools | 
 | 68 |      HEAT_TEMPLATES_REPO=/home/vagrant/src/heat-templates | 
 | 69 |      NEUTRON_FWAAS_REPO=/home/vagrant/src/neutron-fwaas | 
 | 70 |      # ... | 
 | 71 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 72 | Why a shell script, why not chef/puppet/... | 
 | 73 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 74 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 75 | The script is meant to be read by humans (as well as ran by | 
 | 76 | computers); it is the primary documentation after all. Using a recipe | 
 | 77 | system requires everyone to agree and understand chef or puppet. | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 78 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 79 | I'd like to help! | 
 | 80 | ~~~~~~~~~~~~~~~~~ | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 81 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 82 | That isn't a question, but please do! The source for DevStack is at | 
 | 83 | `git.openstack.org | 
 | 84 | <https://git.openstack.org/cgit/openstack-dev/devstack>`__ and bug | 
 | 85 | reports go to `LaunchPad | 
| zhangbailin | c63d933 | 2017-09-01 19:46:16 -0700 | [diff] [blame] | 86 | <https://bugs.launchpad.net/devstack/>`__. Contributions follow the | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 87 | usual process as described in the `developer guide | 
| zhangbailin | c63d933 | 2017-09-01 19:46:16 -0700 | [diff] [blame] | 88 | <https://docs.openstack.org/infra/manual/developers.html>`__. This | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 89 | Sphinx documentation is housed in the doc directory. | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 90 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 91 | Why not use packages? | 
 | 92 | ~~~~~~~~~~~~~~~~~~~~~ | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 93 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 94 | Unlike packages, DevStack leaves your cloud ready to develop - | 
| Sean Dague | 8b8441f | 2017-05-02 06:14:11 -0400 | [diff] [blame] | 95 | checkouts of the code and services running locally under systemd, | 
 | 96 | making it easy to hack on and test new patches. However, many people | 
 | 97 | are doing the hard work of packaging and recipes for production | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 98 | deployments. | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 99 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 100 | Why isn't $MY\_FAVORITE\_DISTRO supported? | 
 | 101 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 102 |  | 
 | 103 | DevStack is meant for developers and those who want to see how | 
 | 104 | OpenStack really works. DevStack is known to run on the distro/release | 
 | 105 | combinations listed in ``README.md``. DevStack is only supported on | 
 | 106 | releases other than those documented in ``README.md`` on a best-effort | 
 | 107 | basis. | 
 | 108 |  | 
| Atsushi SAKAI | e3c2673 | 2015-11-06 13:23:47 +0900 | [diff] [blame] | 109 | Are there any differences between Ubuntu and CentOS/Fedora support? | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 110 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 111 |  | 
 | 112 | Both should work well and are tested by DevStack CI. | 
 | 113 |  | 
 | 114 | Why can't I use another shell? | 
 | 115 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 116 |  | 
 | 117 | DevStack now uses some specific bash-ism that require Bash 4, such as | 
 | 118 | associative arrays. Simple compatibility patches have been accepted in | 
 | 119 | the past when they are not complex, at this point no additional | 
 | 120 | compatibility patches will be considered except for shells matching | 
 | 121 | the array functionality as it is very ingrained in the repo and | 
 | 122 | project management. | 
 | 123 |  | 
 | 124 | Can I test on OS/X? | 
 | 125 | ~~~~~~~~~~~~~~~~~~~ | 
 | 126 |  | 
 | 127 | Some people have success with bash 4 installed via homebrew to keep | 
 | 128 | running tests on OS/X. | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 129 |  | 
| Ian Wienand | 64cf204 | 2015-06-02 10:28:55 +1000 | [diff] [blame] | 130 | Can I at least source ``openrc`` with ``zsh``? | 
 | 131 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 132 |  | 
 | 133 | People have reported success with a special function to run ``openrc`` | 
 | 134 | through bash for this | 
 | 135 |  | 
 | 136 | .. code-block:: bash | 
 | 137 |  | 
 | 138 |    function sourceopenrc { | 
 | 139 |        pushd ~/devstack >/dev/null | 
| Ethan Lynn | e256174 | 2016-03-30 23:40:56 +0800 | [diff] [blame] | 140 |        eval $(bash -c ". openrc $1 $2 >/dev/null;env|sed -n '/OS_/ { s/^/export /;p}'") | 
| Ian Wienand | 64cf204 | 2015-06-02 10:28:55 +1000 | [diff] [blame] | 141 |        popd >/dev/null | 
 | 142 |    } | 
 | 143 |  | 
 | 144 |  | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 145 | Operation and Configuration | 
| Sean Dague | 3293046 | 2014-11-18 06:51:16 -0500 | [diff] [blame] | 146 | =========================== | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 147 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 148 | Can DevStack handle a multi-node installation? | 
 | 149 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 150 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 151 | Yes, see :doc:`multinode lab guide <guides/multinode-lab>` | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 152 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 153 | How can I document the environment that DevStack is using? | 
 | 154 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 155 |  | 
 | 156 | DevStack includes a script (``tools/info.sh``) that gathers the | 
 | 157 | versions of the relevant installed apt packages, pip packages and git | 
 | 158 | repos. This is a good way to verify what Python modules are | 
 | 159 | installed. | 
 | 160 |  | 
 | 161 | How do I turn off a service that is enabled by default? | 
 | 162 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 163 |  | 
 | 164 | Services can be turned off by adding ``disable_service xxx`` to | 
| Jordan Pittier | 326e480 | 2016-02-12 15:23:43 +0100 | [diff] [blame] | 165 | ``local.conf`` (using ``c-vol`` in this example): | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 166 |  | 
 | 167 |     :: | 
 | 168 |  | 
| Jordan Pittier | 326e480 | 2016-02-12 15:23:43 +0100 | [diff] [blame] | 169 |         disable_service c-vol | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 170 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 171 | Is enabling a service that defaults to off done with the reverse of the above? | 
 | 172 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 173 | Of course! | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 174 |  | 
 | 175 |     :: | 
 | 176 |  | 
| Sean Dague | 37eca48 | 2015-06-16 07:19:22 -0400 | [diff] [blame] | 177 |         enable_service q-svc | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 178 |  | 
| Sean Dague | 1759618 | 2015-10-05 15:26:43 -0400 | [diff] [blame] | 179 | How do I run a specific OpenStack release? | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 180 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 181 |  | 
| Sean Dague | 1759618 | 2015-10-05 15:26:43 -0400 | [diff] [blame] | 182 | DevStack master tracks the upstream master of all the projects. If you | 
 | 183 | would like to run a stable branch of OpenStack, you should use the | 
 | 184 | corresponding stable branch of DevStack as well. For instance the | 
| Jordan Pittier | 99d5d1c | 2017-03-15 13:42:25 +0100 | [diff] [blame] | 185 | ``stable/ocata`` version of DevStack will already default to all the | 
 | 186 | projects running at ``stable/ocata`` levels. | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 187 |  | 
| Sean Dague | 1759618 | 2015-10-05 15:26:43 -0400 | [diff] [blame] | 188 | Note: it's also possible to manually adjust the ``*_BRANCH`` variables | 
 | 189 | further if you would like to test specific milestones, or even custom | 
 | 190 | out of tree branches. This is done with entries like the following in | 
 | 191 | your ``local.conf`` | 
 | 192 |  | 
 | 193 | :: | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 194 |  | 
 | 195 |         [[local|localrc]] | 
| Sean Dague | 1759618 | 2015-10-05 15:26:43 -0400 | [diff] [blame] | 196 |         GLANCE_BRANCH=11.0.0.0rc1 | 
 | 197 |         NOVA_BRANCH=12.0.0.0.rc1 | 
 | 198 |  | 
 | 199 |  | 
 | 200 | Upstream DevStack is only tested with master and stable | 
| Atsushi SAKAI | e3c2673 | 2015-11-06 13:23:47 +0900 | [diff] [blame] | 201 | branches. Setting custom BRANCH definitions is not guaranteed to | 
| Sean Dague | 1759618 | 2015-10-05 15:26:43 -0400 | [diff] [blame] | 202 | produce working results. | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 203 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 204 | What can I do about RabbitMQ not wanting to start on my fresh new VM? | 
 | 205 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
| Ian Wienand | a16e461 | 2015-06-02 10:08:04 +1000 | [diff] [blame] | 206 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 207 | This is often caused by ``erlang`` not being happy with the hostname | 
 | 208 | resolving to a reachable IP address. Make sure your hostname resolves | 
 | 209 | to a working IP address; setting it to 127.0.0.1 in ``/etc/hosts`` is | 
 | 210 | often good enough for a single-node installation. And in an extreme | 
 | 211 | case, use ``clean.sh`` to eradicate it and try again. | 
 | 212 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 213 | Why are my configuration changes ignored? | 
 | 214 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 215 |  | 
 | 216 | You may have run into the package prerequisite installation | 
 | 217 | timeout. ``tools/install_prereqs.sh`` has a timer that skips the | 
 | 218 | package installation checks if it was run within the last | 
 | 219 | ``PREREQ_RERUN_HOURS`` hours (default is 2). To override this, set | 
 | 220 | ``FORCE_PREREQ=1`` and the package checks will never be skipped. | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 221 |  | 
 | 222 | Miscellaneous | 
| Sean Dague | 3293046 | 2014-11-18 06:51:16 -0500 | [diff] [blame] | 223 | ============= | 
| Sean M. Collins | 09e550c | 2014-10-21 11:40:08 -0400 | [diff] [blame] | 224 |  | 
| Ian Wienand | 2f27add | 2015-06-02 10:18:49 +1000 | [diff] [blame] | 225 | ``tools/fixup_stuff.sh`` is broken and shouldn't 'fix' just one version of packages. | 
 | 226 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 
 | 227 |  | 
 | 228 | Stuff in there is to correct problems in an environment that need to | 
 | 229 | be fixed elsewhere or may/will be fixed in a future release. In the | 
 | 230 | case of ``httplib2`` and ``prettytable`` specific problems with | 
 | 231 | specific versions are being worked around. If later releases have | 
 | 232 | those problems than we'll add them to the script. Knowing about the | 
 | 233 | broken future releases is valuable rather than polling to see if it | 
 | 234 | has been fixed. |