Skip to content
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

mon: fix force_pg_create pg stuck in creating bug #12539

Merged
merged 3 commits into from Feb 9, 2017

Conversation

liewegas
Copy link
Member

http://tracker.ceph.com/issues/18298

Also clean out some more legacy crud we don't need.

// the cluster. As soon as everybody has upgraded we can flipt to the new
// behavior instead
OSDMap& osdmap = mon->osdmon()->osdmap;
if (osdmap.get_num_up_osds() == 0)

Choose a reason for hiding this comment

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

should we still keep this check?

@liewegas
Copy link
Member Author

liewegas commented Dec 20, 2016 via email

@liewegas
Copy link
Member Author

@tchaikov rebased this on master

@tchaikov tchaikov self-assigned this Jan 31, 2017
Copy link
Member

@jecluis jecluis left a comment

Choose a reason for hiding this comment

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

meh, looked at this last week and then forgot to add the review.

lgtm.

@liewegas
Copy link
Member Author

retest this please

@liewegas
Copy link
Member Author

liewegas commented Feb 1, 2017

retest this please

if (osdmap.get_num_up_osds() > 0) {
assert(osdmap.get_up_osd_features() & CEPH_FEATURE_MON_STATEFUL_SUB);
}
check_subs();
Copy link
Contributor

Choose a reason for hiding this comment

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

could move check_subs() into the if (osdmap.get_num_up_osds() > 0) block, because only OSD is interested in the pg creates updates.

ff1fd4b already removed most of
this; remove the now useless stub and clean up the unneede con
check.

Signed-off-by: Sage Weil <sage@redhat.com>
Forgot this in 6cbdd67

Signed-off-by: Sage Weil <sage@redhat.com>
We weren't carefully registering the creating PG.  In
particular, the current osd mappings (acting, up, etc.)
weren't getting filled in, which meant the PG wasn't
(necessarily) mapped to an OSD until the OSDMap updated
and we recalculated mappings.

Fix by sending us through the common code path so that
all fields get updated properly.

Fixes: http://tracker.ceph.com/issues/18298
Signed-off-by: Sage Weil <sage@redhat.com>
@liewegas
Copy link
Member Author

liewegas commented Feb 6, 2017 via email

@liewegas liewegas merged commit 4d505ac into ceph:master Feb 9, 2017
@liewegas liewegas deleted the wip-mon-pg-creates branch February 9, 2017 02:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants