Commit Graph

40 Commits

Author SHA1 Message Date
Nicolas Pochet dd47f6493f
Migrate tests to zaza
Depends-On: https://github.com/openstack-charmers/zaza/pull/93
Change-Id: I9a19960fdb239eb5a8d421f135285e89b8405267
2018-10-09 18:15:01 +02:00
Ryan Beisner eef2a8be2c Update functional test definitions
Change-Id: Ib8c7ccae838d4d79a5f9cf737fa8fd3478afadc4
2018-08-28 17:23:01 -07:00
James Page 8875a7a685 Enable bluestore by default
For Ceph Lumimous (12.2.0) or later enable Bluestore block device
format as the default for Ceph OSD's. Bluestore can be disabled by
setting the bluestore config option to False.

For older releases, Bluestore cannot be enabled as its not
supported - setting the config option will have no effect.

Change-Id: I5ca657b9c4da055c4e0ff12e8b91b39d0964be8c
2018-08-16 05:10:52 +01:00
Chris MacNaughton 6847ff9373 Remove old nova-compute / mysql relation
Change-Id: I0f07da697cb96279dcd7f7f70826c0c465737fb3
Closes-Bug: #1713807
2018-07-18 10:28:50 +02:00
Frode Nordahl 1f68a5874e
Update tests to not set `fsid` and `monitor-secret`
Get `fsid` from leader settings on ceph-mon unit where needed
for validation.

Change-Id: I751ecff76873a599c0d03ec1308e30e615e38aa8
Related-Bug: #1698154
2018-06-06 10:14:37 +02:00
Frode Nordahl 4368f6b545
Fix subscription of filter object error
In Python 3 filter() built-in returns a iterator and not a list

Change-Id: I641565109b0dcc816a66d3ca3eb578fb9ed44a1a
Closes-Bug: #1774694
2018-06-04 18:17:14 +02:00
Frode Nordahl 352d699387
Add pre-flight check for device pristinity
Add `non-pristine` key to `list-disks` action.

No longer attempt to do initializtion of `osd-journal` devices.

Make py27 test noop

Flip pep8 test to py3

Partial-Bug: #1698154
Change-Id: I0ca574fa7f0683b4e8a693b9f62fbf6b39689789
Depends-On: I90a866aa138d18e4242783c42d4c7c587f696d7d
2018-06-04 17:02:11 +02:00
Ryan Beisner 22ce311b0b
No reformat
Do not reformat devices.  A subsequent change will be necessary
to account for conditions where a reformat is still desired,
such as a set of blocking states and user-driven actions.

Partial-bug: #1698154

Depends-On: I90a866aa138d18e4242783c42d4c7c587f696d7d
Change-Id: I3a41ab38e7a1679cf4f5380a7cc56556da3aaf2b
2018-06-04 12:40:47 +02:00
David Ames de283cdad2 Enable Bionic as a gate test
Change bionic test from dev to gate for 18.05.

Change-Id: Ifbe70a78f93ca0aaeb8491130ef9b6567c1a3d78
2018-05-11 16:32:19 -07:00
James Page a21be9a7ab Improve idempotency of block device processing
Resync charms.ceph to pickup improvements in recording
of block devices that have been processed as OSD devices
to support better idempotency of block device processing
codepaths.

This fixes a particularly nasty issue with osd-reformat
is set to True where the charm can wipe and re-prepare
an OSD device prior to the systemd unit actually booting
and mounting the OSD's associated filesystem.

This change also makes the osd-reformat option a boolean
option which is more accessible to users of the charm
via the CLI and the Juju GUI.

Change-Id: I578203aeebf6da2efc21a10d2e157324186e2a66
Depends-On: I2c6e9d5670c8d1d70584ae19b34eaf16be5dea19
2018-04-10 14:34:53 +01:00
James Page b6dca11a1b luminous: ceph-volume switch
Switch to using ceph-volume + LVM for managing block devices
for Luminous and later; this is the upstream preferred approach
to managing OSD devices, allowing for more flexibility in terms
of use of crypto and logical volumes.

Change-Id: I30c4d29e6f568ac2e30a45b1a7bc0e68685c3707
Depends-On: I1675b67d364ae6042129a8a717d4bdffff5bde92
2018-04-10 09:17:38 +01:00
Andrew McLeod ed84524e3b Enable xenial-pike amulet test
Make default func27-smoke xenial-pike
Charm-helpers sync

Review and merge https://github.com/juju/charm-helpers/pull/69 first.

Change-Id: I32a04dfc995929840f8c544e1d5ed58066515210
2017-12-06 19:10:14 +00:00
Alex Kavanagh 4e1ecd55b8 Bring ceph-osd to Python 3
* Synced version of charm-helpers
* Synced version of charms.ceph to bring in Py3 compatible library
  methods.

Change-Id: I5ac45740f48a71d9cb0c5943472fc8590a723514
2017-11-17 12:13:54 +00:00
Frode Nordahl c4d4e42c1a Add actions to blacklist osd-devices
The blacklist actions allow for adding and removing devices
to a unit-local list of devices to be skipped during osd
initialization. This list will be used to override the
application level, and thereby deployment wide, 'osd-devices'
configuration option on a individual unit basis.

The pre-existing list-disk action is extended to return
list of blacklisted devices under the 'blacklist' key.

Change-Id: I28a3c5d6076fb496dead3fe3387d9bbbbe9ec083
Closes-Bug: #1730267
2017-11-09 07:06:29 +01:00
Frode Nordahl 8ba8bce657 Update functional test model to use cinder-ceph subordinate
Change-Id: I2d441da31e8e3b6570bf237661bf22c294d8ee73
Related-Bug: #1719742
2017-10-23 17:17:43 +02:00
James Page 14f5033815 Drop configuration for global keyring
Drop explicit global configuration of keyring, supporting
installation of the ceph/ceph-mon/ceph-osd charms in the
same machine.

Change-Id: Ib4afd01fbcc4478ce90de5bd464b7829ecc5da7e
Closes-Bug: 1681750
2017-09-14 13:10:13 -06:00
David Ames 42b71274d6 Enable Ocata Amulet Tests
- Add Zesty as a supported series to metadata.yaml.
- Turn on Xenial-Ocata Amulet test definitions.
- Sync charm helpers to get Juju 2.x amulet compatibility.
- Keeping Zesty-Ocata Amulet test definitions turned off until the
  metadata.yaml changes propagate to the charm store.
- Resync tox.ini to resolve amulet unit test failures.

Change-Id: Ia14904339099d84d09a2fce171740459a76a8367
2017-03-23 09:29:00 +00:00
Ryan Beisner 3a3cbcb37b Update Amulet defs, series metadata and c-h sync
- Sync charm helpers if applicable.

- Fix test executable hashbags for virtualenv prep.

- Add Yakkety-Newton Amulet test definitions.

- Prep Xenial-Ocata Amulet test definitions (not yet enabled).

- Prep Zesty-Ocata Amulet test definitions (not yet enabled).

- Remove Precise charm series metadata if present.

- Remove Precise Amulet test definitions if present.

Change-Id: I367b6e9e22464c0b85e71ad330234477699835e0
2016-12-03 16:41:49 +00:00
Ryan Beisner b6f4efa89e Update amulet test definitions for Newton
- Remove Precise-Icehouse Amulet test definitions if they exist.

- Add Xenial-Newton Amulet test definitions.

- Add Yakkety-Newton Amulet test definitions.

- Use the percona-cluster charm in tests instead of the mysql charm.

Change-Id: Icb3adfbe08c9db339499f69523f7b223dda94c0c
2016-10-10 20:53:52 -05:00
Ryan Beisner fd15c0d586 Use bundletester for amulet test execution
Switch to using bundletester for execution of functional tests,
leveraging tox to build out test virtualenvs.

Rename amulet tests inline with gate-*, dev-* and dfs-*
naming standards.

Update README to refer to functional testing section of the charm
guide.

Change-Id: I618219551fc116c151cda4790c01aa9e86fa462a
2016-07-21 18:06:41 +00:00
James Page c32211c8e1 Re-license charm as Apache-2.0
All contributions to this charm where made under Canonical
copyright; switch to Apache-2.0 license as agreed so we
can move forward with official project status.

In order to make this change, this commit also drops the
inclusion of upstart configurations for very early versions
of Ceph (argonaut), as they are no longer required.

Change-Id: I9609dd79855b545a2c5adc12b7ac573c6f246d48
2016-06-28 12:01:05 +01:00
Jenkins 73087e1306 Merge "Update test to validate processes better" 2016-04-14 18:30:48 +00:00
Chris MacNaughton c8847fe0a7 Update test to validate processes better
This test is being updated to use the new functionality
being made available in the charmhelpers sync

Also, update tests/charmhelpers

Change-Id: I3109be2ee6069101c72ca1cfd786bcfc66fa27e0
2016-04-14 08:51:48 -04:00
Ryan Beisner 9e51997542 Enable Xenial-Mitaka amulet test target
Also remove irrelevant service checks from amulet test.

Change-Id: I66bb1ecfa85980f7c1ea340a225f40163028e56c
2016-04-11 18:53:09 +00:00
Alex Kavanagh bbfdeb84f0 Pause/resume for ceph-osd charm
This changeset provides pause and resume actions to the ceph charm.
The pause action issues a 'ceph osd out <local_id>' for each of the
ceph osd ids that are on the unit.  The action does not stop the
ceph osd processes.

Note that if the pause-health action is NOT used on the ceph-mon
charm then the cluster will start trying to rebalance the PGs accross
the remaining OSDs.  If the cluster might reach its 'full ratio' then
this will be a breaking action.  The charm does NOT check for this
eventuality.

The resume action issues a 'ceph osd in <local_id>' for each of the
local ceph osd process on the unit.

The charm 'remembers' that a pause action was issued, and if
successful, it shows a 'maintenance' workload status as a reminder.

Change-Id: I9f53c9c6c4bb737670ffcd542acec0b320cc7f6a
2016-04-08 11:25:18 +00:00
James Page 72b8ecade3 Check for Keystone apache2 process for liberty+
The keystone charm recently changed to run keystone as a wsgi
process under Apache2; refactor amulet test to ensure that
apache2 is checked instead of keystone for >= liberty.

Change-Id: Ide7c6e6349b80662677c6d9f3ef3e84b09b18b9b
2016-04-07 15:08:32 +01:00
Chris Holcombe 4285f14a55 Rolling upgrades of ceph osd cluster
This change adds functionality to allow the ceph osd cluster to
upgrade in a serial rolled fashion.  This will use the ceph monitor
cluster to lock and allows only 1 ceph osd server at a time to upgrade.
The upgrade is initiated setting a config value for source for the
service which will prompt the osd cluster to upgrade to that new
source and restart all osds processes server by server.  If an osd
server has been waiting on a previous server for more than 10 minutes
and hasn't seen it finish it will assume it died during the upgrade
and proceed with its own upgrade.

I had to modify the amulet test slightly to use the ceph-mon charm
instead of the default ceph charm.  I also changed the test so that
it uses 3 ceph-osd servers instead of 1.

Limtations of this patch: If the osd failure domain has been set to osd
than this patch will cause brief temporary outages while osd processes
are being restarted.  Future work will handle this case.

This reverts commit db09fdce93.

Change-Id: Ied010278085611b6d552e050a9d2bfdad7f3d35d
2016-03-31 11:36:27 -07:00
Chris MacNaughton 21929d7369 Update ceph_encryption amulet test to raise on failure
Currently, when this test should fail, it just returns
false, when it should amulet.raise_status so that the
test gets marked as failed. For Mitaka, we are currently
skipping the encryption test as the Ceph charm cannot
currently deploy encryption on Infernalis

Change-Id: I6a15b2d2560a5dffb9a77a8e5965613a8d3f6aac
2016-03-28 16:25:21 -04:00
Ryan Beisner 0cb5cd7f6d Update amulet test to include a non-existent osd-devices value
The osd-devices charm config option is a whitelist, and the
charm needs to gracefully handle items in that whitelist which
may not exist.

Change-Id: Iea212ef0e0987767e0e666ee2e30a59d4bef189a
2016-03-16 17:58:39 +00:00
Chris MacNaughton 130a309a15 support Ceph's --dmcrypt flag for OSD preparation
Tests now verify that ceph osds are running to ensure
they pass in either order

Change-Id: Ia543f4b085d4e97976ba08db508761f8dde97c42
2016-03-03 17:03:30 -05:00
Edward Hope-Morley 72a8deb4a6 fix amulet 2016-02-22 15:21:12 -05:00
Ryan Beisner a8d160208d Update amulet test definitions; Wait for workload status before testing. 2016-02-12 21:23:26 +00:00
Ryan Beisner c2ee546db7 add pre-kilo ceph-mon service status checks 2015-06-29 21:20:01 +00:00
Ryan Beisner 261ab212e0 update test 2015-06-29 20:14:43 +00:00
Ryan Beisner 7ab345fb05 re-sync tests/charmhelpers for cinder/glance helper updates 2015-06-23 23:35:27 +00:00
Ryan Beisner d68d9a9f67 Refactor osd pool checks for flexibility and reusability in other ceph-related charms (radosgw). 2015-06-22 16:11:44 +00:00
Ryan Beisner 4232f473ed update tests for process checking on systemd systems; misc cleanup. 2015-06-20 15:27:28 +00:00
Ryan Beisner 781f6edb6d amulet tests - update test coverage, enable vivid, prep for wily 2015-06-17 16:19:09 +00:00
Ryan Beisner 1858bc7f0c auto flip amulet debug on 2015-04-16 21:31:30 +00:00
Corey Bryant 0c008de899 Add basic amulet tests. 2014-09-27 18:17:20 +00:00