Skip to content

Set mon_target_pg_per_osd to 400 only during cluster creation #3170

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

malayparida2000
Copy link
Contributor

@malayparida2000 malayparida2000 commented Apr 16, 2025

On existing clusters the value of mon_target_pg_per_osd is by default set to 100. If we set it to 400, there will be a massive increase in the number of PGs which will cause rebalancing & data movement.

On existing clusters customers will have to set the value of mon_target_pg_per_osd to 400 manually on the storageCluster CR if they want to increase the number of PGs.

Ref-https://issues.redhat.com/browse/DFBUGS-2391

This can be used to specify any Ceph config options on the cluster

Signed-off-by: Malay Kumar Parida <[email protected]>
On existing clusters the value of mon_target_pg_per_osd is by default
set to 100. If we set it to 400, there will be a massive increase in the
number of PGs which will cause rebalancing & data movement.

On existing clusters customers will have to set the value of
mon_target_pg_per_osd to 400 manually on the storageCluster CR
if they want to increase the number of PGs.

Signed-off-by: Malay Kumar Parida <[email protected]>
@malayparida2000 malayparida2000 force-pushed the target_pg_per_osd_upgrade_case branch from 968287e to d4fd23d Compare April 17, 2025 03:28
@malayparida2000
Copy link
Contributor Author

/retest

@malayparida2000
Copy link
Contributor Author

/cc @travisn PTAL

@openshift-ci openshift-ci bot requested a review from travisn April 30, 2025 10:00
Copy link
Contributor

openshift-ci bot commented Apr 30, 2025

@malayparida2000: GitHub didn't allow me to request PR reviews from the following users: PTAL.

Note that only red-hat-storage members and repo collaborators can review this PR, and authors cannot review their own PRs.

In response to this:

/cc @travisn PTAL

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Copy link
Contributor

@travisn travisn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one comment to consider now, or as a follow up.

@@ -1559,3 +1559,34 @@ func generateCephReplicatedSpec(initData *ocsv1.StorageCluster, poolType string)

return crs
}

// setMonTargetPgPerOsd sets the mon_target_pg_per_osd value to 400 if not already set
func setMonTargetPgPerOsd(cephConfig *map[string]map[string]string) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like us to consider moving other settings from the configmap to this CephConfig section as well, so I hope we can generalize this implementation of preserving default ceph settings. But this can be a 4.20 work item, not urgent for now.

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Apr 30, 2025
Copy link
Contributor

openshift-ci bot commented Apr 30, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: malayparida2000, travisn

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 30, 2025
@travisn
Copy link
Contributor

travisn commented Apr 30, 2025

/hold for the last question

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Apr 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants