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

rgw: only log metadata on metadata master zone #15613

Merged
merged 1 commit into from Jun 13, 2017

Conversation

Projects
None yet
3 participants
@cbodley
Contributor

cbodley commented Jun 10, 2017

rgw: only log metadata on metadata master zone
Fixes: http://tracker.ceph.com/issues/20244

Signed-off-by: Casey Bodley <cbodley@redhat.com>
@oritwas

This comment has been minimized.

Contributor

oritwas commented Jun 11, 2017

jenkins test this please

@cbodley

This comment has been minimized.

Contributor

cbodley commented Jun 12, 2017

jenkins test this please

1 similar comment
@oritwas

This comment has been minimized.

Contributor

oritwas commented Jun 13, 2017

jenkins test this please

@cbodley cbodley merged commit 9d7b477 into ceph:master Jun 13, 2017

3 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
make check make check succeeded
Details

@cbodley cbodley deleted the cbodley:wip-20244 branch Jun 13, 2017

@@ -3557,7 +3557,7 @@ class RGWRados
}
bool need_to_log_metadata() {
return get_zone().log_meta;
return is_meta_master() && get_zone().log_meta;

This comment has been minimized.

@idealguo

idealguo Jun 14, 2017

It means master zone in slave zonegroup will not log metadata too?

This comment has been minimized.

@cbodley

cbodley Jun 14, 2017

Contributor

correct, and RGWZoneGroup::post_process_params() has already been enforcing this in radosgw-admin commands:

  for (map<string, RGWZone>::iterator iter = zones.begin(); iter != zones.end(); ++iter) {
    RGWZone& zone = iter->second;
    zone.log_data = log_data;
    zone.log_meta = (is_master && zone.id == master_zone);

this pr just moved that enforcement into RGWRados itself, so that we can properly handle zones that were created before jewel and hadn't triggered that code in RGWZoneGroup::post_process_params()

after jewel, if multiple zones have log_meta set, the secondary zone will add each mdlog entry that it syncs from the metadata master back into its mdlog, and then keep resyncing/rewriting that entry, filling up its mdlog with duplicate entries

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment