Skip to content

Commit

Permalink
Merge PR ceph#38836 into master
Browse files Browse the repository at this point in the history
* refs/pull/38836/head:
	client: add debug messages for osdmap wait

Reviewed-by: Xiubo Li <[email protected]>
  • Loading branch information
batrick committed Jan 11, 2021
2 parents 1783f43 + 14b4787 commit ed34006
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion qa/suites/fs/volumes/tasks/volumes/overrides.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ overrides:
ceph:
conf:
mgr:
debug client: 10
debug client: 20
log-ignorelist:
- OSD full dropping all updates
- OSD near full
Expand Down
3 changes: 3 additions & 0 deletions src/client/Client.cc
Original file line number Diff line number Diff line change
Expand Up @@ -12163,6 +12163,7 @@ void Client::_setxattr_maybe_wait_for_osdmap(const char *name, const void *value
// For setting pool of layout, MetaRequest need osdmap epoch.
// There is a race which create a new data pool but client and mds both don't have.
// Make client got the latest osdmap which make mds quickly judge whether get newer osdmap.
ldout(cct, 15) << __func__ << ": name = " << name << dendl;
if (strcmp(name, "ceph.file.layout.pool") == 0 || strcmp(name, "ceph.dir.layout.pool") == 0 ||
strcmp(name, "ceph.file.layout") == 0 || strcmp(name, "ceph.dir.layout") == 0) {
string rest(strstr(name, "layout"));
Expand All @@ -12173,7 +12174,9 @@ void Client::_setxattr_maybe_wait_for_osdmap(const char *name, const void *value

if (r == -ENOENT) {
bs::error_code ec;
ldout(cct, 20) << __func__ << ": waiting for latest osdmap" << dendl;
objecter->wait_for_latest_osdmap(ca::use_blocked[ec]);
ldout(cct, 20) << __func__ << ": got latest osdmap: " << ec << dendl;
}
}
}
Expand Down

0 comments on commit ed34006

Please sign in to comment.