The CRD watcher has been replaced by the new controller-runtime
framework.
This brings robustness in our operator, meaning that any resources that
are modified will be reconciled into the desired state.
Closes: https://github.com/rook/rook/issues/4937
Signed-off-by: Sébastien Han <seb@redhat.com>
The pool size for cephObjectStore (object.yaml), was not getting updated in the cluster upon changing.The reason being that there was an "else" case missing to update the replica size if the pools already existed. That will fix this issue.
Signed-off-by: RAJAT SINGH <rajasing@redhat.com>
As part of the transition to support Ceph release **as of** Nautilus, we
left over that portion of code.
We don't need it anymore.
Signed-off-by: Sébastien Han <seb@redhat.com>
Current YugabyteDB operator code creates Master and TServer pods without any resource requests/limits (specifically CPU and memory).
This causes the operator to run into soft/hard memory limit issue. The fix adds recommended resource requests and limits as defaults to the pods it creates.
Closes: https://github.com/yugabyte/yugabyte-db/issues/3884
Signed-off-by: Sameer Kulkarni <samkulkarni20@gmail.com>
The OSD needs to talk to the udev socket to get information about a device.
like serial, vendor etc. So that it can populate the output of:
`ceph osd metadata $n` correctly.
Signed-off-by: Sébastien Han <seb@redhat.com>
The OSDs pick up on several topology labels for CRUSH hierarchy.
The GA label topology.kubernetes.io was partially implemented, but
not picked up by the OSDs. Now the OSDs will pick up both the topology
labels from pre-1.17 such as failure-domain.beta.kubernetes.io/zone
and topology.kubernetes.io/zone.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
We have seen cases where the pool is already gone and a deletion
timestamp is set on the CephBlockPool CR.
Signed-off-by: Sébastien Han <seb@redhat.com>
Now, the CephObjectStoreUser CRD is managed with the controller-runtime.
So the watcher is outside of the main controller reconciliation loop of
CephCluster which brings numerous benefit such as:
* having its own reconciliation loop
* won't block anything from the main CephCluster controller loop
* fast than waiting for CephCluster loop to completion
Partially close: https://github.com/rook/rook/issues/1981
Signed-off-by: Sébastien Han <seb@redhat.com>
In the cluster CR the nodes element will be ignored under storage when
useAllNodes is true. The nodes will only be applied when useAllNodes is
false. It is a common usability problem that users can't figure out
why their nodes are not configured. At least this log entry can give
them a clue.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
The osd prepare job is now always working with devices so
we always need to mount /dev and run privileged. There is
no scenario for not mounting /dev since filestore support
was removed.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
The communication between the operator and OSD prepare job
is done through updates to the configmap. If an update fails
to the configmap, we are anyway going to need to check the logs
for failure. So let's just log the error and make a best effort
to continue the orchestration. If the failure was temporary,
the next update to the status would succeed and likely continue
working as expected.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
Changed back the status.State to the exact way it was implemented on the ceph cluster. Added the States as a Constant and used that constant to call the status.State.
Signed-off-by: Nizamudeen <nia@redhat.com>
With a finalizer on the pools, the pools were not always being purged
during the integration tests. Now the multicluster suite will ensure
its pool is purged.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
Most of the OLM UI currently uses status.Phase to show the status of the cluster and in some case it uses status.State to show the information.
Having them both for now and slowly deprecating the uses of status.state is the most appropriate way to do now.
Signed-off-by: Nizamudeen <nia@redhat.com>
As a safeguard against the error case described in #4934, this
change sets BlockOwnerDeletion to false on the ownerReference
of all Ceph CSI resources.
Signed-off-by: Elise Gafford <egafford@redhat.com>
Now, the CephBlockPool CRD is managed with the controller-runtime.
So the watcher is outside of the main controller reconciliation loop of
CephCluster which brings numerous benefit such as:
* having its own reconciliation loop
* won't block anything from the main CephCluster controller loop
* fast than waiting for CephCluster loop to completion
Partially close: https://github.com/rook/rook/issues/1981
Signed-off-by: Sébastien Han <seb@redhat.com>
Checks the version of the configured ceph-csi image while starting the operator. The operator will fail if the image is not supported.
Added an additional parameter to operator to disable the check e.g. to test not yet supported csi images.
Signed-off-by: Stefan Haas <shaas@suse.com>
Prior attempts to delete CSI drivers using owner references to the
Ceph ConfigMap resulted in garbage collection of the driver
resources as described in rook#4590. This patch manually deletes these
resources by name as a stopgap to provide an appropriate user
experience while the team investigates this issue further.
Resolves: rook#4824
Signed-off-by: Elise Gafford <egafford@redhat.com>
This commit will add a phase and also a condition to display a Failed status on the external rook-ceph cluster if its failed to establish a connection.
Signed-off-by: Nizamudeen <nia@redhat.com>
The rook types used across the storage providers moved from the v1alpha2
package to the v1 package. This commit points the packages at their new
location. Implementation is expected to remain unchanged.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
As of Octopus, Ceph will prevent you from creating a pool with a
replica size of 1. Allowing such pool could lead to data loss, so enable
the new option: requireSafeReplicaSize: false if you are **ABSOLUTELY**
certain that is what you want.
Closes: https://github.com/rook/rook/issues/4889
Signed-off-by: Sébastien Han <seb@redhat.com>
Do not use the Rook binary to generate minimal config for Ceph's
NFS-Ganesha pods. Instead, `cat` the minimal file in an init container
using the Ceph container.
Signed-off-by: Blaine Gardner <blaine.gardner@suse.com>