mirror of
https://github.com/ceph/ceph
synced 2025-03-11 02:39:05 +00:00
*** empty log message ***
git-svn-id: https://ceph.svn.sf.net/svnroot/ceph@644 29311d96-e01e-0410-9327-a35deaab8ce9
This commit is contained in:
parent
9902cfdc0a
commit
6859fe817d
@ -3,7 +3,7 @@
|
||||
# hi there
|
||||
{
|
||||
'sleep' => 3,
|
||||
'kill_after' => 300,
|
||||
'kill_after' => 700,
|
||||
|
||||
'nummds' => [2, 4, 6, 8, 10, 12],
|
||||
|
||||
@ -15,7 +15,8 @@
|
||||
|
||||
# parameters
|
||||
'fs' => 'ebofs',
|
||||
'until' => 100, # --syn until $n ... when to stop clients
|
||||
|
||||
'until' => 600, # --syn until $n ... when to stop clients
|
||||
|
||||
'makedirs' => 1,
|
||||
'makedirs_dirs' => 10,
|
||||
@ -26,11 +27,11 @@
|
||||
#'custom' => '--debug_after 110 --debug_osd 15 --debug_filer 15 --debug 5',
|
||||
|
||||
# for final summation (script/sum.pl)
|
||||
'start' => 30,
|
||||
'end' => 90,
|
||||
'start' => 100,
|
||||
'end' => 550,
|
||||
|
||||
'comb' => {
|
||||
'x' => 'nummds',
|
||||
'vars' => [ 'mds.op' ]
|
||||
'vars' => [ 'mds.req' ]
|
||||
}
|
||||
};
|
||||
|
@ -33,7 +33,7 @@
|
||||
|
||||
#include "config.h"
|
||||
#undef dout
|
||||
#define dout(x) if (x <= g_conf.debug) cout << "mds" << mds->get_nodeid() << " cdir: "
|
||||
#define dout(x) if (x <= g_conf.debug || x <= g_conf.debug_mds) cout << "mds" << mds->get_nodeid() << " cdir: "
|
||||
|
||||
|
||||
// PINS
|
||||
|
@ -31,7 +31,7 @@
|
||||
|
||||
#include "config.h"
|
||||
#undef dout
|
||||
#define dout(x) if (x <= g_conf.debug) cout << "cinode: "
|
||||
#define dout(x) if (x <= g_conf.debug || x <= g_conf.debug_mds) cout << "cinode: "
|
||||
|
||||
|
||||
int cinode_pins[CINODE_NUM_PINS]; // counts
|
||||
|
@ -36,7 +36,7 @@ using namespace std;
|
||||
|
||||
#include "config.h"
|
||||
#undef dout
|
||||
#define dout(l) if (mds->get_nodeid() == 0 && (l<=g_conf.debug || l<=g_conf.debug_mds_log)) cout << "mds" << mds->get_nodeid() << ".logstream "
|
||||
#define dout(l) if (l<=g_conf.debug || l<=g_conf.debug_mds_log) cout << "mds" << mds->get_nodeid() << ".logstream "
|
||||
|
||||
|
||||
|
||||
|
@ -145,15 +145,17 @@ void MDBalancer::send_heartbeat()
|
||||
|
||||
void MDBalancer::handle_heartbeat(MHeartbeat *m)
|
||||
{
|
||||
dout(5) << "=== got heartbeat " << m->get_beat() << " from " << m->get_source() << " " << m->get_load() << endl;
|
||||
dout(5) << "=== got heartbeat " << m->get_beat() << " from " << MSG_ADDR_NICE(m->get_source()) << " " << m->get_load() << endl;
|
||||
|
||||
if (!mds->mdcache->get_root()) {
|
||||
dout(10) << "no root on handle" << endl;
|
||||
mds->mdcache->open_root(new C_MDS_RetryMessage(mds, m));
|
||||
return;
|
||||
}
|
||||
|
||||
int who = MSG_ADDR_NUM(m->get_source());
|
||||
|
||||
if (m->get_source() == 0) {
|
||||
if (who == 0) {
|
||||
dout(10) << " from mds0, new epoch" << endl;
|
||||
beat_epoch = m->get_beat();
|
||||
send_heartbeat();
|
||||
@ -161,8 +163,8 @@ void MDBalancer::handle_heartbeat(MHeartbeat *m)
|
||||
show_imports();
|
||||
}
|
||||
|
||||
mds_load[ m->get_source() ] = m->get_load();
|
||||
mds_import_map[ m->get_source() ] = m->get_import_map();
|
||||
mds_load[ who ] = m->get_load();
|
||||
mds_import_map[ who ] = m->get_import_map();
|
||||
|
||||
//cout << " load is " << load << " have " << mds_load.size() << endl;
|
||||
|
||||
|
@ -105,7 +105,7 @@ using namespace std;
|
||||
|
||||
#include "config.h"
|
||||
#undef dout
|
||||
#define dout(l) if (l<=g_conf.debug) cout << "mds" << mds->get_nodeid() << ".cache "
|
||||
#define dout(l) if (l<=g_conf.debug || l <= g_conf.debug_mds) cout << "mds" << mds->get_nodeid() << ".cache "
|
||||
|
||||
|
||||
|
||||
@ -2310,12 +2310,13 @@ void MDCache::handle_inode_update(MInodeUpdate *m)
|
||||
void MDCache::handle_cache_expire(MCacheExpire *m)
|
||||
{
|
||||
int from = m->get_from();
|
||||
int source = MSG_ADDR_NUM(m->get_source());
|
||||
map<int, MCacheExpire*> proxymap;
|
||||
|
||||
if (m->get_from() == m->get_source()) {
|
||||
if (m->get_from() == source) {
|
||||
dout(7) << "cache_expire from " << from << endl;
|
||||
} else {
|
||||
dout(7) << "cache_expire from " << from << " via " << m->get_source() << endl;
|
||||
dout(7) << "cache_expire from " << from << " via " << source << endl;
|
||||
}
|
||||
|
||||
// inodes
|
||||
@ -3092,7 +3093,8 @@ void MDCache::handle_rename_notify_ack(MRenameNotifyAck *m)
|
||||
assert(in);
|
||||
dout(7) << "handle_rename_notify_ack on " << *in << endl;
|
||||
|
||||
in->rename_waiting_for_ack.erase(m->get_source());
|
||||
int source = MSG_ADDR_NUM(m->get_source());
|
||||
in->rename_waiting_for_ack.erase(source);
|
||||
if (in->rename_waiting_for_ack.empty()) {
|
||||
// last one!
|
||||
in->finish_waiting(CINODE_WAIT_RENAMENOTIFYACK, 0);
|
||||
@ -3219,7 +3221,7 @@ void MDCache::handle_rename(MRename *m)
|
||||
// HACK
|
||||
bufferlist bufstate;
|
||||
bufstate.claim_append(m->get_inode_state());
|
||||
decode_import_inode(destdn, bufstate, off, m->get_source());
|
||||
decode_import_inode(destdn, bufstate, off, MSG_ADDR_NUM(m->get_source()));
|
||||
|
||||
CInode *in = destdn->inode;
|
||||
assert(in);
|
||||
@ -3241,11 +3243,11 @@ void MDCache::handle_rename(MRename *m)
|
||||
// ok, send notifies.
|
||||
set<int> notify;
|
||||
for (int i=0; i<mds->get_cluster()->get_num_mds(); i++) {
|
||||
if (i != m->get_source() && // except the source
|
||||
if (i != MSG_ADDR_NUM(m->get_source()) && // except the source
|
||||
i != mds->get_nodeid()) // and the dest
|
||||
notify.insert(i);
|
||||
}
|
||||
file_rename_notify(in, srcdir, srcname, destdir, destname, notify, m->get_source());
|
||||
file_rename_notify(in, srcdir, srcname, destdir, destname, notify, MSG_ADDR_NUM(m->get_source()));
|
||||
|
||||
delete m;
|
||||
}
|
||||
@ -5713,7 +5715,7 @@ void MDCache::export_dir(CDir *dir,
|
||||
// send ExportDirDiscover (ask target)
|
||||
export_gather[dir].insert(dest);
|
||||
mds->messenger->send_message(new MExportDirDiscover(dir->inode),
|
||||
dest, MDS_PORT_CACHE, MDS_PORT_CACHE);
|
||||
MSG_ADDR_MDS(dest), MDS_PORT_CACHE, MDS_PORT_CACHE);
|
||||
dir->auth_pin(); // pin dir, to hang up our freeze (unpin on prep ack)
|
||||
|
||||
// take away the popularity we're sending. FIXME: do this later?
|
||||
@ -5736,7 +5738,7 @@ void MDCache::handle_export_dir_discover_ack(MExportDirDiscoverAck *m)
|
||||
CDir *dir = in->dir;
|
||||
assert(dir);
|
||||
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
assert(export_gather[dir].count(from));
|
||||
export_gather[dir].erase(from);
|
||||
|
||||
@ -5836,7 +5838,7 @@ void MDCache::handle_export_dir_prep_ack(MExportDirPrepAck *m)
|
||||
dout(7) << "export_dir_prep_ack " << *dir << ", starting export" << endl;
|
||||
|
||||
// start export.
|
||||
export_dir_go(dir, m->get_source());
|
||||
export_dir_go(dir, MSG_ADDR_NUM(m->get_source()));
|
||||
|
||||
// done
|
||||
delete m;
|
||||
@ -6181,7 +6183,7 @@ void MDCache::handle_export_dir_notify_ack(MExportDirNotifyAck *m)
|
||||
assert(dir->is_frozen_tree_root()); // i'm exporting!
|
||||
|
||||
// remove from waiting list
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
assert(export_notify_ack_waiting[dir].count(from));
|
||||
export_notify_ack_waiting[dir].erase(from);
|
||||
|
||||
@ -6304,7 +6306,7 @@ public:
|
||||
|
||||
void MDCache::handle_export_dir_discover(MExportDirDiscover *m)
|
||||
{
|
||||
assert(m->get_source() != mds->get_nodeid());
|
||||
assert(MSG_ADDR_NUM(m->get_source()) != mds->get_nodeid());
|
||||
|
||||
dout(7) << "handle_export_dir_discover on " << m->get_path() << endl;
|
||||
|
||||
@ -6362,7 +6364,7 @@ void MDCache::handle_export_dir_discover_2(MExportDirDiscover *m, CInode *in, in
|
||||
|
||||
void MDCache::handle_export_dir_prep(MExportDirPrep *m)
|
||||
{
|
||||
assert(m->get_source() != mds->get_nodeid());
|
||||
assert(MSG_ADDR_NUM(m->get_source()) != mds->get_nodeid());
|
||||
|
||||
CInode *diri = get_inode(m->get_ino());
|
||||
assert(diri);
|
||||
@ -6537,7 +6539,7 @@ void MDCache::handle_export_dir(MExportDir *m)
|
||||
CDir *dir = diri->dir;
|
||||
assert(dir);
|
||||
|
||||
int oldauth = m->get_source();
|
||||
int oldauth = MSG_ADDR_NUM(m->get_source());
|
||||
dout(7) << "handle_export_dir, import " << *dir << " from " << oldauth << endl;
|
||||
assert(dir->is_auth() == false);
|
||||
|
||||
@ -6652,7 +6654,7 @@ void MDCache::handle_export_dir(MExportDir *m)
|
||||
mds->balancer->add_import(dir);
|
||||
|
||||
// send notify's etc.
|
||||
dout(7) << "sending notifyack for " << *dir << " to old auth " << m->get_source() << endl;
|
||||
dout(7) << "sending notifyack for " << *dir << " to old auth " << MSG_ADDR_NUM(m->get_source()) << endl;
|
||||
mds->messenger->send_message(new MExportDirNotifyAck(dir->inode->ino()),
|
||||
m->get_source(), MDS_PORT_CACHE,
|
||||
MDS_PORT_CACHE);
|
||||
@ -6662,9 +6664,9 @@ void MDCache::handle_export_dir(MExportDir *m)
|
||||
it != dir->open_by.end();
|
||||
it++) {
|
||||
assert( *it != mds->get_nodeid() );
|
||||
if ( *it == m->get_source() ) continue; // not to old auth.
|
||||
if ( *it == MSG_ADDR_NUM(m->get_source()) ) continue; // not to old auth.
|
||||
|
||||
MExportDirNotify *notify = new MExportDirNotify(dir->ino(), m->get_source(), mds->get_nodeid());
|
||||
MExportDirNotify *notify = new MExportDirNotify(dir->ino(), MSG_ADDR_NUM(m->get_source()), mds->get_nodeid());
|
||||
notify->copy_exports(m->get_exports());
|
||||
|
||||
if (g_conf.mds_verify_export_dirauth)
|
||||
@ -7230,7 +7232,7 @@ void MDCache::hash_dir(CDir *dir)
|
||||
if (i == mds->get_nodeid()) continue; // except me
|
||||
hash_gather[dir].insert(i);
|
||||
mds->messenger->send_message(new MHashDirDiscover(dir->inode),
|
||||
i, MDS_PORT_CACHE, MDS_PORT_CACHE);
|
||||
MSG_ADDR_MDS(i), MDS_PORT_CACHE, MDS_PORT_CACHE);
|
||||
}
|
||||
dir->auth_pin(); // pin until discovers are all acked.
|
||||
|
||||
@ -7258,7 +7260,7 @@ void MDCache::handle_hash_dir_discover_ack(MHashDirDiscoverAck *m)
|
||||
CDir *dir = in->dir;
|
||||
assert(dir);
|
||||
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
assert(hash_gather[dir].count(from));
|
||||
hash_gather[dir].erase(from);
|
||||
|
||||
@ -7368,7 +7370,7 @@ void MDCache::handle_hash_dir_prep_ack(MHashDirPrepAck *m)
|
||||
CDir *dir = in->dir;
|
||||
assert(dir);
|
||||
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
|
||||
assert(hash_gather[dir].count(from) == 1);
|
||||
hash_gather[dir].erase(from);
|
||||
@ -7578,7 +7580,7 @@ void MDCache::handle_hash_dir_ack(MHashDirAck *m)
|
||||
assert(dir->is_hashed());
|
||||
assert(dir->is_hashing());
|
||||
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
assert(hash_gather[dir].count(from) == 1);
|
||||
hash_gather[dir].erase(from);
|
||||
|
||||
@ -7655,12 +7657,13 @@ void MDCache::handle_hash_dir_notify(MHashDirNotify *m)
|
||||
dout(5) << "handle_hash_dir_notify " << *dir << endl;
|
||||
int from = m->get_from();
|
||||
|
||||
int source = MSG_ADDR_NUM(m->get_source());
|
||||
if (dir->is_auth()) {
|
||||
// gather notifies
|
||||
assert(dir->is_hashed());
|
||||
|
||||
assert( hash_notify_gather[dir][from].count(m->get_source()) );
|
||||
hash_notify_gather[dir][from].erase(m->get_source());
|
||||
assert( hash_notify_gather[dir][from].count(source) );
|
||||
hash_notify_gather[dir][from].erase(source);
|
||||
|
||||
if (hash_notify_gather[dir][from].empty()) {
|
||||
dout(7) << "last notify from " << from << endl;
|
||||
@ -7756,7 +7759,7 @@ public:
|
||||
|
||||
void MDCache::handle_hash_dir_discover(MHashDirDiscover *m)
|
||||
{
|
||||
assert(m->get_source() != mds->get_nodeid());
|
||||
assert(MSG_ADDR_NUM(m->get_source()) != mds->get_nodeid());
|
||||
|
||||
dout(7) << "handle_hash_dir_discover on " << m->get_path() << endl;
|
||||
|
||||
@ -7911,7 +7914,7 @@ void MDCache::handle_hash_dir(MHashDir *m)
|
||||
assert(dir->is_hashing());
|
||||
|
||||
dout(5) << "handle_hash_dir " << *dir << endl;
|
||||
int oldauth = m->get_source();
|
||||
int oldauth = MSG_ADDR_NUM(m->get_source());
|
||||
|
||||
// content
|
||||
import_hashed_content(dir, m->get_state(), m->get_nden(), oldauth);
|
||||
@ -7933,7 +7936,7 @@ void MDCache::handle_hash_dir(MHashDir *m)
|
||||
dout(7) << "sending notifies" << endl;
|
||||
for (int i=0; i<mds->get_cluster()->get_num_mds(); i++) {
|
||||
if (i == mds->get_nodeid()) continue;
|
||||
if (i == m->get_source()) continue;
|
||||
if (i == MSG_ADDR_NUM(m->get_source())) continue;
|
||||
mds->messenger->send_message(new MHashDirNotify(dir->ino(), mds->get_nodeid()),
|
||||
MSG_ADDR_MDS(i), MDS_PORT_CACHE, MDS_PORT_CACHE);
|
||||
}
|
||||
@ -8063,7 +8066,7 @@ void MDCache::handle_unhash_dir_prep_ack(MUnhashDirPrepAck *m)
|
||||
CDir *dir = in->dir;
|
||||
assert(dir);
|
||||
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
dout(7) << "handle_unhash_dir_prep_ack from " << from << " " << *dir << endl;
|
||||
|
||||
if (!m->did_assim()) {
|
||||
@ -8176,7 +8179,7 @@ void MDCache::handle_unhash_dir_ack(MUnhashDirAck *m)
|
||||
assert(dir->is_hashed());
|
||||
|
||||
// assimilate content
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
import_hashed_content(dir, m->get_state(), m->get_nden(), from);
|
||||
delete m;
|
||||
|
||||
@ -8251,7 +8254,7 @@ void MDCache::handle_unhash_dir_notify_ack(MUnhashDirNotifyAck *m)
|
||||
assert(dir->is_frozen_dir());
|
||||
|
||||
// done?
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
assert(hash_gather[dir].count(from));
|
||||
hash_gather[dir].erase(from);
|
||||
delete m;
|
||||
@ -8580,7 +8583,7 @@ void MDCache::handle_unhash_dir_notify(MUnhashDirNotify *m)
|
||||
assert(dir->is_unhashing());
|
||||
assert(!dir->is_auth());
|
||||
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
assert(hash_gather[dir].count(from) == 1);
|
||||
hash_gather[dir].erase(from);
|
||||
delete m;
|
||||
|
@ -35,7 +35,7 @@ LogType mdlog_logtype;
|
||||
|
||||
#include "config.h"
|
||||
#undef dout
|
||||
#define dout(l) if (mds->get_nodeid() == 0 && (l<=g_conf.debug || l<=g_conf.debug_mds_log)) cout << "mds" << mds->get_nodeid() << ".log "
|
||||
#define dout(l) if (l<=g_conf.debug || l<=g_conf.debug_mds_log) cout << "mds" << mds->get_nodeid() << ".log "
|
||||
|
||||
// cons/des
|
||||
|
||||
|
@ -75,20 +75,22 @@ LogType mds_logtype, mds_cache_logtype;
|
||||
|
||||
#include "config.h"
|
||||
#undef dout
|
||||
#define dout(l) if (l<=g_conf.debug) cout << "mds" << whoami << " "
|
||||
#define dout3(l,mds) if (l<=g_conf.debug) cout << "mds" << mds->get_nodeid() << " "
|
||||
#define dout(l) if (l<=g_conf.debug || l <= g_conf.debug_mds) cout << "mds" << whoami << " "
|
||||
#define dout3(l,mds) if (l<=g_conf.debug || l <= g_conf.debug_mds) cout << "mds" << mds->get_nodeid() << " "
|
||||
|
||||
|
||||
|
||||
/*
|
||||
void C_MDS_RetryMessage::redelegate(MDS *mds, int newmds)
|
||||
{
|
||||
// forward message to new mds
|
||||
dout3(5,mds) << "redelegating context " << this << " by forwarding message " << m << " to mds" << newmds << endl;
|
||||
|
||||
mds->messenger->send_message(m,
|
||||
newmds, m->get_dest_port(),
|
||||
MSG_ADDR_MDS(newmds), m->get_dest_port(),
|
||||
MDS_PORT_MAIN); // mostly meaningless
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@ -1324,7 +1326,7 @@ void MDS::handle_hash_readdir_reply(MHashReaddirReply *m)
|
||||
assert(dir->is_hashed());
|
||||
|
||||
// move items to hashed_readdir gather
|
||||
int from = m->get_source();
|
||||
int from = MSG_ADDR_NUM(m->get_source());
|
||||
assert(dir->hashed_readdir.count(from) == 0);
|
||||
dir->hashed_readdir[from].splice(dir->hashed_readdir[from].begin(),
|
||||
m->get_items());
|
||||
|
@ -304,9 +304,9 @@ class C_MDS_RetryRequest : public Context {
|
||||
mds->dispatch_request(req, ref);
|
||||
}
|
||||
|
||||
virtual bool can_redelegate() {
|
||||
/*virtual bool can_redelegate() {
|
||||
return true;
|
||||
}
|
||||
}*/
|
||||
};
|
||||
|
||||
|
||||
@ -323,11 +323,13 @@ public:
|
||||
mds->my_dispatch(m);
|
||||
}
|
||||
|
||||
/*
|
||||
virtual bool can_redelegate() {
|
||||
return true;
|
||||
}
|
||||
|
||||
virtual void redelegate(MDS *mds, int newmds);
|
||||
*/
|
||||
};
|
||||
|
||||
|
||||
|
13
ceph/script/profonly.pl
Executable file
13
ceph/script/profonly.pl
Executable file
@ -0,0 +1,13 @@
|
||||
#!/usr/bin/perl
|
||||
|
||||
my $rank = shift @ARGV;
|
||||
my $args = join(' ',@ARGV);
|
||||
if ($rank == $ENV{MPD_JRANK}) {
|
||||
$c = "LD_PRELOAD=$ENV{'HOME'}/csl/obsd/src/pmds/gprof-helper.so ./tcpsyn $args";
|
||||
|
||||
} else {
|
||||
$c = "./tcpsyn.nopg $args";
|
||||
}
|
||||
|
||||
#print "$rank: $c\n";
|
||||
system $c;
|
@ -44,6 +44,7 @@ my ($jname) = $job =~ /\/(\w+)$/;
|
||||
$jname ||= $job;
|
||||
die "not jobs/?" unless defined $job;
|
||||
my $out = "log/$job.$tag";
|
||||
my $relout = "$job.$tag";
|
||||
|
||||
|
||||
|
||||
@ -172,7 +173,7 @@ sub run {
|
||||
|
||||
$c .= ' ' . $h->{'custom'} if $h->{'custom'};
|
||||
|
||||
$c .= " --log_name $fn";
|
||||
$c .= " --log_name $relout/$keys";
|
||||
|
||||
|
||||
if ($sim->{'_psub'}) {
|
||||
|
Loading…
Reference in New Issue
Block a user