This code has suffered a great deal of bitrot and is superceded
by the cmds --dump-journal functionality anyway, which
is much more full-featured.
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
pipes marked disposable must not inherit the lossy policy on reconnect.
Also, in Pipe::writer, when sent.empty() && close_on_empty, mark as
lossy to ensure that fault will close the connection.
Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
Somehow, in the last major change, the constraints that kept the
bencher from trying to read non-existent objects got removed. Put
a check back in the main bench loop to fix that.
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
This only affects list_collections. Previously, when using an FS that
does not support d_type, like xfs, load_pgs would fail to find any
pgs, since list_collections skipped all files.
This made clients hang because all pgs were considered non-existent by
the osd.
Reported-by: Yoshiaki Tamura <yoshi@midokura.jp>
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
If srcdn is a remote dentry, we will be journaling the src inode to update
the mtime, but we need to ensure the parent dirs are in the metablob.
Fixes: #1132
Signed-off-by: Sage Weil <sage@newdream.net>
The reread_head method needs to initialize trimming_pos (like read_head
does) or else we get confused later.
Signed-off-by: Sage Weil <sage@newdream.net>
Make sure the inode is pinned while it is on the LogSegment::renamed_files
list. Avoids a crash when an inode on that list is wrongly trimmed.
Signed-off-by: Sage Weil <sage@newdream.net>
We need to seek to the appropriate offsets on the src and destination
fd's for this to do the right thing.
Signed-off-by: Sage Weil <sage@newdream.net>
If we get heartbeat messages from old epochs from peers that are not
current, drop them and mark the connection down. Even if they are peers
we _should_ have (because we haven't gotten a notify yet to learn about
a pg we should have but don't yet) we have a newer map epoch and will learn
about them shortly, reopening the connection.
Fixes: #1107
Signed-off-by: Sage Weil <sage@newdream.net>
- share the map with the cluster addr
- use the new {note,get}_peer_epoch helpers to do it sanely
- don't share if we're booting; see 818fa33a66
Signed-off-by: Sage Weil <sage@newdream.net>
We were calling recovery_item.remove_myself() without holding the
recoveryWQ::lock. Naughty naughty!
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
This lets OSDMap::create_simple() see g_conf.osd_pool_default_size when
creating the initial data, metadata, and rbd pools.
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>