Commit Graph
8079 Commits
Author SHA1 Message Date
mergify[bot] f406ff22c2 Merge pull request #9521 from rook/mergify/bp/release-1.8/pr-9400
rgw: add events to CephBucketNotification CR (backport #9400)
2022-01-04 20:27:55 +00:00
Yuval Lifshitz e13d8c17fc rgw: add events to CephBucketNotification CR
the events are used to mark the start/success/failure of the reconciliation
and also to log the bucket names on which the CephbucketNotification is
created

Signed-off-by: Yuval Lifshitz <ylifshit@redhat.com>
(cherry picked from commit 11727b1673)
2022-01-04 19:59:17 +00:00
mergify[bot] f5bcc0144b Merge pull request #9520 from rook/mergify/bp/release-1.8/pr-9468
core: rgw: allow specifying daemon startup probes (backport #9468)
2022-01-04 18:27:53 +00:00
Blaine Gardner 86c2301cfc core: rgw: allow specifying daemon startup probes
Allow specifying daemon startup probes where we also allow configuring
liveness probes. Startup probes allow Rook to tolerate when Ceph daemons
occasionally take a long time to start up while not also making
Kubernetes liveness probes slower to detect runtime failures of daemons.

Startup probes are beta in Kubernetes 1.18, so we should not enable
probes by default for earlier Kubernetes versions.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
(cherry picked from commit c07d89d9ea)
2022-01-04 18:04:06 +00:00
Blaine Gardner a5f8e42c36 Merge pull request #9518 from rook/mergify/bp/release-1.8/pr-9512
core: run discover daemonset as root uid (backport #9512)
2022-01-04 10:44:32 -07:00
mergify[bot] 295df75289 Merge pull request #9517 from rook/mergify/bp/release-1.8/pr-9515
build: use the same csv name for all platforms (backport #9515)
2022-01-04 17:08:10 +00:00
Sébastien Han 78c296589f core: run discover daemonset as root uid
So that the tool inside the container has the permission to run
correctly, e.g: sgdisk.

Clsoes: https://github.com/rook/rook/issues/9493
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit dd67b866dc)
2022-01-04 16:54:06 +00:00
Sébastien Han 7c5d0ed3ee build: use the same csv name for all platforms
Recently with the directory renaming to "deploy/olm" the CSV name
changed from "ceph" to "olm". Now we are using the same "rook-ceph" name
regardless of the platform.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 7cf9285501)
2022-01-04 16:41:13 +00:00
mergify[bot] ca89626f3c Merge pull request #9490 from rook/mergify/bp/release-1.8/pr-9489
build: add missing helm (backport #9489)
2021-12-27 05:05:59 +00:00
Satoru Takeuchi c1f2df3798 build: add missing helm
If helm is not install, `make` fails with the following log.

```console
./build/rbac/get-helm-rbac.sh: line 25: helm: command not found
```

Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
(cherry picked from commit a7b5f06622)
2021-12-27 03:40:24 +00:00
mergify[bot] 06ac5cb699 Merge pull request #9481 from rook/mergify/bp/release-1.8/pr-9384
subvolumegroup: add new crd (backport #9384)
2021-12-21 17:51:50 +00:00
mergify[bot] d08c043ee7 Merge pull request #9480 from rook/mergify/bp/release-1.8/pr-9365
object: fix handling for notifications for OBC (backport #9365)
2021-12-21 17:47:14 +00:00
Sébastien Han 21c6a89541 subvolumegroup: add new crd
This introduces a new CRD to add the ability to create subvolumegroup
for a given ceph filesystem volume. Typically the name of the volume is
the name of the filesystem created by rook.

Closes: https://github.com/rook/rook/issues/7036
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 6e9eb33782)
2021-12-21 17:24:36 +00:00
Jiffin Tony Thottan c3db97f83d object: fix handling for notifications for OBC
Current approach is to delete all the existing notifcations from bucket
and re-add the notification from the labels.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
(cherry picked from commit 9d9acc2db1)
2021-12-21 17:24:14 +00:00
mergify[bot] ceae2a4550 Merge pull request #9479 from rook/mergify/bp/release-1.8/pr-9434
osd: handle removal of encrypted osd deployment (backport #9434)
2021-12-21 15:42:19 +00:00
Sébastien Han 7b1a08d427 osd: handle removal of encrypted osd deployment
This is handling a tricky scenario where the OSD deployment is manually
removed and the OSD never reconvers. This is unlikely to happen, but
still OSD should be able to run after that action. Essentially after a
manual deletion, we need to run the prepare job again to re-hydrate the
OSD information so that the OSD deployment can be deployed.
On encryption, it is a little bit tricky since ceph-volume list again
the main block won't return anything, so we need to target the encrypted
block to list.
There is another case this PR does not handle, which is the removal of
the OSD deployment and then the node is restarted. This means that the
encrypted container is not opened anymore. However, opening it requires
more work like writing the key on the filesystem (if not coming from the
Kubernete secret, eg,. KMS vault) and then run luksOpen. This is an
extreme corner case probably not worth worrying about for now.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 05775b068d)
2021-12-21 15:15:18 +00:00
mergify[bot] 0158da1feb Merge pull request #9477 from rook/mergify/bp/release-1.8/pr-9457
core: disallow multiple clusters in the same namespace (backport #9457)
2021-12-20 16:44:07 +00:00
Sébastien Han 64f46b095c Merge pull request #9475 from rook/mergify/bp/release-1.8/pr-9473
docs: fixed typo on rbd mirroring documentation (backport #9473)
2021-12-20 17:18:45 +01:00
Sébastien Han eab4073431 core: disallow multiple clusters in the same namespace
Rook does not support running multiple clusters in the same namespace,
so the operator should not reconcile if a new cluster is added.
The scenario where a cluster is added while the operator is down is also
handled. CR updates are also handled.
When the operator detects more than one cluster it will refuse to
reconcile the CephCluster, and child CRDs will block too until the
operator is ready.
The user must remove one of the clusters before can continue to perform
any reconcile.

Closes: https://github.com/rook/rook/issues/9452
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit da76a772f8)
2021-12-20 16:18:44 +00:00
Sébastien Han bd678416c2 core: do not log create event as info
Let's use debug not to clutter logs.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 52ededd151)
2021-12-20 16:18:43 +00:00
mergify[bot] a025d96460 Merge pull request #9476 from rook/mergify/bp/release-1.8/pr-9427
operator: always report events (backport #9427)
2021-12-20 16:10:12 +00:00
Blaine Gardner 769e774719 operator: always report events
The original PR which added event reporting unnecessarily "optimized" to
prevent spamming the API controller[1].

It is sometimes important to get events as they happen and not hide new
events behind preexisting older events. For example, in integration
tests, we may often want to wait for a controller to finish processing
an update, and the best way to do that is to wait for the
"ReconcileSucceeded" event. In order for this to be useful, the events
must be reported each time.

If we begin having problems with events being reported too often, then
we should fix the underlying issue of reconciles happening too often
instead of relying on a time-based "optimization" that hides recent
event reports that may be useful.

[1]: https://github.com/rook/rook/pull/7222

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
(cherry picked from commit da61ac1ae8)
2021-12-20 15:42:58 +00:00
vshinde727 503ac9b7dc docs: fixed typo on rbd mirroring documentation
Signed-off-by: Vivek Shinde <vshinde@parallelwireless.com>
(cherry picked from commit 6a0690383a)
2021-12-20 13:19:39 +00:00
Satoru Takeuchi 76dc8ddf4b Merge pull request #9463 from rook/mergify/bp/release-1.8/pr-9441
ceph: fix blockOwnerDeletion error (backport #9441)
2021-12-20 17:24:54 +09:00
Satoru Takeuchi b7c4544860 Merge pull request #9472 from rook/mergify/bp/release-1.8/pr-9465
docs: Recommend primary affinity over hybrid pools (backport #9465)
2021-12-20 17:23:51 +09:00
Travis Nielsen 88ac27c49d docs: recommend primary affinity over hybrid pools
Hybrid pools suffer from lower availability when a node goes down,
so we recommend primary affinity instead of hybrid pools.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit 277252a46d)
2021-12-20 07:56:31 +00:00
Daniel Ruiz Capilla be085276db rgw: fix blockOwnerDeletion error
This restores the missing permissions to allow the object controller to
update the finalizers section in the spec. See https://sdk.operatorframework.io/docs/faqs/

Signed-off-by: Daniel Ruiz Capilla <crd1985@gmail.com>
(cherry picked from commit 66cc46220f)
2021-12-17 16:22:54 +00:00
Blaine Gardner 570dc42d52 Merge pull request #9461 from rook/mergify/bp/release-1.8/pr-9453
docs: add jumbo frames note to common issues (backport #9453)
2021-12-17 08:37:07 -07:00
Blaine Gardner 086dc641f8 docs: add jumbo frames note to common issues
Resolves #9320

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
(cherry picked from commit 6c90d66875)
2021-12-17 13:33:40 +00:00
mergify[bot] d8768b325a Merge pull request #9456 from rook/mergify/bp/release-1.8/pr-9189
security: add dry run mode for external cluster script (backport #9189)
2021-12-17 09:10:43 +00:00
subhamkrai 714bd30272 security: add dry run mode for external cluster script
Adding dry run mode for external cluster script.
This will add cli argument `--dry-run`. By default
`dry-run` option will be `False`
which means it will only print something like below.

```
Execute: 'ceph fs ls'
Execute: 'ceph fsid'
Execute: 'ceph quorum_status'
Execute: 'ceph auth get-or-create client.healthchecker mon allow r, allow command quorum_status,
	allow command version mgr allow command config osd allow rwx pool=default.rgw.meta, allow r pool=
	.rgw.root, allow rw pool=default.rgw.control, allow rx pool=default.rgw.log, allow x
	pool=default.rgw.buckets.index'
Execute: 'ceph mgr services'
Execute: 'ceph auth get-or-create client.csi-rbd-node mon profile rbd osd profile rbd'
Execute: 'ceph auth get-or-create client.csi-rbd-provisioner mon profile rbd mgr allow rw osd
	profile rbd'
Execute: 'ceph status'

```

Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit c891ddb57d)
2021-12-17 08:46:20 +00:00
Blaine Gardner f746b502e0 Merge pull request #9451 from BlaineEXE/update-release-1.8-to-v1.8.1
build: update examples and manifests for v1.8.1
v1.8.1
2021-12-16 14:24:51 -07:00
Blaine Gardner d27303a074 build: update examples and manifests for v1.8.1
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-12-16 13:41:52 -07:00
mergify[bot] bd403a89b8 Merge pull request #9449 from rook/mergify/bp/release-1.8/pr-9439
osd: add CAP_MKNOD to PSP (backport #9439)
2021-12-16 18:25:34 +00:00
Yuichiro Ueno 0d3462b163 osd: add CAP_MKNOD to PSP
This commit adds CAP_MKNOD to PodSecurityPolicy to allow OSD-prepare job
creating pods under PSP-enabled Kubernetes cluster.

Signed-off-by: Yuichiro Ueno <ueno@preferred.jp>
(cherry picked from commit bae6351a39)
2021-12-16 17:57:53 +00:00
Travis Nielsen 7b9c691463 Merge pull request #9447 from rook/mergify/bp/release-1.8/pr-9418
mds: Skip sanity check during upgrades to 16.2.7 (backport #9418)
2021-12-16 10:52:08 -07:00
Travis Nielsen 8645d241fa mds: skip sanity check during upgrades to 16.2.7
The mons need to be configured to skip the mds sanity check
during upgrade to 16.2.7 or the mons may crash during that
upgrade.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit 0c19f62df2)
2021-12-16 16:54:34 +00:00
mergify[bot] 37a20ba549 Merge pull request #9437 from rook/mergify/bp/release-1.8/pr-9363
pool: Allow configuration of built-in pools with non-k8s names (backport #9363)
2021-12-15 23:32:08 +00:00
Travis Nielsen 1a6e14f7f5 test: only create replicated pools in ci
Creating an EC pool is causing the CI to hang when the EC
pool is initialized since there aren't enough OSDs to
satisfy the EC parameters.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit 60cc67fed4)
2021-12-15 23:04:34 +00:00
Travis Nielsen d9fc61c3f2 pool: allow configuration of built-in pools with non-k8s names
The built-in pools device_health_metrics and .nfs created by ceph
need to be configured for replicas, failure domain, etc.
To support this, we allow the pool to be created as a CR.
Since K8s does not support underscores in the resource names
the operator must translate this special pool name into
the name expected by ceph.

This also sets the basis for allowing filesystem data
pools to specify the desired pool name instead of requiring
a generated name.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit 7ee9cc9d56)
2021-12-15 23:04:34 +00:00
mergify[bot] ceba7adbf5 Merge pull request #9435 from rook/mergify/bp/release-1.8/pr-9386
mgr: run the watch side car config on /etc/ceph (backport #9386)
2021-12-15 21:25:25 +00:00
Sébastien Han 7b88115d97 mgr: add missing context to the active-watch sidecar
The context was not initialized and thus the configmap fetch will fail
with a nil pointer.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 892c9a211c)
2021-12-15 19:21:03 +00:00
Sébastien Han 108f566eb9 mgr: run active-watch as root and privileged
For now, we must run the container with UID 0 and privileged for
multiple reasons:

* the rook binary writes ceph config to /var/lib/rook which is owned by
  root
* it's difficult to use /etc/ceph since it will conflict with the
  rook-ceph-override configmap AND is also owned by root since it's a
  mounted configmap.
* using /etc/ceph might be possible but has other issues with rook's
  exec package since the ceph config is built from /var/lib/rook

Closes: https://github.com/rook/rook/issues/9385
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 5c1e459a6a)
2021-12-15 19:21:02 +00:00
mergify[bot] 69178d3369 Merge pull request #9428 from rook/mergify/bp/release-1.8/pr-9388
helm: add optional monitoring RBAC to operator chart (backport #9388)
2021-12-14 23:00:05 +00:00
Blaine Gardner 5ca0e752ef helm: add optional monitoring RBAC to operator chart
An older version of the Helm chart always installed RBAC permissions for
enabling monitoring. In an effort to reduce the privileges Rook uses by
default, they were removed. We need to still include the monitoring RBAC
optionally since the change could break some users.

Co-authored-by: Mathieu Parent <mathieu.parent@insee.fr>
Co-authored-by: Blaine Gardner <blaine.gardner@redhat.com>

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
(cherry picked from commit e3be7a30ba)
2021-12-14 22:36:31 +00:00
mergify[bot] df6167d792 Merge pull request #9421 from rook/mergify/bp/release-1.8/pr-9276
pool: add rbd ec pool support in external cluster (backport #9276)
2021-12-14 21:22:08 +00:00
mergify[bot] 74bd6f0712 Merge pull request #9426 from rook/mergify/bp/release-1.8/pr-9296
file: allow to create CephFS dataPools with predefined names (backport #9296)
2021-12-14 18:29:49 +00:00
mergify[bot] 54f3008f3c Merge pull request #9425 from rook/mergify/bp/release-1.8/pr-9423
build: updating tini init command in direct mount toolbox (backport #9423)
2021-12-14 18:25:12 +00:00
Denis Egorenko 07fb393fca file: allow to create CephFS data pools with predefined names
Add an ability to create data pools for CephFS with predefined
names.

Related-Issue: rook#9295
Signed-off-by: Denis Egorenko <degorenko@mirantis.com>
(cherry picked from commit 3ff681e81d)
2021-12-14 18:05:19 +00:00
parth-gr 2a891a8eef build: update the securityContext of direct mount container
update securityContext to runAsUser: 0
so container can run as a root user

Signed-off-by: parth-gr <paarora@redhat.com>
(cherry picked from commit bc355c695e)
2021-12-14 10:57:50 -07:00