Commit Graph
443 Commits
Author SHA1 Message Date
mridulv 30cd786303 ceph: adding ability to specify crushroot in the CRD
Previously we did not supported defining crushRoot in some of the CRDs. With this fix, we plan to fix this behaviour.

Signed-off-by: mridulv <mridulv09@gmail.com>
2020-08-08 16:24:15 +05:30
Umanga Chapagain da1910840a ceph: add CRD changes and documentation
adds `enableRBDStats` to CRD manifets and updates documentation
on its usage.

Signed-off-by: Umanga Chapagain <chapagainumanga@gmail.com>
2020-08-06 12:11:55 +05:30
Sébastien Han 89b3225441 ceph: add encryption support for osd pvc
We can now encrypted OSD device that were provisioned via a storage
class using the PV interface.
The encryption works at the storageClassDeviceSets level, which means we
can have encrypted and non-encrypted sets.
Using the new key `encrypted` we can turn it on.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-05 10:06:11 +02:00
Travis Nielsen 772b7990db ceph: updated clusterroles applied in upgrade test
In the upgrade integration test we need to mirror what we expect
users to do during the upgrade by applying the new clusterroles.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-04 16:04:07 -06:00
Travis Nielsen 2365885653 ceph: remove unnecessary aggregate clusterroles
The aggregate clusterrole were designed for the scenario where
the rules are not completely owned by one component. Since Rook
owns all of the RBAC for its components, the aggregate rules can
be removed and simplify certain issues around upgrades.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-04 15:47:18 -06:00
Travis Nielsen 14495d1e5a ceph: upgrade documentation for v1.4
The upgrade guide is now updated for upgrades from v1.3 to v1.4.
The v1.2 upgrade yamls are removed and the docs are cleaned up from
1.3 upgrade steps that are no longer necessary.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-04 15:47:18 -06:00
Travis Nielsen e0ea87a353 Merge pull request #5674 from thotz/quotaobc
ceph: adding support for quota in object bucket claims
2020-07-30 22:51:58 -06:00
Travis Nielsen 91a1f2dc9e Merge pull request #5921 from binoue/add-event-log-file
ci: create Kubernetes Event log file
2020-07-30 11:24:03 -06:00
binoue 937b77f8e6 ceph: revised according to the review comments
revised according to the review comments

Signed-off-by: binoue <banji-inoue@cybozu.co.jp>
2020-07-30 07:44:08 +09:00
binoue 9a44b95f68 ceph: create event log file
Currently, rook CI is not logging Kubernetes Events, but it sometimes gives hints
for bugs.
Therefore, this PR adds a function to collect and log Kubernetes Events.

Signed-off-by: binoue <banji-inoue@cybozu.co.jp>
2020-07-29 16:02:05 +09:00
Madhu Rajanna 28f0471106 ceph: update clusterrole of operator for csidrivers
updated the clusterrole of the rook operator
to delete the csidrivers object when csi-drivers
are disabled, without the required access rook operator
cannot delete the csidrivers object.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-29 09:41:26 +05:30
Jiffin Tony Thottan f4240cb31d ceph: add quota support for obc
Closes: #5274
Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-07-28 12:00:11 +05:30
Alexander Trost 0795204b1d Merge pull request #5872 from cloudical-io/cassandra_update
cassandra: use latest 3.11.6 version in examples
2020-07-23 15:26:36 +02:00
Sébastien Han e517ac96aa ceph: fail if the pool fails to be deleted
Let's assert if the pool is still present.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-22 17:25:15 +02:00
Sébastien Han 39931b1edf ceph: fix conditions not being applied
Somehow, the client.Update was not updating the cluster object, using
client.Status().Update actually fixed it.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-22 17:25:15 +02:00
Travis Nielsen 66d81230ac Merge pull request #5870 from Madhu-1/remove-metaflag
ceph: remove unwanted metadatastore and mountcache flag
2020-07-22 09:00:23 -06:00
Alexander Trost 29e51cb1e9 cassandra: use latest 3.11.6 version in examples
This also updates the cassandra version in the tests.
This is to provide safe and secure defaults to users running Cassandra.

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2020-07-22 13:18:43 +02:00
Madhu Rajanna 73e1ee41c3 ceph: remove unwanted metadatastore and mountcache flag
metadatastore and mountcache are required for cephcsi v1.0.0

as rook doesnot used ceph-csi v1.+ version
we can remove this flag. Removing these flags doesnot
affect the functionality of anything.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-22 14:36:11 +05:30
Sébastien Han bc4875a5eb ci: only apply cleanup policy on converged cluster
There is no point of asking for a cleanup when the cluster is external,
also the cleanup pod will never exist and the CI will fail waiting for
it.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-21 17:10:28 +02:00
Sébastien Han 6444675d4d ci: debug cleanup job logs
Add logs of the cleanup jobs on success.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-21 17:10:26 +02:00
Sébastien Han 10ed662bdb ceph: enhancement disk sanitize options
Now, we can not only cleanup monitor data, logs and crashes but the
disks too. As part of the cleanupPolicy CR spec, we have a new setting
called sanitizeDisk which holds more details:

* method: indicates if the entire disk should be sanitized or simply ceph's metadata.
Possible choices are 'complete' or 'quick' (default)
* dataSource: indicate where to get random bytes from to write on the disk.
Possible choices are 'zero' (default) or 'random'
Using random sources will consume entropy from the system and will take much more time then the zero source
* iteration: overwrite N times instead of the default (1). Takes an integer value

See the documentation for more details.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-21 14:07:11 +02:00
Sébastien Han 97a029e691 Merge pull request #5844 from vbnrh/ci-issue-admission
ceph:  disables admission controller tests for k8 v1.14 and older.
2020-07-20 17:48:54 +02:00
Vineet Badrinath f0bb6b11bd ceph: disables admission controller tests for k8 v1.14 and older
Adds checks to see whether the k8s version is greater than v1.15 in integration tests.
when true, it will run the scripts for the admission controllers.

Closes: https://github.com/rook/rook/issues/5841
Signed-off-by: Vineet Badrinath <vbadrina@redhat.com>
2020-07-20 19:36:17 +05:30
Sébastien Han 90787daef7 ceph: do not enable the 'rook' module by default
We currently don't use the module, so let's speed up the bootstrap
progress as well as the reconcile by not always enabling it.
It can always be enabled via the spec mgr section.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-17 10:37:28 +02:00
Travis Nielsen e74c7eaef8 ceph: refactor context and clusterInfo passed to the ceph commands
To provide more context for executing commands in a ceph cluster,
the full clusterInfo is now passed to the ceph execution commands.
All information about the cluster will now be available throughout
all the areas of the operator. The namespace, ceph credentials,
mon endpoints, and other info is a core part of that cluster info.

Arguments passed through the controllers are also simplified for
mons, mgr, osds, and other daemons where the parameters had
become too complex.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-07-16 15:54:54 -06:00
Travis Nielsen 2514699ccd Merge pull request #5817 from travisn/enable-mgr-test
Re-enable the Ceph Mgr integration test that runs against Ceph master
2020-07-15 15:09:38 -06:00
Blaine Gardner f2bc23c33e Merge pull request #4916 from SUSE/drive-groups
Ceph: provision OSDs using Drive Groups
2020-07-14 18:08:45 -06:00
Travis Nielsen 3d3986ee02 Merge pull request #5785 from prksu/fix-nfs-on-openshift
nfs: fix nfs issue on openshift
2020-07-14 11:06:47 -06:00
Blaine Gardner 7117fc12b7 ceph: osd: add drive groups spec to cluster CR
Add the ability to provision Ceph OSDs with Drive Groups.
This adds Drive Groups to the CephCluster CRD, and it sets code
in place for propagating this config to the OSD provisioning pod.

Signed-off-by: Blaine Gardner <blaine.gardner@suse.com>
2020-07-14 09:43:03 -06:00
Ahmad Nurus S 1659687d37 nfs: fix nfs issue on openshift
Signed-off-by: Ahmad Nurus S <prksu.sh@gmail.com>
2020-07-14 18:11:39 +07:00
Travis Nielsen cb8111c042 ci: check for official build string properly
The version of Jenkins has changed such that setting the official build env
var is no longer comparing correctly. Now we will only assume the env
var is set by the PR to false, therefore the tests need to compare
against false instead of true.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-07-13 13:53:57 -06:00
Sébastien Han ccb52b84e6 ceph: configurable status checks and livenessprobe
This commit allows us to configure status check for each daemon:

* "mon": health check on the ceph monitors (quorum)
* "osd": health check on the ceph osds
* "status": ceph health status check

Each check is controlled by the following settings:

* disabled: whether to disable the check (default: false)
* internal: interval to run the check
* timeout: only valid for mons, is the timeout for unresponsive mon
before failling over.

Example to disable the status health check:

```yaml
healthCheck:
  daemonHealth:
    status:
      disabled: true
```

As part of that, pod's livenessprobe can now be configured via the
following settings:

* disabled: whether to enable or not
* probe: override the current probe in place by a new one

```yaml
healthCheck:
  livenessProbe:
    mon:
      disabled: true
```

Closes: https://github.com/rook/rook/issues/5772
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-10 19:21:59 +02:00
Sébastien Han 6de1ad8575 ceph: resync crds
Add missing API fields.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-08 09:28:40 +02:00
Travis Nielsen dbae36b2bb ceph: update to the latest octopus release
Update the base operator image and cluster examples to use the latest
octopus release v15.2.4. Also cleanup some old examples and unit tests
that were still based on mimic.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-07-06 12:11:47 -06:00
Travis Nielsen 2d793cdc3f ceph: disable ceph mgr test temporarily
Due to an issue in ceph master, the mgr integration test is failing.
Until this is fixed, we will temporarily disable the test. A fix
is expected with https://github.com/ceph/ceph/pull/35915

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-07-06 09:19:41 -06:00
Travis Nielsen 9332d31196 Merge pull request #5755 from travisn/skip-mgr-test-in-master
ceph: Add logging for mgr integration test suite in master
2020-07-06 08:24:31 -06:00
Ahmad Nurus S f7f8270f58 nfs: rewrite nfs operator controller to use controller-runtime
Signed-off-by: Ahmad Nurus S <prksu.sh@gmail.com>
2020-07-03 14:33:25 +07:00
Travis Nielsen 5ec75c16e4 ceph: skip mgr integration test suite in master
The master CI is not expected to run the mgr test suite, which
runs against ceph master.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-07-02 17:00:38 -06:00
Sébastien Han e4eaa91ede ceph: add rgw endpoint healthcheck
We have introduced a new goroutine to check the state of the rgw
endpoint. It will run every minute and perform operations on a bucket.
The success or failure will be reported as part of the status field of
the CephObjectStore CR.

A good status will look like:

status:
  endpointStatus:
    lastChanged: "2020-06-25T13:47:45Z"
    lastChecked: "2020-06-25T13:48:46Z"
  phase: Connected

A failed status:

status:
  endpointStatus:
    details: |-
      error creating bucket "rook-ceph-internal-s3-bucket-checker": RequestError: send request failed
      caused by: Put http://rook-ceph-rgw-my-store.rook-ceph:8080/rook-ceph-internal-s3-bucket-checker: dial tcp 10.108.189.148:8080: connect: connection refused
    health: ERROR

This check works for both converged and external modes. Note that the
CephObjectStore CRD has a new field called "externalRgwEndpoints" which
allows you to define a list of IP addresses pointing to rgws.

Closes: https://github.com/rook/rook/issues/5692
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-02 16:34:10 +02:00
Madhu Rajanna 02c9bfe00f ceph: update RBAC required for external-snapshotter
Updated the required RBAC for external-snapshotter
beta to work.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-01 07:20:04 +05:30
Travis Nielsen 6c0d4057b3 Merge pull request #5045 from vbnrh/rook-admission-controller
ceph: Adding support for admission controllers
2020-06-25 09:56:39 -06:00
Vineet Badrinath ce1003aef8 ceph: adds scripts and components to support admission controllers
adds deploy.sh script to deploy validatingwebhookconfiguration and create secrets.
adds new command ceph admission-controller to start webhook servers.
adds validation for various rook custom resources

Signed-off-by: Vineet Badrinath <vbadrina@redhat.com>
2020-06-24 14:59:00 +05:30
Satoru Takeuchi c8c05ed7b9 ceph: fix the wrong document of tuneDeviceClass
The tuning parameter of slow device is defined as "tuneDeviceClass".
However, it's written in the document as "tuneSlowDeviceClass".

Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
2020-06-24 00:31:14 +00:00
Sébastien Han c7f255a0e8 ceph: add the ability to set any pool property
We can now explicitly set any property on a given pool by using the new
Property field in the CephBlockPool Spec.

Also, this fixes the case where both `CephBlockPool` and `CephCluster`
are created at the same time. When Rook creates the pool, the cluster is
still being bootstrapped and the global option
`osd_pool_default_pg_autoscale_mode` has not bee set yet. So the pool
gets created but its `pg_autoscale_mode` property is set to `warn`
instead of `on`.

Closes: https://github.com/rook/rook/issues/5608V
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-06-17 10:08:00 +02:00
Travis Nielsen 609d43d050 Merge pull request #5640 from binoue/fix-error-message
ceph: fix error message
2020-06-10 17:24:26 -06:00
binoue b52b59669f ceph: fix error message
This commit fixes an error message

Signed-off-by: binoue <banji-inoue@cybozu.co.jp>
2020-06-11 07:10:29 +09:00
Ali Maredia fc579f4520 ceph: initial commit for ceph rgw multisite resources
This commit contains CR implementations for:
CephObjectRealm
CephObjectZoneGroup
CephObjectZone

Also there are changes made to the objectstore
to add rgws in the object-store to zones and
zone groups in a multisite configuration and
the removal of the --default parameter for any
realms/zonegroups/zones that are created.

Signed-off-by: Ali Maredia <amaredia@redhat.com>
2020-06-09 16:28:53 -04:00
Sébastien Han c799e11032 ceph: enhancement cleanup with disks
Now, we can not only cleanup monitor data, logs and crashes but the
disks too. As part of the cleanupPolicy CR spec, we have a new setting
called sanitizeDisks which holds more details:

* confirmation: the confirmation message to sanitize disks,
use "yes-really-sanitize-disks" to confirm

This will **only** wipe the metadata, so it's a fast cleanup allowing
you to re-install later but won't remove all the data from the drive.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-05-27 18:14:02 +02:00
Travis Nielsen e1a9a9039b ceph: pool resize test hangs during cleanup
In Octopus 15.2.2 there is an rbd change that causes the rbd ls command
to hang if there are not sufficient OSDs to meet the replica requirement.
The smoke suite just started hanging today since the 15.2.2 image was
released with this change. Therefore, the test that resizes the pool
to replica 3 must resize back to 1 before cleaning up.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-05-19 22:02:37 -06:00
Satoru Takeuchi e96009c26d ceph: prepare PVCs for OSD on PVC test inside the integration test
The PVCs for OSD on PVC test is prepared before running the integration test.
In addition, users are forced to run this script for this by themselves.
To avoid this problem, running this script inside the integration test.

Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
2020-05-14 05:14:27 +09:00