Commit Graph
2467 Commits
Author SHA1 Message Date
Travis Nielsen 6bcb53749d Merge pull request #12222 from rook/mergify/bp/release-1.11/pr-12216
monitoring: Skip creating the service monitor for the exporter if monitoring is not enabled (backport #12216)
2023-05-10 15:49:45 -06:00
travisn eac19b36d3 monitoring: no service monitor by default for exporter
The exporter is enabled by default, but the service monitor
can only be enabled if prometheus CRDs are available. The
monitoring.enabled must be set to true as the flag that
prometheus is available and the service monitor should
be created.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit 1b80767877)
2023-05-10 15:57:06 +00:00
avanthakkar 262597b2c2 core: add termination grace period for exporter pods
Shorten the termination time for exporter pod before it
gets deleted to avoid crashing of pod.
Signed-off-by: avanthakkar <avanjohn@gmail.com>
(cherry picked from commit 8a8eb863d0)
2023-05-10 13:58:27 +00:00
travisn 6cbf660e00 monitoring: configurable option to disable prometheus metrics
The prometheus mgr module and ceph exporter can now be optionally
disabled by the monitoring.metricsDisabled setting in the
CephCluster CR. These will not be disabled by default, rather
than the mgr module being disabled by default from v1.11.4.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit 92a0ab37e3)
2023-05-08 17:04:32 +00:00
travisn 28edc07c5b mgr: default to active mgr label
The active and standby labels are updated on the mgr pods
by the mgr sidecar. In the case of a single mgr, there is
not sidecar, so the dashboard and other mgr services were
not available when there was a single mgr. Now the mgr
pod will default to the active mgr status label so that
the single mgr case will succeed. In the case of two mgrs,
the sidecar will immediately update the standby mgr to
remove the active status label.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit 1fa3c5ae18)
2023-05-05 20:52:56 +00:00
Travis Nielsen 96c629d539 Merge pull request #12197 from rook/mergify/bp/release-1.11/pr-12194
core: disable controller runtime metrics server (backport #12194)
2023-05-05 14:51:22 -06:00
Redouane Kachach 5395d17a55 mgr: using dynamic mgr_role label to implement mgr HA
Closes: https://github.com/rook/rook/issues/11844

Signed-off-by: Redouane Kachach <rkachach@redhat.com>
(cherry picked from commit f00bd790a8)
2023-05-05 17:52:23 +00:00
Madhu Rajanna c7cb7c0588 core: disable controller runtime metrics server
As we are not using the controller runtime
metrics we dont even need to start the server
as its just uses extra resouces and its not
much useful.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 6f30700f5e)
2023-05-05 17:45:24 +00:00
Madhu Rajanna b5584ce8a0 core: unset all encryption configuration before setting
if the configuration is already set in the ceph
database, using `ceph config assimilate-conf`
will add the key and value if its missing but
it wont update the value if the key is already
present, To fix this problem we can remove the
key and add all the configurations once again.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 1139cefc94)
2023-05-03 16:56:59 +00:00
Blaine Gardner 52eb79c3bf nfs: pare down config file volume sources
Pare down the available volume sources for NFS config files so that the
CRD isn't unnecessarily huge. This allows us to recommend
`kubectl apply` again in the upgrade doc.

Size of the NFS CRD is reduced by approximately 60%.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
(cherry picked from commit 6500c11d57)
2023-05-02 13:53:55 -06:00
parth-gr 9bc7debca5 mgr: fix ceph dashboard login issue
Dashboard ac-user-create cmd was taking more time
then the usual ceph command to run,
So increased the timeout to run the cmd, and
now dashboard admin user is sucessfully created

Closes: https://github.com/rook/rook/issues/12113
Signed-off-by: parth-gr <paarora@redhat.com>
(cherry picked from commit ed61d25fc3)
2023-05-02 16:29:40 +00:00
sp98 6cb4dab7d2 core: skip OBC and Notification controllers
Skip running Object Bucket and Object bucket notification
controllers based on env variable.

Signed-off-by: sp98 <sapillai@redhat.com>
(cherry picked from commit e87338fbc4)
2023-04-24 16:28:26 +00:00
avanthakkar 7f4f2a4035 core: disable exporter service
Create the exporter service only if exporter pods are created.
Signed-off-by: avanthakkar <avanjohn@gmail.com>
(cherry picked from commit 32b2445ee4)
2023-04-21 23:54:02 +00:00
Sachin Prabhu 2e2925b04c nfs: set nsswitch.conf to lookup local files
When using sssd, the /etc/nsswitch.conf should also include local files
for lookups. This is required when looking up uid 0 and the root user
which are not handled by ldap or other sources.

Closes: https://github.com/rook/rook/issues/11925
Signed-off-by: Sachin Prabhu <sprabhu@redhat.com>
(cherry picked from commit d3636aaf3e)
2023-04-14 16:18:40 +00:00
Sachin Prabhu 06694b0eb0 nfs: do not restrict search domain to localhost
Adding the search domain localhost causes lookup failures.

Many DNS servers have a wildcard entry *.localhost which returns
127.0.0.1. Adding a "search localhost" to resolv.conf appends a
".localhost" for every host lookup for which the DNS server returns
127.0.0.1 which causes failures further down the execution path.

example: with localhost in the search domains
 # ping google.com
PING google.com.localhost (127.0.0.1) 56(84) bytes of data.
64 bytes from localhost (127.0.0.1): icmp_seq=1 ttl=64 time=0.071 ms

Closes: https://github.com/rook/rook/issues/11870
Signed-off-by: Sachin Prabhu <sprabhu@redhat.com>
(cherry picked from commit 08d83a33cd)
2023-04-14 16:18:39 +00:00
avanthakkar 6969b459f7 core: disable exporter for Ceph v17.2.6
The expected ceph version for exporter is changed temporarily because
some regression was detected in Ceph version 17.2.6.
Thus, disabling ceph-exporter for now until all the regression are fixed.

Signed-off-by: avanthakkar <avanjohn@gmail.com>
(cherry picked from commit 3e46522423)
2023-04-12 22:08:37 +00:00
travisn e6e98074ea core: update default image to ceph v17.2.6
With the release of ceph v17.2.6, the examples and the base
image for the operator are updated to pick up the latest
and greatest.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit 609ac91cb1)
2023-04-12 06:15:52 +00:00
sp98 578045291a core: use clusterID for service nslookup
use ClusterID of the k8s cluster while doing nslookup of the
exported mon or osd service IP

Signed-off-by: sp98 <sapillai@redhat.com>
(cherry picked from commit 9e8e85d68b)
2023-04-11 16:50:03 +00:00
zc 1c58c90177 mgr: failed to update the port of mgr's dashboard
if port was used by other daemon,the dashboard will start failed and the status of the ceph will be err,then we update the port to a unused port,the operator can not deal with it

Signed-off-by: zc <zc@zcdeMacBook-Pro.local>
(cherry picked from commit caf7b8c753)
2023-04-06 13:59:53 +00:00
Travis Nielsen 519b02398e Merge pull request #11959 from rook/mergify/bp/release-1.11/pr-11899
csi: make AttachRequired as configurable (backport #11899)
2023-04-04 14:28:55 -06:00
Shachar Sharon 55e36b66f8 nfs: add support for nfs-ganesha metrics monitoring
NFS-Ganesha (as of V5-dev.2 [1]) supports Prometheus monitoring from
within the NFS server itself. It provides metrics for both connected
clients and active exports, via TCP port 9587. Expose those metrics via
existing nfs k8s-service.

[1] https://github.com/nfs-ganesha/nfs-ganesha/commit/b6c59df5a0b8a3ae5b2a87446f8906cb321ee026

Signed-off-by: Shachar Sharon <ssharon@redhat.com>
(cherry picked from commit 7b28f1de05)
2023-04-04 15:37:56 +00:00
Travis Nielsen 4f9b1e835e Merge pull request #12014 from rook/mergify/bp/release-1.11/pr-11980
mgr: disable the prometheus module by crds (backport #11980)
2023-04-03 16:49:53 -06:00
Jiffin Tony Thottan 5e1c733cac object: check obc provisioner for bucket notification
obc-label-controller needs to check only obc provisioned by Rook operator.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
(cherry picked from commit 01a3dd0baf)
2023-03-31 21:14:46 +00:00
xiaobaowen 6e171c3218 mgr: disable the prometheus module by crds
Signed-off-by: xiaobaowen <xiaobaowen@deeproute.ai>
(cherry picked from commit e7254c2a1b)
2023-03-31 14:17:33 +00:00
travisn e13bdd0f8f csi: ipv6 compatibility for requiring msgr2
The msgr2 conversion assumed the endpoints were formatted
with a single :, which is not compatible with ipv6.
Now if the endpoint ends with the v1 port, it will
simply update the prefix to v2.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit bbfba5425f)
2023-03-29 15:16:09 +00:00
sp98 8dccb4fcc8 mon: remove condition to use 6790 mon port
PR #3143 added check to retain 6790 port for mons. Now
we can remove this check in Rook 1.11.

Signed-off-by: sp98 <sapillai@redhat.com>
(cherry picked from commit 755135582f)
2023-03-23 16:20:09 +00:00
Madhu Rajanna 3abc7f9705 csi: make AttachRequired as configurable
adding a option to make AttachRequired field
as configurable and added a comment to explain
the consequences of changing the default value

resolves: #11805

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 4c710de791)
2023-03-22 13:59:50 +00:00
Madhu Rajanna f3afcdf697 csi: remove default-fstype for cephfs
we dont need to have fstype for cephfs
pvc, removing the unwanted argument
for cephfs.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 3017d563f2)
2023-03-22 13:59:49 +00:00
Madhu Rajanna c6e48823af nfs: add csi-attacher to NFS provisioner
Add attacher sidecar to NFS provisioner pod
to avoid mounting RWO volumes on two nodes

details: https://github.com/rook/rook/issues/10692

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 4bdab21db0)
2023-03-22 13:59:49 +00:00
Travis Nielsen e311df61c7 Merge pull request #11953 from rook/mergify/bp/release-1.11/pr-11950
core: remove ceph-conf-dir volume mount from exporter (backport #11950)
2023-03-21 13:10:16 -06:00
avanthakkar 14bf3fd4e1 core: remove ceph-conf-dir volume mount from exporter
Remove the `ceph-conf-dir` volume and volume mount from exporter
as it's no more required to spin up exporter daemon

Signed-off-by: avanthakkar <avanjohn@gmail.com>
(cherry picked from commit 1a000673a4)
2023-03-21 18:25:19 +00:00
travisn 44f6455247 core: set key rotation default in code instead of crds
The defaults in CRDs cause an update and trigger a new
reconcile if the value is not set. For the key rotation
setting, the default was only being updated when the kms
feature was enabled. This update was causing the reconcile
to fail in the kms tests. With the default now in code,
the default can remain empty and no cr update will trigger
a new reconcile unexpectedly.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit cd94ed7ddc)
2023-03-21 18:16:43 +00:00
Travis Nielsen 77b98c496b Merge pull request #11939 from rook/mergify/bp/release-1.11/pr-11928
operator: use msgr2 if compression is enabled (backport #11928)
2023-03-20 13:28:19 -06:00
Travis Nielsen 367c39676e Merge pull request #11912 from rook/mergify/bp/release-1.11/pr-11823
osd: validate and remove duplicate topology (backport #11823)
2023-03-20 12:42:30 -06:00
Thomas Way 229bd17f79 operator: log ceph error in monstore
Closes: #11795
Signed-off-by: Thomas Way <thomas@6f.io>
(cherry picked from commit ef60650f09)
2023-03-20 18:25:24 +00:00
Thomas Way b859b4b3d2 operator: use msgr2 if compression is enabled
Closes: #11795
Signed-off-by: Thomas Way <thomas@6f.io>
(cherry picked from commit 891fdb3f77)
2023-03-20 18:25:24 +00:00
root 0a972a0850 rgw: allow the rgw dashboard to be disabled
The rgw dashboard can be disabled by the setting in the
CephObjectStore `gateway.dashboardEnabled` if set to false.

Signed-off-by: xiaobaowen <xiaobaowen@deeproute.ai>
(cherry picked from commit 253d4123f6)
2023-03-17 14:19:29 +00:00
parth-gr ec74ca2b4f ci: update golangci-lint version as it fails for some k8s version in 1.10
Closes: https://github.com/rook/rook/issues/11896

Signed-off-by: parth-gr <paarora@redhat.com>
(cherry picked from commit 8e317ee074)
2023-03-16 16:52:46 +00:00
parth-gr e2b2c9958a osd: remove deprecated k8s topology label
Signed-off-by: parth-gr <paarora@redhat.com>
(cherry picked from commit 89764f0371)
2023-03-15 18:40:01 +00:00
parth-gr 80919e67b9 osd: validate and remove duplicate topology
remove the duplicate topology added to the node,
and the priority to keep duplicate would be give to
the one who is lowest in the hierarchy

Closes: https://github.com/rook/rook/issues/11800

Signed-off-by: parth-gr <paarora@redhat.com>
(cherry picked from commit c22f5f36cb)
2023-03-15 18:40:01 +00:00
Richard Bateman f9f72c326b nfs: add hostNetwork option for the ganesha daemon
Add a hostNetwork option for a Ganesha server.
This allows you to use host networking for the cluster but still
use regular pod networking for NFS Ganesha servers

Signed-off-by: Richard Bateman <taxilian@gmail.com>
(cherry picked from commit 0ca9da23e8)
2023-03-13 18:14:57 +00:00
travisn 12d79edd1d csi: update port to 3300 if msgr2 is required
When msgr2 is required, ensure the mon endpoints passed to
the csi configmap are on port 3300. The mons will be
listening on both 6789 and 3300. Existing volumes can
continue using port 6789 while new volumes will use
port 3300.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit 0484a3973f)
2023-03-10 21:51:55 +00:00
avanthakkar f8b4a4e568 core: add missing labels in exporter deployment
Adding missing `ceph_daemon_id` & `rook_cluster` labels to the exporter deployment.
Signed-off-by: avanthakkar <avanjohn@gmail.com>
(cherry picked from commit e235e01fa1)
2023-03-09 17:26:43 +00:00
Rakshith R 30692ca9c8 osd: add capability to reconcile key rotation cron jobs
This commits adds code to reconcile key rotation cron jobs.

Signed-off-by: Rakshith R <rar@redhat.com>
(cherry picked from commit f39a32fcdb)
2023-03-08 16:37:33 +00:00
Rakshith R 65007124ab osd: add util function to create key rotation cron job
This commit adds util function to create key rotation cron job
such as getKeyRotationContainer, getKeyRotationCronPodTemplateSpec
and makeKeyRotationCronJob.

Signed-off-by: Rakshith R <rar@redhat.com>
(cherry picked from commit ef38aea2a4)
2023-03-08 16:37:33 +00:00
Rakshith R 542906be28 osd: add rotate-key functionality to rook's key-management cmd
This commit adds functionality to be able to rotate
key encryption key of encrypted PVC backed OSDs.
Necessary changes such as adding update functionality
to kms and rbac changes are made as well.

Signed-off-by: Rakshith R <rar@redhat.com>
(cherry picked from commit 71e011f731)
2023-03-08 16:37:32 +00:00
Travis Nielsen f6b3d53f5a Merge pull request #11849 from rook/mergify/bp/release-1.11/pr-11848
core: Add env var to exporter for ceph config (backport #11848)
2023-03-07 15:02:56 -07:00
avanthakkar 6accfb6380 core: add env var to exporter for ceph config
The exporter requires the mon config and keyring.
Use the CEPH_ARGS env var to specify the config
instead of expecting a ceph.conf to be generated
by another component on the host path.

Co-Authored-By: Travis Nielsen <tnielsen@redhat.com>
Signed-off-by: Avan Thakkar <athakkar@redhat.com>
(cherry picked from commit b6013d9b11)
2023-03-07 21:22:17 +00:00
Redouane Kachach eaf09ad77a Revert "mgr: use k8s readiness probe to implement mgr HA"
This reverts commit dc76f81fea.

Signed-off-by: Redouane Kachach <rkachach@redhat.com>
(cherry picked from commit 0ae7867dd1)
2023-03-07 18:28:25 +00:00
Redouane Kachach 9a3e5c4e94 Revert "mgr: remove mgr sidecar"
This reverts commit ff75ec96b7.

Signed-off-by: Redouane Kachach <rkachach@redhat.com>
(cherry picked from commit 456a0c328c)
2023-03-07 18:28:25 +00:00