Commit Graph
5265 Commits
Author SHA1 Message Date
Travis Nielsen 68853a50be Merge pull request #17962 from parth-gr/rgw-account-deletion
rgw: rgw account deletion should remove account from ceph
2026-07-20 14:11:52 -06:00
Travis Nielsen 5c372db30a Merge pull request #17925 from malayparida2000/go-work
build: migrate multi-module setup to go.work
2026-07-20 11:50:00 -06:00
subham rai 02428dc8ac Merge pull request #17979 from Madhu-1/resolve-node-publish-secret
external: resolve node secret names via annotations for external cluster
2026-07-20 14:20:41 +05:30
Malay Kumar Parida 78006802eb build: cleanup both go.mod files replace & require sections
Signed-off-by: Malay Kumar Parida <mparida@redhat.com>
2026-07-17 14:20:40 +05:30
subham rai 43a28b32f8 Merge pull request #17978 from malayparida2000/codegen_fix
build: Resolve kube code-generator version from the repo's k8s version
2026-07-17 14:06:55 +05:30
Blaine Gardner 75e64b00be Merge pull request #17940 from subhamkrai/add-caps-rgw-admin-user
object: option to update rgw caps with account
2026-07-15 14:12:24 -06:00
Michael Adam c90913051b rgw: fix a comment typo
This fixes a comment typo caught bt the codespell CI check.

Signed-off-by: Michael Adam <obnox@samba.org>
2026-07-15 18:25:53 +02:00
subhamkrai 392204c1f8 object: option to update rgw caps with account
this commit add support for updating rgw caps with
`user-info-without-key` and `accounts` to cephobjectstoreuser crd
Adding the check for min ceph version from which these caps
are available.

Co-Authoured-by:  Jiffin Tony Thottan <thottanjiffin@gmail.com>
Signed-off-by: subhamkrai <srai@redhat.com>
2026-07-15 16:45:49 +05:30
Madhu Rajanna 14a146c045 external: resolve node secret names via annotations for external clusters
Add annotations to RBD node secrets in
import-external-cluster.sh so that externally
created secrets with
custom names can be discovered at runtime.
Update CreateUpdateClientProfileRadosNamespace to
look up secrets by annotation
instead of using hardcoded names.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2026-07-15 10:37:18 +05:30
Malay Kumar Parida 6958535ea4 build: resolve kube code-generator version from the repo's k8s version
kubernetes/code-generator is versioned alongside the core k8s.io modules, so codegen should logically stay in sync with the Kubernetes version in go.mod.
So we now resolve KUBE_CODEGEN_TAG from k8s.io/apimachinery with go list instead of maintaining a separate
pin that can silently fall behind dependency bumps. This removes manual version upkeep entirely. Bumping k8s modules in
go.mod automatically picks the matching code-generator release on the next make codegen.

Also rename CODE_GENERATOR_VERSION to KUBE_CODEGEN_TAG to align with the kube_codegen.sh tooling and the CODE_GENERATOR path used by codegen.sh.
Add the generated files for latest codegen run as well.

Signed-off-by: Malay Kumar Parida <mparida@redhat.com>
2026-07-15 00:59:15 +05:30
Parth Arora 0679f843bc Merge pull request #17896 from parth-gr/vsi-volume-attach
external: resolve provisioner secret names via annotations for extern…
2026-07-14 18:10:16 +05:30
parth-gr cca7020f0b rgw: rgw account deletion should remove account from ceph
currently there was a bug in the code where it didnt removed
the account from the ceph cluster during intial intialize

Signed-off-by: parth-gr <partharora1010@gmail.com>
2026-07-14 16:01:09 +05:30
Travis Nielsen 46a1b0d19b Merge pull request #17887 from Madhu-1/add-node-publish-volume
csi: Add supported files for krbd QoS
2026-07-13 11:55:16 -06:00
Travis Nielsen 1b62ed8507 Merge pull request #17920 from XT-Phate/fix(cephfs)--raise-swallowed-error
file: reveal swallowed errors on cephfs reconciliation
2026-07-10 11:22:56 -06:00
parth-gr ac14ce76c9 external: resolve provisioner secret names via annotations for external clusters
Add annotations to CephFS and RBD provisioner secrets in
import-external-cluster.sh so that externally created secrets with
custom names can be discovered at runtime.
Update CreateUpdateClientProfileRadosNamespace and
generateProfileSubVolumeGroupSpec to look up secrets by annotation
instead of using hardcoded names.

closes: https://github.com/rook/rook/issues/16956
Signed-off-by: parth-gr <partharora1010@gmail.com>
2026-07-10 17:15:01 +05:30
Artem Torubarov 75fe8db848 osd: rename internal OSD migration field to migrateOSD
Signed-off-by: Artem Torubarov <artem.torubarov@sap.com>
2026-07-10 11:45:47 +02:00
Maxime Bertin 0696b24d9c file: reveal swallowed errors on cephfs reconciliation
CephFS reconciliation loop on Filesystem creation was swallowing errors.
The err variable which contained the error was replaced with the resulted error from the
kubernetes update status call on the CRD.
This commit fixes that and aggregate both errors in case there is both a kubernetes status update failure and a creation error.

Signed-off-by: Maxime Bertin <mbertin@luccasoftware.com>
2026-07-10 08:28:35 +02:00
Travis Nielsen 057147089b Merge pull request #17923 from malayparida2000/build_fix
build: fix go.mod.check sed for apis module replace
2026-07-09 11:10:55 -06:00
Malay Kumar Parida fe38b157f5 build: fix go.mod.check sed for apis module replace
The go.mod.check target generates pkg/apis/go.mod from the root go.mod
and must remove the root-only replace directive that points
github.com/rook/rook/pkg/apis to ./pkg/apis. The sed pattern expected
the line to start with "replace", but the actual line is tab-indented
inside the replace block, so the directive was never removed.
Update the sed pattern to match optional leading whitespace and remove
the incorrect self-replace from pkg/apis/go.mod.

Signed-off-by: Malay Kumar Parida <mparida@redhat.com>
2026-07-09 21:28:22 +05:30
Parth Arora 6ee3198716 Merge pull request #17689 from subhamkrai/update-tnf-script-hostname
mon: update how hostname was set for drbd
2026-07-09 21:07:54 +05:30
Madhu Rajanna 328efbadc4 csi: add nodepublishsecret to clientprofile
Add the node publish secret to the client
profile that is required for the PVC's created
from SC without any node publish secret.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2026-07-08 10:17:52 +05:30
subhamkrai c49ef5f079 mon: update how hostname was set for drbd
currently, drbd hostname was ready using command
but now the change we use kubernetes built-in api
to read hostname from `spec.nodeName`.`

Signed-off-by: subhamkrai <srai@redhat.com>
2026-07-07 08:45:28 +05:30
Anas Khan 47b4167b70 core: reconcile when node OSD topology labels change
shouldReconcileChangedNode only diffed the node spec, so changes to node
labels, including rook's own topology.rook.io/* labels, were never detected.
Relabeling a node therefore did not trigger a CephCluster reconcile until some
other condition eventually did.

Trigger a reconcile from the node update predicate when one of the OSD topology
labels rook cares about changes. The whitelist reuses the canonical label set
from topology.GetDefaultTopologyLabels() (the hostname, the Kubernetes
region/zone labels, and the topology.rook.io/* labels), so a reconcile is
scoped to topology changes instead of firing on any label or annotation change.
The UpdateFunc returns true directly for these changes because onK8sNode()
returns false for a node that is already an OSD host, which would otherwise
swallow the relabel.

Resolves #17652

Signed-off-by: Anas Khan <anas@anaskhan.me>
2026-07-07 07:38:15 +05:30
weifanglab 4d2705ce28 core: replace Split in loops with more efficient SplitSeq
Signed-off-by: weifanglab <weifanglab@outlook.com>
2026-07-07 00:41:15 +08:00
Joshua Hoblitt c0eb360041 docs: fix typos and grammar in code comments
Fix duplicate words, incorrect articles (a/an), it's/its, and other small
grammar mistakes in Go comments and user-facing messages across pkg/, cmd/,
and tests/.

Signed-off-by: Joshua Hoblitt <josh@hoblitt.com>
2026-07-01 08:34:11 -07:00
Anas Khan 67bf4baab8 object: use passed context for S3 v2 API calls
The AWS SDK v1 to v2 migration in #17468 left the S3Agent wrapper methods
calling the SDK with context.TODO(), so S3 operations could not be cancelled
when the controller context is cancelled. Add a leading context.Context
parameter to CreateBucket, PutObjectInBucket, GetObjectInBucket,
DeleteObjectInBucket, PutBucketPolicy, and GetBucketPolicy, forward it to the
underlying client, and pass clusterInfo.Context from the bucket provisioner.

Resolves #17526

Signed-off-by: Anas Khan <83116240+anxkhn@users.noreply.github.com>
2026-07-01 13:15:40 +05:30
blackflytech c65663c529 core: use slices.Backward to simplify the code
Signed-off-by: blackflytech <blackflytech@outlook.com>
2026-07-01 00:37:50 +08:00
Joshua Hoblitt e5c6d75a73 core: narrow bare //nolint directives to specific linters
The //nolint directives at these sites omit the linter name, so each
suppresses every linter on its line rather than the one check it needs.
That hides any unrelated errcheck/gosec/govet finding later introduced
on the same line. Name the specific linter for each:

- staticcheck for the two operator sites: SA4004 (the intentional
  single-iteration loop in the OSD PVC host lookup) and SA1019 (the
  deliberate read of the deprecated S3.Enabled field in the RGW
  API-enable builder).
- errcheck for the rbd-mirror deferred token-file cleanup and the
  test-framework logging helpers (WriteString / writeHeader).

No behavior change.

Signed-off-by: Joshua Hoblitt <josh@hoblitt.com>
2026-06-29 16:32:59 -07:00
Joshua Hoblitt 993be34a24 Merge pull request #17834 from jhoblitt/docs/fix-stale-doc-comment-names
docs: fix function comments to match their declaration names
2026-06-29 12:04:25 -07:00
Blaine Gardner 485529056d Merge pull request #17764 from subhamkrai/mute-ceph-errors
core: add api changes to mute ceph warnings
2026-06-29 09:50:13 -06:00
Joshua Hoblitt 49612461a4 docs: fix function comments to match their declaration names
Several godoc comments led with a stale or incorrect identifier, left
over from renames, exported/unexported changes, copy-paste between
sibling declarations, or plain typos. As a result the documented name no
longer matched the function, method, type, or var it describes. Correct
each leading word to the name of the declaration it documents.

Signed-off-by: Joshua Hoblitt <josh@hoblitt.com>
2026-06-26 12:52:39 -07:00
pengqima 240c431f42 docs: fix function comment to match actual function name
Signed-off-by: pengqima <pengqima@outlook.com>
2026-06-26 23:43:22 +08:00
daixihegu 063dcad054 core: use slices.Contains to simplify code
Signed-off-by: daixihegu <daixihegu@163.com>
2026-06-25 10:17:53 +08:00
Travis Nielsen d9de5b1d6f Merge pull request #17758 from kavirakesh14/fix-17285-config-override-newline
ceph: ensure config overrides end with a trailing newline
2026-06-24 10:48:48 -06:00
subhamkrai 9a6c5842bc core: implement ceph health warning mute
this commit implement api to configure
ceph health warning mute/unmute.

Signed-off-by: subhamkrai <srai@redhat.com>
2026-06-24 21:10:54 +05:30
kavirakesh14 619b800b67 operator: fail reconcile if rook-config-override lacks trailing newline
Signed-off-by: kavirakesh14 <kavirakesh007@gmail.com>
2026-06-24 09:56:41 +00:00
Travis Nielsen 7803fac10d core: skip node watcher during initial cache sync
When the operator starts, there is no need to handle the
node watcher immediately while the controller runtime
cache is being initialized. The cluster will anyway be
fully reconciled and create new OSDs if needed. The node
watcher is only intended for triggering a reconcile when
a node is added or updated at a later time after a sync
would anyway be triggered.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2026-06-23 13:39:49 -06:00
Travis Nielsen 33cbe3ddda Merge pull request #17794 from rook/dependabot/go_modules/github-dependencies-77d13303f7
build(deps): bump the github-dependencies group with 4 updates and require Go 1.26
2026-06-23 10:31:08 -06:00
Parth Arora 451c3f3d1b Merge pull request #17805 from parth-gr/drbd-mons
core: reduce the floating mon reschdule time
2026-06-23 20:55:48 +05:30
dependabot[bot] 516b46bf34 build(deps): bump the github-dependencies group with 4 updates
Bumps the github-dependencies group with 4 updates: [github.com/aws/aws-sdk-go-v2/service/s3](https://github.com/aws/aws-sdk-go-v2), [github.com/ceph/go-ceph](https://github.com/ceph/go-ceph), [github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring](https://github.com/prometheus-operator/prometheus-operator) and [github.com/prometheus-operator/prometheus-operator/pkg/client](https://github.com/prometheus-operator/prometheus-operator).

Updates `github.com/aws/aws-sdk-go-v2/service/s3` from 1.103.3 to 1.104.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/s3/v1.103.3...service/s3/v1.104.0)

Updates `github.com/ceph/go-ceph` from 0.39.0 to 0.40.0
- [Release notes](https://github.com/ceph/go-ceph/releases)
- [Changelog](https://github.com/ceph/go-ceph/blob/master/docs/release-process.md)
- [Commits](https://github.com/ceph/go-ceph/compare/v0.39.0...v0.40.0)

Updates `github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring` from 0.91.0 to 0.92.0
- [Release notes](https://github.com/prometheus-operator/prometheus-operator/releases)
- [Changelog](https://github.com/prometheus-operator/prometheus-operator/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prometheus-operator/prometheus-operator/compare/v0.91.0...v0.92.0)

Updates `github.com/prometheus-operator/prometheus-operator/pkg/client` from 0.91.0 to 0.92.0
- [Release notes](https://github.com/prometheus-operator/prometheus-operator/releases)
- [Changelog](https://github.com/prometheus-operator/prometheus-operator/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prometheus-operator/prometheus-operator/compare/v0.91.0...v0.92.0)

---
updated-dependencies:
- dependency-name: github.com/aws/aws-sdk-go-v2/service/s3
  dependency-version: 1.104.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: github-dependencies
- dependency-name: github.com/ceph/go-ceph
  dependency-version: 0.40.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: github-dependencies
- dependency-name: github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring
  dependency-version: 0.92.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: github-dependencies
- dependency-name: github.com/prometheus-operator/prometheus-operator/pkg/client
  dependency-version: 0.92.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: github-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: subhamkrai <srai@redhat.com>
2026-06-23 20:32:19 +05:30
parth-gr 9e0b6e5bbe core: reduce the floating mon reschdule time
currently k8s add the default eviction time as 300 sec
setting it to 5 sec for the quick re-schedule

Signed-off-by: parth-gr <partharora1010@gmail.com>
2026-06-23 20:15:56 +05:30
Satoru Takeuchi a8398f9996 Merge pull request #17724 from jhoblitt/osd-activate-skip-rbd-scan
osd: do not scan rbd devices in raw activate fallback
2026-06-23 07:44:02 +09:00
Joshua Hoblitt da07f0c476 osd: do not scan rbd devices in raw activate fallback
When the OSD activate init container cannot match its configured
device, it falls back to a bare 'ceph-volume raw list', which
enumerates every block device on the node and opens each one to read
bluestore labels. Opening a krbd device whose backing cluster is
unhealthy can block in uninterruptible sleep; when that device's I/O
depends on the OSD being activated, activation deadlocks.

Build the fallback scan list explicitly with lsblk and exclude the
network-backed device types that can hang when their backing storage
is unavailable (rbd, nbd, drbd) along with zram (volatile RAM). Rook
never provisions OSDs on any of these, so the fallback can never
legitimately need to find an OSD on them. loop devices are kept,
since OSDs on loop devices are supported for CI and local testing.
Fail fast if the filtered list is empty rather than degenerating back
to a full scan.

Note this hardens only the rename-fallback path. The deadlock observed
in CI (kernel hung tasks under 'ceph-volume raw activate' opening a
stalled /dev/rbd0; actions runs 27325963851, 27333888237, and
27378983111, which reproduced it on this PR's own head) ultimately
originates inside ceph-volume: 'raw activate' runs an unconditional
LUKS2/TPM2 discovery sweep over all block devices even when given an
explicit --device. That requires a ceph-volume fix; this change makes
the Rook-controlled scan safe regardless of ceph version.

Signed-off-by: Joshua Hoblitt <josh@hoblitt.com>
2026-06-22 10:00:58 -07:00
Travis Nielsen 63eed4ed47 Merge pull request #17279 from sophotechlabs/test/osd-config-store
test: add unit tests for OSD store config parsing
2026-06-19 08:12:00 -06:00
subhamkrai ad26ebdab0 build: update ceph version to latest v20.2.2
updating the ceph version from v20.2.1 to v20.2.2

Signed-off-by: subhamkrai <srai@redhat.com>
2026-06-17 22:00:11 +05:30
Santosh Pillai 6feb856a9f Merge pull request #17670 from jhoblitt/maint-remove-dead-lockingbool
operator: remove dead code from the operator tree
2026-06-17 15:05:49 +05:30
Travis Nielsen ecadb76e6f Merge pull request #17710 from jhoblitt/object-realm-key-urlsafe
object: generate URL-safe realm access keys
2026-06-16 15:16:22 -06:00
subhamkrai ff5f3baa58 core: add api changes to mute ceph warnings
adding api changes to mute/unmute ceph warnings
based on user configuration. The field is map[string]string
key is ceph warning and value is duration how longs
the warnings will be muted.

Signed-off-by: subhamkrai <srai@redhat.com>
2026-06-16 17:16:04 +05:30
Joshua Hoblitt b1bbfb4bba Merge pull request #17726 from jhoblitt/maint-remove-dead-k8sutil-sweep
k8sutil: remove unused helper functions
2026-06-12 09:10:32 -07:00
Blaine Gardner 3d9e868741 Merge pull request #17727 from jhoblitt/maint-remove-dead-cephclient-funcs
core: remove dead code from pkg/daemon and pkg/util
2026-06-12 10:04:24 -06:00