60 Commits

Author SHA1 Message Date
Jenkins
820467f20f Merge "Simplify database_connection_url" 2013-03-14 21:12:18 +00:00
John Griffith
997c10306e Set debug to True in cinder.conf
Adds a line to lib/cinder to turn on debug logging
by default in Cinder.

Change-Id: I9cc7d78b97eea40fc787ca68721b58fc7a00faf4
2013-03-05 23:03:25 +00:00
Attila Fazekas
7e79d9139f Simplify database_connection_url
* does not expects dynamic scoping.
* does not uses eval.

Change-Id: I5ba4e5b7ffaabbb3c2bddadf9e53a2875de8b7c0
2013-03-03 13:13:36 +01:00
Jérôme Gallard
dda2b7afc7 Add cinder multi backend support to devstack
* add CINDER_MULTI_LVM_BACKEND parameter
* if CINDER_MULTI_LVM_BACKEND = True, creates 2 LVM volumes
    - Name : stack-volumes and stack-volumes2
    - Size : 5GB for each of them

Change-Id: I6e03b96e6b2aed0f0c166472300139fba9eaa68b
2013-02-26 09:44:34 +01:00
Stephen Mulcahy
67068ef415 Added cinder-backup service (not enabled by default)
cinder-backup service has been added to cinder. This fix adds the
cinder-backup service. To enable this service, c-bak must be added
to ENABLED_SERVICES in the users localrc. To actually perform a
backup the user must enable swift or another service.

Change-Id: If4ef8d78081be572987e7c38c76ff57e82b4f744
2013-02-22 15:45:56 +00:00
Joe Gordon
a58382acb6 Update cinder to use rootwrap_config
Move from using deprecated option root_helper to rootwrap_config

Fix bug 1130890

Change-Id: Iea8ad55f29bd74f2805c05d417ff56ab6afe6d72
2013-02-20 12:45:02 -08:00
Dean Troyer
f03bafeb84 Refactor init functions to simplify Grenade upgrades
* Glance: create_glance_cache_dir()
* Cinder: create_cinder_cache_dir() and create_cinder_volume_group()
* Nova: create_nova_cache_dir() and create_nova_keys_dir()
* Random tidy-up changes

Change-Id: I20d995d4c2e5facfb912ee03a6cda6c56f20bbe9
2013-02-15 14:56:19 -06:00
Jenkins
f3da41a5ee Merge "Introduce get_python_exec_prefix function." 2013-02-02 13:30:16 +00:00
Joe Gordon
07db713549 Improve millisecond logging
Always display 3 digits for milliseconds (appends 0s)
Based on I3f1461839258be0723e2d3616ec225a830d13029

Change-Id: I48b3f3781b4d34ed6a5fb9e4e78cee919afda6c1
2013-01-30 13:11:04 -08:00
Jakub Ruzicka
4196d5565e Introduce get_python_exec_prefix function.
get_python_exec_prefix returns the path to the direcotry where python
executables are installed, that is /usr/bin on Fedora and /usr/local/bin
everywhere else.

It is used to properly locate OpenStack executables.

Fixes: bug #1068386

Change-Id: I228498ebe2762568d00757d065e37377ee2c8fb3
2013-01-30 16:33:43 +01:00
Dan Prince
9f22f07a15 Cinder: update osapi_volume_extension default.
Updates the Cinder config file to use the new extension
loader location.

Change-Id: I515e16e00b54c69ae3c09e64841818eb4a9c8f73
2013-01-28 09:53:38 -05:00
MORITA Kazutaka
af22a477d1 lib/cinder: add sheepdog support
This enables us to use Sheepdog as a Cinder backend storage by setting
the CINDER_DRIVER environment variable.

Change-Id: I70cfb7f89ac3260d277fa160c457d220255de065
2013-01-17 16:58:05 +09:00
Akihiro MOTOKI
b0f1c38bdc Refactor rpc backend configuration logic
This commit also changes the following:
- Fixes Nova QPID module path
- Fixes a bug Cinder ZeroMQ RPC points to nova module
- Adds ZeroMQ setting for Heat RPC

qpid_is_supported is moved from functions to lib/rpc_backend.

This work is based on the work by Isaku Yamahata <yamahata@valinux.co.jp>
in https://review.openstack.org/#/c/19074/.

Change-Id: I45e21b1fb85e539213f5243764132a37906d7455
2013-01-14 16:12:06 +09:00
Jenkins
fec9355fd2 Merge "Fix "sudo: sorry, you must have a tty to run sudo"" 2013-01-12 20:35:13 +00:00
Jenkins
8aecaeee4c Merge "Set up Cinder for TLS" 2013-01-11 13:40:39 +00:00
Attila Fazekas
91b8d13eda Fix "sudo: sorry, you must have a tty to run sudo"
On many systems the requiretty sudoers option is turned on by default.
With "requiretty" option the sudo ensures the user have real tty access.

Just several "su" variant has an option for skipping the new session creation step.

Only one session can posses a tty, so after a "su -c" the sudo will not
work.

We will use sudo instead of su, when we create the stack account.

This change adds new variable the STACK_USER for
 service username.

Change-Id: I1b3fbd903686884e74a5a22d82c0c0890e1be03c
2013-01-11 09:15:30 +01:00
Jenkins
d9cfdc6ae1 Merge "Adjust CINDER_SECURE_DELETE flag to cinder changes" 2013-01-09 04:44:15 +00:00
Dean Troyer
22853c1974 Clean up cinder volume group rather than remove it
Removing the cinder volume group breaks devstack installations
that share that volume group with other logical volumes. It also was
leaking loopback devices.

Change-Id: Ice4470e06e08ce49a0e1f82af70abcc015c91c20
2013-01-07 15:21:08 -06:00
Joe Gordon
c99853ca71 Enable millisecond logging for nova and cinder
Change-Id: Ic28867ae9a436e81c7f2fcf79f40a1ecc251072c
2013-01-03 17:39:16 -08:00
Pádraig Brady
eac9370a12 Adjust CINDER_SECURE_DELETE flag to cinder changes
Cater for the pending more general cinder support
for configurable volume wiping method at:
https://review.openstack.org/#/c/12521

This change is done here first so as to not
trigger a CI lockup when the referenced patch above lands.
When that's in place, we can remove the older
secure_delete config adjustment in a subsequent patch.

Change-Id: I73fe2e0d1cf2815ab6025121584951cb5ff56fa3
2013-01-02 16:09:52 +00:00
Dean Troyer
6d04fd7ba5 Holiday docs and comment formatting cleanup
Change-Id: Ia4ca88c67d3b94e306a79a669805a2fa1b0dc069
2012-12-28 18:03:10 -06:00
Sean Dague
252f2f533b clean up cinder on an unstack
cinder currently has issues that leave volumes around
after tempest tests. Make sure that cinder gets cleaned
up to a zero state on an unstack.sh so that we can reset
the environment.

Change-Id: I448340899bf0fae7d4d16fa26da17feafcef888f
2012-12-20 16:43:41 -05:00
Dean Troyer
560346b506 Set up Cinder for TLS
* Start c-api proxy if 'tls-proxy' is enabled
* Configure Cinder service catalog for TLS

Change-Id: Ic692a0a16ffa51bfd4bfb67f827cd941ac0e72a4
2012-12-19 15:29:42 -06:00
Jenkins
701718a844 Merge "Use the right service name for tgt/tgtd in stop_cinder" 2012-12-19 18:39:36 +00:00
Jenkins
d22dd9c06c Merge "Clear out the keystone pki data for each run" 2012-12-18 13:13:50 +00:00
Vishvananda Ishaya
23431f3526 Clear out the keystone pki data for each run
This prevents old invalid tokens from working after a rerun of stack.sh
and potentially providing users and tenants that don't exist.

Fixes bug 1089700

Change-Id: Icfc22978e41e459d51b50bc7ad2e6d98d766e402
2012-12-17 08:44:01 -08:00
Dean Troyer
671c16e63a Move cinder account creation out of keystone_data.sh
Supports the coming HA/proxy configuration for Cinder

Change-Id: If2e08e45430dce895ed6bb1070612517a38ca4bc
2012-12-14 09:17:28 -06:00
Vincent Untz
90dd96d478 Use the right service name for tgt/tgtd in stop_cinder
Change-Id: I58cf8cdf88a3edebed729f4460e8ce222db3664d
2012-12-13 12:10:41 +01:00
Jenkins
e0195ed8ab Merge "Always create signing_dir regardless of token format" 2012-12-12 18:19:42 +00:00
Akihiro MOTOKI
5e3deb678e Always create signing_dir regardless of token format
Fixes bug 1088801

devstack does not create signing_dir when keystone token format is UUID.
If the default value of signing_dir is read-only, OpenStack services
such as Quantum server failed to start due to permission denied.

On the keystone client cannot know which token_format is used in keystone
in advance, so signing_dir should be created regardless of the token format.

Change-Id: I1b0d25c1ac4d22d9fb2c5443d15b96fdaa5a4c81
2012-12-11 18:16:05 +09:00
Vincent Untz
00011c0847 Add is_fedora and exit_distro_not_supported functions
Between is_fedora, is_ubuntu and is_suse, we can make the code a bit
simpler to read. We also use exit_distro_not_supported to identify
places where we need implementation details for new distros.

As "/sbin/service --skip-redirect" is Fedora-specific, guard this with a
is_fedora test too.

Change-Id: Ic77c0697ed9be0dbb5df8e73da93463e76025f0c
2012-12-07 09:06:07 +01:00
Jenkins
b3def626a2 Merge "Fix XenAPINFSDriver's path" 2012-12-06 21:27:23 +00:00
Jenkins
4b9062b619 Merge "Fix XenAPINFS configuration" 2012-12-06 21:27:04 +00:00
Mate Lakat
a0ca45f173 Fix XenAPINFSDriver's path
Fixes bug 1087329

As the driver was moved to a different location, devstack script needed
an update.

Change-Id: Iaa1db94a84b6e9cb99514ce886025600809e9f29
2012-12-06 17:45:49 +00:00
Attila Fazekas
b79574b495 Name the tgt/conf.d enties based on the vg name
On one system multiple volume and volume manger could be installed and
needs dedicated tgt config entries.
cinder-volumes, stack-volumes, nova-volumes are the default volume group
names.
/etc/tgt/conf.d/ files should be named based on the volume-group name.
The vg name is uniq on one system.
In devstack case the stack.conf is usable.

Changes:
* Rename conf.d/cinder.conf to conf.d/stack.conf
* Handle conf.d similary on all distribution

Change-Id: I856cdf4a21a414d2940d8f9d8b0b0368b1fad887
2012-12-06 17:24:10 +01:00
Mate Lakat
53d3d6baf9 Fix XenAPINFS configuration
fixes bug 1087272

Trying to configure XenAPINFS volume driver through localrc options
failed. This fix removes the extra check, as lib/cinder already exits on
error.

Change-Id: I874b7cee44861244cb7a340cc4094ef3f8b48a5a
2012-12-06 15:49:17 +00:00
Vincent Untz
c18b965152 Add is_ubuntu function
This replaces all of the [[ "$os_PACKAGE" = "deb" ]] tests, except when
those tests are before straight calls to dpkg.

Change-Id: I8a3ebf1b1bc5a55d736f9258d5ba1d24dabf04ea
2012-12-04 18:30:13 +01:00
Mate Lakat
b2fdafead2 Additional options for XenAPINFS cinder driver
Related to bp xenapi-storage-manager-nfs

Add configuration options to devstack scripts, so it is easier to set up
a system with a XenAPINFS volume backend. It makes possible to test this
configuration with exercises. To enable the XenAPINFS driver, specify:

CINDER_DRIVER=XenAPINFS
CINDER_XENAPI_CONNECTION_URL=<url for a xenserver>
CINDER_XENAPI_CONNECTION_USERNAME=<username for the xenserver>
CINDER_XENAPI_CONNECTION_PASSWORD=<password for the xenserver>
CINDER_XENAPI_NFS_SERVER=<a box that has an nfs export>
CINDER_XENAPI_NFS_SERVERPATH=<exported catalog>

in your localrc

Change-Id: Ia214172aac377d273a03849c8cc2adcbf5b8f607
2012-11-29 12:38:38 +00:00
Vincent Untz
856a11e0e4 Add partial openSUSE/SLE support
Note that this is the first part of the support. A second part involves
dealing with the package names.

Among the changes:
 - add several functions to determine some distro-specific behavior (how
   to call usermod, if some features are available on the distro, etc.)
 - correctly detect openSUSE and SLE in GetOSVersion, and set DISTRO
   accordingly
 - new is_suse() function to check if running on a SUSE-based distro
 - use zypper to install packages
 - adapt apache virtual host configuration for openSUSE
 - some simple fixes (path to pip, mysql service name)

Change-Id: Id2f7c9e18a1c4a7b7cea262ea7959d183e4b0cf0
2012-11-28 16:22:12 +01:00
Dean Troyer
4d3049e7cd Configure Cinder for syslog if enabled
Change-Id: I3d2770cd2c3e3b93c0f26de359e5b0cb166826c1
2012-11-07 11:47:57 -06:00
James E. Blair
213c416878 Add CINDER_SECURE_DELETE flag.
Defaults to true which means no change in behavoir.  Adds option
to disable secure delete as in https://review.openstack.org/15477.

Change-Id: I2b19ed4223460b550026ad4975080c0079c8b433
2012-11-06 09:38:36 +01:00
Jenkins
308beccc24 Merge "Add PostgreSQL support to devstack" 2012-11-04 12:34:31 +00:00
Terry Wilson
428af5a257 Add PostgreSQL support to devstack
This patch adds an interface for supporting multiple database backend
types and implemnts support for PostgreSQL. It also adds a function,
use_exclusive_service, which serves as a base for enabling a service
that conflicts with other services. The use_database function uses it,
and it might also be useful for selecting messaging backends.

MySQL is still selected by default. Tested on Fedora 17 and Ubuntu
12.04 with MySQL and PostgreSQL. Implements blueprint postgresql-support

Change-Id: I4b1373e25676fd9a9809fe70cb4a6450a2479174
2012-11-03 18:19:21 -04:00
Dean Troyer
bc071bcef0 Configure PKI cache dirs
* Configure Cinder, Glance, Keystone, Nova to put cached credentials
  from keystone.auth_token into /var/cache/<service>

It is not obvious to me that having each of these service share a
credentials cache is a good idea.  It does appear to work but this
patch takes the conservative approach of putting each service's cache
in a distinct directory.

More importantly it gets them out of $HOME!

Change-Id: If88088fc287a2f2f4f3e34f6d9be9de3da7ee00d
2012-10-31 13:23:39 -05:00
Eoghan Glynn
c6cc585f97 Ensure correct cinder dir is written to tgt config
The wrong directory was being placed in the tgtd config.

This change will allow https://review.openstack.org/13633 to gate.

Change-Id: Icbf7b5ecc9bc53ccc2aed0cacb9f5f61abe8f882
2012-09-25 18:16:59 +01:00
Dean Troyer
699a29f72d Implement screen process stop() function
Implements screen process stop in ceilometer, cinder, glance, heat, n-vol

Change-Id: Ic5e02926f026d0e6f4b39846bfe77634dd414c60
2012-09-21 14:02:38 -05:00
Dean Troyer
7903b795dd Add non-verbose output mode
Set VERBOSE=False to turn off the noise of stack.sh output.  All
output still is written to the logfile if LOGFILE is set.

Rebased

Change-Id: I316bc4d68c997ec907a48e720e2f7778428d935b
2012-09-17 19:38:23 +00:00
Dean Troyer
50ac792157 Move Glance data and Nova state dirs out of source dir
* allow NOVA_STATE_PATH to be overridden,
  default is now /opt/stack/data/nova
* add NOVA_INSTANCES_PATH to move the instances dir separately
  from the state dir
* allow GLANCE_CACHE_DIR to be overridden,
  default is now /opt/stack/data/glance/cache
* allow GLANCE_IMAGE_DIR to be overridden,
  default is inow /opt/stack/data/glance/images
* set GLANCE_BIN_DIR to support entry points (future)
* allow CINDER_STATE_PATH to be overridden,
  default is now /opt/stack/data/cinder

Change-Id: If95dc19b957ef5b9b14397835cd0543f82717f50
2012-09-13 14:49:45 -05:00
Mate Lakat
a39caacad3 Make sure tgt is using config.d approach
Fixes bug 1045358.

On ubuntu Oneiric, the tgt configuration was not using the config.d
approach. tgt was unable to find the config files, so no volumes could
be created. This fix makes sure, that the config.d directory is there,
and the configuration includes files from there.

Was Cinder only, added same fix for Nova volumes

Change-Id: I6752cb628dd22e91e640f0f584fafefa4cd6d0f1
2012-09-09 19:03:46 -05:00
ewindisch
3bae7c2c61 Add ZeroMQ RPC backend
Now prevents more than one RPC backend selection.
(ZeroMQ, Qpid, and Rabbit are mutually exclusive)

Configure quantum and cinder to use ZeroMQ

Adds qpid to cinder config.

Change-Id: I229c4c632213a303d097d4a029e986598073665a
2012-08-31 10:59:43 -04:00