dht logging cleanup
This commit is contained in:
parent
a76ce13ce2
commit
702affac48
@ -156,8 +156,6 @@ unlock:
|
||||
local->layout = NULL;
|
||||
|
||||
if (ret != 0) {
|
||||
layout->gen = conf->gen;
|
||||
|
||||
gf_log (this->name, GF_LOG_DEBUG,
|
||||
"fixing assignment on %s",
|
||||
local->loc.path);
|
||||
|
@ -39,8 +39,11 @@ dht_layout_t *
|
||||
dht_layout_new (xlator_t *this, int cnt)
|
||||
{
|
||||
dht_layout_t *layout = NULL;
|
||||
dht_conf_t *conf = NULL;
|
||||
|
||||
|
||||
conf = this->private;
|
||||
|
||||
layout = CALLOC (1, layout_size (cnt));
|
||||
if (!layout) {
|
||||
gf_log (this->name, GF_LOG_ERROR,
|
||||
@ -49,7 +52,8 @@ dht_layout_new (xlator_t *this, int cnt)
|
||||
}
|
||||
|
||||
layout->cnt = cnt;
|
||||
|
||||
if (conf)
|
||||
layout->gen = conf->gen;
|
||||
out:
|
||||
return layout;
|
||||
}
|
||||
@ -257,7 +261,7 @@ dht_layout_merge (xlator_t *this, dht_layout_t *layout, xlator_t *subvol,
|
||||
|
||||
if (ret != 0) {
|
||||
layout->list[i].err = -1;
|
||||
gf_log (this->name, GF_LOG_DEBUG,
|
||||
gf_log (this->name, GF_LOG_TRACE,
|
||||
"missing disk layout on %s. err = %d",
|
||||
subvol->name, err);
|
||||
ret = 0;
|
||||
@ -495,12 +499,14 @@ dht_layout_normalize (xlator_t *this, loc_t *loc, dht_layout_t *layout)
|
||||
/* TODO During DHT selfheal rewrite (almost) find a better place to
|
||||
* detect this - probably in dht_layout_anomalies()
|
||||
*/
|
||||
if (layout->list[i].err == ENOENT) {
|
||||
if (layout->list[i].err > 0) {
|
||||
gf_log (this->name, GF_LOG_DEBUG,
|
||||
"path=%s ENOENT - directory entry"
|
||||
" should be created in selfheal", loc->path);
|
||||
ret = 1;
|
||||
break;
|
||||
"path=%s err=%s on subvol=%s",
|
||||
loc->path, strerror (layout->list[i].err),
|
||||
(layout->list[i].xlator ?
|
||||
layout->list[i].xlator->name : "<>"));
|
||||
if (layout->list[i].err == ENOENT)
|
||||
ret = 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -169,7 +169,7 @@ dht_selfheal_dir_xattr (call_frame_t *frame, loc_t *loc, dht_layout_t *layout)
|
||||
missing_xattr++;
|
||||
}
|
||||
|
||||
gf_log (this->name, GF_LOG_DEBUG,
|
||||
gf_log (this->name, GF_LOG_TRACE,
|
||||
"%d subvolumes missing xattr for %s",
|
||||
missing_xattr, loc->path);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user