Commit Graph
2236 Commits
Author SHA1 Message Date
Sébastien Han bcd76bf46d ceph: run obc requests with debug
Use debug log to all the s3 calls so it's either to debug. Also, it's
not so verbose.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-26 15:27:49 +02:00
Sébastien Han 8668e1f69c ceph: correctly return if multus was applied
We must only return if multus got configured successfully.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-25 09:54:18 +02:00
Jared Watts 06ab07be8b Merge pull request #5863 from prksu/nfs-provisioner
nfs: nfs provisioner controlled by operator
2020-08-24 16:26:23 -07:00
Sébastien Han d89b06bcf2 Merge pull request #6137 from thotz/cephobjectstorelogging
ceph: use proper log functions in object package
2020-08-24 10:46:21 +02:00
Ahmad Nurus S 5cc2ceda2d nfs: make provisioner as sidecar of nfs server
Signed-off-by: Ahmad Nurus S <prksu.sh@gmail.com>
2020-08-21 16:40:33 +07:00
Jiffin Tony Thottan 7413485b8a ceph: use proper log functions in object package
There is incorrect usage of log functions in the object directory, changing those instances

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-08-21 12:39:53 +05:30
rohan47 8c4ede1edc ceph: added support for multus for csi
CSI pods now utilize multus networking and connect to public
network specified in the CephCluster CR.

Closes: https://github.com/rook/rook/issues/5356
Signed-off-by: rohan47 <rohgupta@redhat.com>
2020-08-20 18:25:09 +05:30
Sébastien Han ee893eda5e Merge pull request #6126 from leseb/encryption-expansion-pvc
ceph: add expansion support for encrypted osd on pvc
2020-08-19 21:40:46 +02:00
Travis Nielsen ce92249725 ceph: continue with memory limits below min settings
The operator will now allow the resource limits to be applied below the
recommended minimums. In small clusters, even the recommended minimums
may not be necessary. A warning is still printed to the operator log,
but we allow the configuration to continue.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-19 11:07:16 -06:00
Sébastien Han 321e8e0b5a ceph: add more pvc dep unit tests
Added more unit tests scenario for osd on pvc such as:

* block/db/wal
* block encryption
* block/db encryption
* block/db/wal encryption

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-19 18:45:31 +02:00
Sébastien Han aa5362d48d Merge pull request #6120 from leseb/fix-5996
ceph: do not use realPath for osd on pvc
2020-08-19 17:33:46 +02:00
Sébastien Han 803462ceca ceph: add encrypted block status container
This init container displays the status of the encrypted pvc. This can
be really useful for debugging purpose.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-19 17:13:46 +02:00
Sébastien Han cb81ee7d1d ceph: add pvc expansion support for encrypted osds
We now support the expansion of encrypted osds. We added a new init
container to run "cryptsetup resize".

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-19 17:13:46 +02:00
Sébastien Han 3f42db5ce0 ceph: support osd deployment update on encrypted pvc
If the deployment spec was updated or restarted, the "encryption-open"
init container would fail to open the device since it was already
opened on the node.
Because they are no reliable post stop hook on Kubernetes, the trick is
to use a small bash init container.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-19 17:13:25 +02:00
Sébastien Han d5b1e89ce2 Merge pull request #6118 from travisn/osd-prepare-resources
ceph: Set the OSD prepare resources
2020-08-19 15:38:06 +02:00
Sébastien Han 944d8cb209 ceph: do not use realPath for osd on pvc
It is fine to use /mnt/set1-data-0-k47mc, it looks like I thought there
was an issue with udev but there is none...

Closes: https://github.com/rook/rook/issues/5996
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-19 14:39:55 +02:00
Sébastien Han 6d6449b5af Merge pull request #6103 from travisn/osd-prepare-placement
ceph: Separate placement for osd prepare jobs from osd daemons
2020-08-19 14:04:03 +02:00
Travis Nielsen 18d39d909e ceph: set the osd prepare resources
The osd prepare resources were only being set on the main container
while the init containers either did not have resources set, or were
inheriting the resource settings from the device set resources for osds.
Now the osd prepare resources will be consistently set based on the
prepareosd resources in the main section of the cluster CR.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-18 22:58:26 -06:00
Travis Nielsen 26f59c0382 ceph: remove redundant check for encrypted osds
This is simply a code simplification to remove an extra check for
whether the OSDs are encrypted. There is no change in functionality.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-18 22:50:32 -06:00
Travis Nielsen 0ffa0348b5 ceph: separate placement for osd prepare jobs from osd daemons
The osd prepare jobs and osd daemons may have different placement
requirements. In particular, the topology spread constraints
or pod anti-affinity should only work on either the prepare job or
osd daemon, but does not work effectively on both types at the same
time. Therefore, we split out the osd prepare placement to be separate
from the osd daemon placement. If the osd prepare placement is not set
the operator will fall back to the osd daemon placement for
backward compatibility.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-18 15:24:04 -06:00
Travis Nielsen cb3db54187 Merge pull request #6072 from alimaredia/object-multisite-testing
ceph: object realm controller unit tests
2020-08-18 14:58:38 -06:00
Ali Maredia 5b339cf791 ceph: object realm controller unit tests
Add unit tests for the ceph object realm
controller.

Signed-off-by: Ali Maredia <amaredia@redhat.com>
2020-08-18 15:15:14 -04:00
Travis Nielsen b4db31033b Merge pull request #6107 from leseb/fix-6078
ceph: check rootfs for lvm too
2020-08-18 11:52:36 -06:00
Sébastien Han 713d3ecace ceph: check rootfs for lvm too
On rancher OS, the lvm binary is in a different location and cannot be
accessed via the root namespace. So we now also check directly from
/rootfs. When using nsenter, itbreaks out of container's mount
namespace and executes an lvm command.

Closes: https://github.com/rook/rook/issues/6078
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-18 17:04:56 +02:00
Sébastien Han adab0e07e5 Merge pull request #6059 from leseb/lvm-list
ceph: improve callCephVolume() for list and prepare
2020-08-18 13:30:49 +02:00
Travis Nielsen 98db380237 Merge pull request #6062 from leseb/wal-encryption
ceph: add support for wal encrypted device on pvc
2020-08-17 14:07:40 -06:00
Alexander Trost 788709f67a Merge pull request #6082 from cloudical-io/additional_user_labels
core: added labels to rook v1
2020-08-17 18:18:42 +02:00
Sébastien Han b4208f4a55 Merge pull request #6090 from leseb/fix-rgw-healthcheck
ceph: fix object store healthcheck yaml
2020-08-17 17:32:15 +02:00
Sébastien Han dbac1c11d0 ceph: improve callCephVolume() for list and prepare
callCephVolume() was using our exec interface with CombinedOutput which
means return both stdout and stderr. This is fine when preparing OSDs
since we read back the stdout and also want any errors if any (stderr).
However when listing OSD we only want the output since ceph-volume tends
to mix stdout and stderr in the output and does not always silence the
warning types/harmless errors. If the listing has a problem we report it
by printing the ceph-volume log file.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-17 12:43:43 +02:00
Alexander Trost e990841206 docs: added rbd mirror crd documentation
This adds some basic RBDMirror CRD documentation and fixes the types.go
comments accordingly.

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2020-08-17 11:55:42 +02:00
Alexander Trost 5225a59278 core: added labels to rook v1
This adds Labels and LabelsSpec to the rook.io/v1 apis pkg.

Related to #6050

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2020-08-17 10:57:48 +02:00
Sébastien Han 7859bf5c4b ceph: fix object store healthcheck yaml
Reverting some of
https://github.com/rook/rook/commit/23f0ac7f9c7157383bc860b259c1964df46454c1
to re-use `bucket` for the healthcheck configuration.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-17 10:25:49 +02:00
Travis Nielsen 7481993959 Merge pull request #6017 from humblec/ceph-csi-snapshotter
Add/update ceph csi snapshotter rbac and sidecar deployments
2020-08-13 12:32:35 -06:00
Humble Chirammal 97a3283099 ceph: add snapshot create/delete and restore doc for cephfs
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2020-08-13 22:17:01 +05:30
Sébastien Han efa7ba9d84 Merge pull request #5986 from subhamkrai/secureport
ceph: disable object store port when secureport specified
2020-08-13 17:25:57 +02:00
Sébastien Han 1390335f98 Merge pull request #6063 from leseb/fix-crash-collector
ceph: check for gone node on crash collector
2020-08-13 17:02:30 +02:00
Sébastien Han b3e7971953 Merge pull request #6060 from leseb/fix-6057
ceph: use different command for lvm2 presence
2020-08-13 16:30:30 +02:00
Travis Nielsen 1624c58fea Merge pull request #6056 from travisn/annotations-append
cassandra: Initialize merged annotations when empty
2020-08-13 07:53:05 -06:00
Travis Nielsen 306c5425de Merge pull request #6033 from Madhu-1/check-channel
ceph: check channel is open before closing
2020-08-13 07:49:20 -06:00
Sébastien Han 4f9435d226 ceph: add support for wal encrypted device on pvc
Similar to https://github.com/rook/rook/pull/5977 but for wal devices.
So if a cluster is deployed on PVC and wal devices, those will be
encrypted as well.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-13 15:42:40 +02:00
Sébastien Han acc5ba1a6b ceph: check for gone node on crash collector
If a node is gone, we try to remove crash collector deployments so they
don't stay stale or pending. We must ensure the node is gone and not
just return an error even if we successfully deployment the orphan
deployment.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-13 14:16:31 +02:00
Madhu Rajanna 52c2ac3620 ceph: check channel is open before closing
to avoid operator panic we should check the channel
is open before closing as a safety measure.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-13 16:59:28 +05:30
Sébastien Han db71d38a5e ceph: use different command for lvm2 presence
Older versions of lvm do not implement "--help" but "help" only where
new versions support both so let's use "help" so the check works for all
the versions.

Closes: https://github.com/rook/rook/issues/6057
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-13 10:03:49 +02:00
Sébastien Han dd2166b105 ceph: return cv debug logs
So that the operator can print it.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-12 22:24:14 +02:00
Sébastien Han f75a6e9d93 ceph: do not list on empty device
If the device is empty let's not use an empty space as an argument for
the c-v call.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-12 22:24:14 +02:00
Sébastien Han 9738c2ba21 ceph: use callCephVolume() to list osds
Small refactor to use the common function helper callCephVolume() to
build ceph-volume arguments.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-12 22:24:14 +02:00
Sébastien Han a91c96cb47 ceph: add support for encrypted metadata pvc
Now the metadata pvc will also be encrypted if the storageClassDeviceSet
has the "encrypted" flag turned on.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-12 22:24:11 +02:00
Travis Nielsen 820852268d core: move annotations helper into test code
The helper to convert annotations to a string map is not needed in the
production code, so it is moved to the unit tests.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-12 14:00:29 -06:00
Travis Nielsen b3355454dc core: initialize merged annotations when empty
Applying annotations was crashing when there were no annotations in the
original map. Now the map is initialized when no annotations are set
in the original map.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-12 13:58:25 -06:00
Humble Chirammal 903fcdb778 ceph: update csi image version to 3.1.0 in spec.go
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2020-08-12 22:39:48 +05:30