Commit Graph
7961 Commits
Author SHA1 Message Date
Sébastien Han 6423e3838e Merge pull request #6405 from Madhu-1/update-mirror-doc
ceph: fix example rbdMirrorBootstrapPeerSecretName in mirror doc
2020-10-08 10:46:28 +02:00
Sébastien Han 35d524c7ed Merge pull request #6322 from alimaredia/object-zone-unit-tests
ceph: add unit tests for object/zone
2020-10-08 10:24:05 +02:00
Madhu Rajanna 0faa076859 ceph: fix example rbdMirrorBootstrapPeerSecretName in mirror doc
The rbdMirrorBootstrapPeerSecretName always starts with
pool-peer-token- when we pool is created with mirroring
enabled.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-10-08 13:51:38 +05:30
Sébastien Han 7c8de8fc7c Merge pull request #6402 from travisn/graduated-status
docs: Add a badge for graduation status
2020-10-08 09:18:32 +02:00
Travis Nielsen 3bbd14efb6 docs: add a badge for graduation status
To more quickly show the graduation status on the main readme,
we add a badge that shows rook is graduated.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-10-07 17:08:58 -06:00
Ali Maredia b62a50309f ceph: add unit tests for object/zone
Add unit tests for CephObjectZone controller.

Signed-off-by: Ali Maredia <amaredia@redhat.com>
2020-10-07 18:52:44 -04:00
Sébastien Han b49b6393bc ceph: tune osd tcmalloc thread cache bytes
We can now tune the value of TCMALLOC_MAX_TOTAL_THREAD_CACHE_BYTES by
setting an annotation on the CephCluster CRD like so:

```
annotation:
  osd:
    TCMALLOC_MAX_TOTAL_THREAD_CACHE_BYTES: "134217728"
```

Alternatively, if nothing is specified Rook will read the value of the
file `/etc/sysconfig/ceph`.

Closes: https://github.com/rook/rook/issues/6134
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-10-07 18:49:18 +02:00
Sébastien Han 9b980d136f ceph: log stderr in error when exec with output file
In order to properly debug errors, we need to merge stderr inside the
`err` reported so that we don't only see the stdout.
We were doing this when executing without file output, doing the same
for the output file.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-10-07 14:47:09 +02:00
Sébastien Han c95eaea1e0 Merge pull request #6388 from cybozu-go/ci-ceph-fix-intermittent-failure-of-flexsuite
ci: fix an intermittent failure of ceph flex suite
2020-10-07 13:45:28 +02:00
Satoru Takeuchi 9cd42a17a4 ci: fix an intermittent failure of ceph flex suite
Sometimes CephFlexSuite fails with the following backtrace.

```
--- FAIL: TestCephFlexSuite (584.14s)
    --- PASS: TestCephFlexSuite/TestBlockStorageMountUnMountForDifferentAccessModes (163.66s)
    --- PASS: TestCephFlexSuite/TestBlockStorageMountUnMountForStatefulSets (83.21s)
    --- FAIL: TestCephFlexSuite/TestFileSystem (119.51s)
        ceph_base_file_test.go:487:
                Error Trace:    ceph_base_file_test.go:487
                                                        ceph_base_file_test.go:265
                                                        ceph_flex_test.go:113
                Error:          Expected nil, but got: &errors.errorString{s:"kubectl exec command bash failed on pod rook-ceph-tools in namespace flex-ns. Failed to run: kubectl [exec -n flex-ns rook-ceph-tools -- bash -c mount -t ceph -o mds_namespace=smoke-test-fs,name=admin,secret=$(grep key /etc/ceph/keyring | awk '{print $3}') $(grep mon_host /etc/ceph/ceph.conf | awk '{print $3}'):/ /tmp/testrook] : exit status 32"}
                Test:           TestCephFlexSuite/TestFileSystem
```

It's due to insufficient retry of mount.

There is only one difference between CI logs of both "PASS" cases and "FAIL" cases.

The log of PASS cases:
```
2020-09-30 21:47:03.369019 D | exec: Running command: kubectl exec -n flex-ns rook-ceph-tools -- bash -c mount -t ceph -o mds_namespace=smoke-test-fs,name=admin,secret=$(grep key /etc/ceph/keyring | awk '{print $3}') $(grep mon_host /etc/ceph/ceph.conf | awk '{print $3}'):/ /tmp/testrook
2020-09-30 21:47:03.679359 D | exec: Running command: kubectl exec -n flex-ns rook-ceph-tools -- mkdir -p /tmp/testrook/foo
```

The log of FAIL cases:
```
2020-09-30 21:49:21.591702 D | exec: Running command: kubectl exec -n flex-ns rook-ceph-tools -- bash -c mount -t ceph -o mds_namespace=smoke-test-fs,name=admin,secret=$(grep key /etc/ceph/keyring | awk '{print $3}') $(grep mon_host /etc/ceph/ceph.conf | awk '{print $3}'):/ /tmp/testrook
2020-09-30 21:49:36.592161 I | exec: timeout waiting for process kubectl to return. Sending interrupt signal to the process
2020-09-30 21:49:40.355420 E | utils: Failed to execute: kubectl [exec -n flex-ns rook-ceph-tools -- bash -c mount -t ceph -o mds_namespace=smoke-test-fs,name=admin,secret=$(grep key /etc/ceph/keyring | awk '{print $3}') $(grep mon_host /etc/ceph/ceph.conf | awk '{print $3}'):/ /tmp/testrook] : timeout waiting for the command kubectl to return.
```

Everything looks fine before showing the above-mentioned error in FAIL cases.
In addition, this problem hasn't happened in high-spec local machine
over 10 times.

Related issue: 6358

Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
2020-10-07 09:36:44 +00:00
Travis Nielsen 697b03146b Merge pull request #6383 from subhamkrai/update-tunefast
ceph: remove suffix _sdd for tuneFastDeviceClass
2020-10-06 16:13:43 -06:00
Travis Nielsen 5a267ad381 Merge pull request #6386 from cloudical-io/readme_badges
docs: updated badge url
2020-10-06 13:20:07 -06:00
Alexander Trost 41a2f7b6ad docs: updated badge url
This updates the badge image url and removes one differently styled
badge design param.

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2020-10-06 20:57:53 +02:00
Travis Nielsen 5b1a263282 Merge pull request #6377 from thotz/obcdocupdate
docs: update obc documentation
2020-10-06 11:14:53 -06:00
Travis Nielsen bf68278b9f Merge pull request #6382 from sabbot/final-edgefs-commit
edgefs: EdgeFS deprecation documentation fix
2020-10-06 11:01:53 -06:00
subhamkrai 364df7793f ceph: remove suffix _sdd for tuneFastDeviceClass
this commit remove _ssd  suffix from
tuneFastDeviceClass setting as with _ssd
won't affect disk.

Signed-off-by: subhamkrai <srai@redhat.com>
2020-10-06 20:54:52 +05:30
Travis Nielsen 69049828ee Merge pull request #6191 from Obleskar/patch-3
edgefs: docs: note nfs service name restrictions
2020-10-06 09:19:18 -06:00
Anton Skriptsov d9ba495425 edgefs: edgefs deprecation documentation fix
Update EdgeFS status to 'Deprecated'

Signed-off-by: Anton Skriptsov <anton.skriptsov@gmail.com>
2020-10-06 17:38:47 +03:00
Travis Nielsen 3eddcf5477 Merge pull request #6283 from sp98/rook-IPv6-support
ceph: support IPv6 single-stack
2020-10-06 07:46:25 -06:00
Jiffin Tony Thottan e837082de7 docs: update obc documentation
Remove wrong information from OBC CRD example

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-10-06 13:32:12 +05:30
Travis Nielsen 95358bc659 Merge pull request #6369 from raghavendra-talur/rtalur-master-fix-crash
ceph: prevent closing of channel more than once
2020-10-05 13:04:12 -06:00
Raghavendra TalurandTravis Nielsen 0c21abd535 ceph: prevent closing of channel more than once
Once we close the channel for the monitoring daemons, we update the
monitoring status so as to not call them again.

This is to prevent "close of closed channel" panic.

Co-authored-by: Travis Nielsen <tnielsen@redhat.com>
Signed-off-by: Nitin Goyal <nigoyal@redhat.com>
Signed-off-by: Raghavendra Talur <raghavendra.talur@gmail.com>
2020-10-05 22:14:16 +05:30
Travis Nielsen 6557cb1bc8 Merge pull request #6303 from subhamkrai/tunefast-deviceclass
ceph: tune fast device class for OSD on PVC in the Azure
2020-10-05 10:18:41 -06:00
Travis Nielsen 32483c72d8 Merge pull request #6366 from subhamkrai/test-flex
ceph: flex test failing in CI
2020-10-05 10:18:01 -06:00
subhamkrai c2c59ec47b ceph: tune fast device class for OSD on PVC in the Azure
on Azure, all SSDs are reporting as a rotational disk.
This commit will add `tuneFastDeviceClass` flag which will
tune for an SSD even if the cloud provider is reporting
rotational. We have a flag `tuneDeviceClass`
which works vice-versa.

Signed-off-by: subhamkrai <srai@redhat.com>
2020-10-05 20:19:55 +05:30
Sébastien Han 778e01aab2 Merge pull request #6367 from leseb/encryption-dev-lost
ceph: check underlaying block status
2020-10-05 16:47:18 +02:00
subhamkrai 5be7f0ae07 ceph: flex test failing in CI
this commit will add error not found condition
check before assert delete on PVC and
statefulset due to whch flex test was failing.

Signed-off-by: subhamkrai <srai@redhat.com>
2020-10-05 20:00:01 +05:30
Sébastien Han 95ac992e48 ceph: check underlaying block status
During the initialization encrypted OSD initialization sequence, we check
for the presence of the encrypted container. If it exists we don't try
  to open it again since this will result in an error.
However, there is another case we need to handle, when the underlying
device is gone. For instance, if the pod/PV couple was drained and move
back, living the orphan dm. Once the pod comes back, the dm is still
present and perfectly matches. Unfortunately, the underlying disk is
different and thus the dm must be removed and the disk re-opened.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-10-05 15:47:29 +02:00
Sébastien Han f0748f6425 Merge pull request #6331 from dungdm93/master
docs: fix typo in ObjectMultisite docs
2020-10-05 14:05:22 +02:00
Travis Nielsen 3e7e31fd3e Merge pull request #6359 from travisn/skip-smoke-suite-k8s-1.11
ceph: Skip smoke suite on k8s 1.11
2020-10-02 09:37:16 -06:00
Travis Nielsen c13d1edf22 ceph: skip smoke suite on k8s 1.11
The smoke suite relies on the csi driver for all the file and block
tests. In the release branch on k8s 1.11 we only need to run the
flex suite and can skip the smoke suite.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-10-01 15:57:00 -06:00
Santosh Pillai 70c5f70701 ceph: support IPv6 single-stack for ceph
Add --ms-bind-ipv6 true args to mom, osd, mgr, object, mds, rbd daemons.

Signed-off-by: Santosh Pillai <sapillai@redhat.com>
2020-10-02 01:03:03 +05:30
Travis Nielsen d5c8be2518 Merge pull request #6352 from Strangerxxx/master
ceph: allow manipulations on monitoring.coreos.com resources to operator within helm chart
2020-10-01 11:45:54 -06:00
Travis Nielsen cebcf0a04e Merge pull request #6353 from leseb/fix-obc-external
ceph: fix obc upgrade from 1.3 to 1.4 external cluster
2020-10-01 07:37:35 -06:00
Sébastien Han 7b8f601c4b Merge pull request #6317 from subhamkrai/golangci-errcheck
Handle golangci-lint linter errcheck error
2020-10-01 12:26:11 +02:00
Sébastien Han d2d1da5970 ceph: fix obc upgrade from 1.3 to 1.4 external cluster
During the 1.3 cycle, we had implemented support for OBC external mode
through an Endpoint in the StorageClass parameter. In 1.4, this is not
the case anymore as we directly use the CephObjectStore external mode.
However, we must maintain backward compatibility with the cluster using
the Endpoint and not fail the upgrade.
Thus checking for a CephObjectStore is invalid and should not always be
assumed, now if we detect an Endpoint we return a simple context which
fixes the upgrade.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-10-01 11:33:54 +02:00
Daniel Chaplin 231317c5f1 core: rbac: allow manipulations on monitoring.coreos.com resources
Before it wasn't allowed but required to successfully deploy Ceph cluster with monitoring enabled.
Fixed by adding more rules to rook-ceph-system rbac role

Closes: https://github.com/rook/rook/issues/6255
Signed-off-by: Daniel Chaplin <black.danek@gmail.com>
2020-10-01 12:11:57 +03:00
subhamkrai 679230f285 ci: enable all golangci-lint linter
this commit enable defalut error check
for golangci-lint linter.

Signed-off-by: subhamkrai <srai@redhat.com>
2020-09-30 22:26:02 +05:30
subhamkrai 0fddfcf307 ceph: handle golangci-lint linter errcheck error
this commit handle golangci-lint linter errcheck.

`errcheck` - Errcheck is a program for checking for
unchecked errors in go programs. These unchecked errors
can be critical bugs in some cases

To see only staticcheck linter output
`golangci-lint run --disable-all -E errcheck`

Signed-off-by: subhamkrai <srai@redhat.com>
2020-09-30 22:24:34 +05:30
Sébastien Han 61b2c6186d Merge pull request #6350 from leseb/fix-luks2-resize
ceph: disable keyring after opening encrypted block
2020-09-30 16:42:51 +02:00
Sébastien Han a7e78858ce ceph: disable keyring after opening encrypted block
On LUKS2 format, the resize operation requires the KEK to be passed. To
maintain a single simple init container for resize, we now open the
encrypted block with  "--disable-keyring" so that further operations
won't require the keyring.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-09-30 15:53:36 +02:00
Sébastien Han 7852f75418 Merge pull request #6344 from varshar16/create-user-per-nfs-daemon
ceph: create user for each ganesha daemon
2020-09-30 10:49:07 +02:00
Varsha Rao 8d3140c8a0 ceph: create user for each ganesha daemon
Ganesha daemons don't need to acess ceph cluster with admin capabilities.
Instead new user with restricted caps can be used.

Signed-off-by: Varsha Rao <varao@redhat.com>
2020-09-29 22:27:17 +05:30
Travis Nielsen 5351968181 Merge pull request #6330 from travisn/osd-reconcile-perf
ceph: Detect OSDs on PVCs in batches instead of with label selectors individually
2020-09-29 09:24:35 -06:00
Sébastien Han eecfa1b7b0 Merge pull request #6338 from thotz/fixobcdeleteissue
ceph: remove user unlink while deleting OBC
2020-09-29 17:14:04 +02:00
Travis Nielsen e2cf76a15e Merge pull request #6343 from leseb/fix-6329
ceph: only support one external cluster secret
2020-09-29 08:23:26 -06:00
Travis Nielsen 2f3313475b Merge pull request #6340 from Madhu-1/csi-v3.1.1
ceph: update cephcsi to v3.1.1
2020-09-29 08:14:15 -06:00
Jiffin Tony Thottan b7bc51ea69 ceph: remove user unlink while deleting OBC
User unlink is performed just before deleting OBC resources.
Since user is internal to OBC and next to remove to delete user,
unlinking user is not necessary.

Fixes: 6300
Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-09-29 17:20:54 +05:30
Sébastien Han 08944c4e50 ceph: only support one external cluster secret
We do not support providing both ROOK_EXTERNAL_USER_SECRET and
ROOK_EXTERNAL_ADMIN_SECRET. When both are provided in the mon secret,
the operator code will use the client.admin user for all its operations.
This will break some of the logic when creating OBC since if
client.admin is detected we assume the cluster is converged and thus
pass args like this:

```
--rgw-realm=external-store --rgw-zonegroup=external-store --rgw-zone=external-store
```

To the radosgw-admin command, which won't work since Rook has no idea
what the external realm/zonegroup/zone are, if any are configured.

This fix should be sufficient for now, but moving forward we should
probably enhance clusterInfo with an "isExternal" property to make
things easier. Also supporting external realm/zonegroup/zone would be
nice. This will probanly hit 1.5 once this code is promoted to stable.
See: https://github.com/rook/rook/issues/6342

Closes: https://github.com/rook/rook/issues/6329
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-09-29 11:06:19 +02:00
Madhu Rajanna 2fa3e71733 ceph: update cephcsi to v3.1.1
as cephcsi v3.1.1 is released today
with many bug fixes and enhancements,
more details can be found at
https://github.com/ceph/ceph-csi/releases/tag/v3.1.1

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-09-29 14:03:44 +05:30