qiushanggao [Tue, 20 Jan 2015 02:27:50 +0000 (10:27 +0800)]
Fix bug: When run Test_filejournal testcase with gtest argument, all of testcases is failed.
when run testcase with gtest argument, for example, with argument --gtest_output=xml:/root/reports/ceph_test_cls_version.xml,
then the test result is failed, because of the test program use the first argument as the journal file name. Signed-off-by: shanggao qiu <qiushanggao@qq.com>
Dong Yuan [Wed, 10 Dec 2014 10:02:51 +0000 (10:02 +0000)]
osd: build fields for Transaction::iterator when tbl is used
When tbl is used (for compatibility), the Transaction::begin method need
to build all fields used by iterator. That includes: coll_index,
object_index, data_bl, op_bl, etc.)
Dong Yuan [Tue, 2 Dec 2014 17:08:44 +0000 (17:08 +0000)]
osd: Transaction::append & Transaction::swap
Finish append and swap for new Transaction encode/decode layout.
Since append will modify the op_bl now, we changed the order of append
and swap in ReplicatedBackend::sub_op_modify and
ReplicatedBackend::submit_transaction to avoid append call on op_t, so
the op_t can be encode in message.
Dong Yuan [Mon, 1 Dec 2014 10:58:56 +0000 (10:58 +0000)]
osd: new Transaction::iterator interface
This patch add new Transaction::iterator interface according to new
encode/decode layout. The new iterator give the whole Op struct in a
single decode_op method.
All ObjectStore Impl (FileStore/MemStore/KeyValueStore) is also changed
to use the new interface.
Dong Yuan [Thu, 27 Nov 2014 14:52:36 +0000 (14:52 +0000)]
osd: add encode/deocde impl for new layout
When use_tbl is true, Transaction::encode will give the same result as
before, while when use_tbl is false, Transaction::encode will use new
field and logic to encode and all related methods such as
get_encoded_bytes, get_data_offset will do the same.
Dong Yuan [Wed, 26 Nov 2014 17:58:50 +0000 (17:58 +0000)]
osd: new format for Transaction encode/decode
This patch add a new fixed size struct Transaction::Op to represent
all actions.
All coll and ghobject used by the transaction are keeped in two maps:
coll: map<coll_t, __le32> coll_index;
object: map<ghobject_t, __le32> object_index;
And the Op struct use the map value(__le32) to refer coll and object,
so each coll and object is only need to encode once in the transaction.
Other variable-size fields(key/value/data) is encoded in bufferlist
data_bl.
Ken Dreyer [Tue, 6 Jan 2015 15:16:20 +0000 (08:16 -0700)]
qa: drop tiobench suite
The tiobench software has been abandoned upstream for years. Fedora and
Debian are no longer shipping the tiobench package, so we've had to
carry the package ourselves in the Ceph project, and we're trying to
slim down our dependencies where it makes sense to do so.
Xiaoxi Chen [Fri, 21 Nov 2014 00:34:54 +0000 (08:34 +0800)]
Add MOSDRepOp and MOSDRepOpReply
Add the two new message type and change the corresponding code flow as well.
Basically the idea to have MOSDRepOp is to seperate subop(read/write)
out of other subop(pull/push,etc), so that we can cleanup some unused fields in
the message type, then save some encoding/decoding overhead.
The backward compatibility is also remian, if talking with old version OSD who
doesn't support osd_client_subop/subopreply, will fall back to osd_subop/subopreply.
Sage: rename MOSDClientSubOp -> MOSDRepOp
Signed-off-by: Xiaoxi Chen <xiaoxi.chen@intel.com> Signed-off-by: Sage Weil <sage@redhat.com>
Ken Dreyer [Mon, 5 Jan 2015 19:11:00 +0000 (12:11 -0700)]
configure: show pkg names when libkeyutils is missing
Prior to this commit, when ./configure can't find libkeyutils, it would
bail out with a terse error message.
Some of the other library checks helpfully print the DEB and RPM package
names in parentheses. Add the DEB and RPM package names to the
libkeyutils check.
Reported-by: Pankaj Garg <Pankaj.Garg@caviumnetworks.com> Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
Jianpeng Ma [Mon, 5 Jan 2015 12:51:21 +0000 (20:51 +0800)]
test/bufferlist: For root, don't do permission operation for read_file
case.
For root user, it meet those error:
test/bufferlist.cc:1880: Failure
Value of: bl.read_file("testfile", &error)
Actual: 0
Expected: -13
test/bufferlist.cc:1884: Failure
Value of: bl.length()
Actual: 8
Expected: (unsigned)4
Which is: 4
test/bufferlist.cc:1886: Failure
Value of: actual
Actual: "ABC
ABC
"
Expected: "ABC\n"
Which is: "ABC
Signed-off-by: Jianpeng Ma <jianpeng.ma@intel.com>
Mykola Golub [Tue, 30 Dec 2014 09:59:31 +0000 (11:59 +0200)]
qa: refactor 'ceph -w' magic in test_mon_misc by introducing helper
functions ceph_watch_start and ceph_watch_wait so they can be reused
in other tests.
Ken Dreyer [Fri, 2 Jan 2015 17:32:26 +0000 (10:32 -0700)]
doc: rm reference to old Ubuntu release
Remove the reference to "Ubuntu 12.10" since this is EOL.
Clarify that we only recommend Ubuntu LTS releases.
(Since this information has a tendancy to become stale, perhaps this
whole paragraph should be removed here and we should simply point at the
main OS Recommendations page.)
Loic Dachary [Thu, 1 Jan 2015 19:52:18 +0000 (20:52 +0100)]
debian: create a repository from sources
Create a debian repository suitable for inclusion in
/etc/apt/sources.list, for the current distribution and using the git
clone from the current working directory.
It is meant to quickly provide teuthology with the packages to run a
job.
Sage Weil [Mon, 29 Dec 2014 23:47:28 +0000 (15:47 -0800)]
client: fix quota signed/unsigned warning
client/Client.cc: In member function 'bool Client::is_quota_bytes_exceeded(Inode*, uint64_t)':
client/Client.cc:10393:66: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (quota->max_bytes && (rstat->rbytes + new_bytes) > quota->max_bytes)
Ning Yao [Fri, 26 Dec 2014 04:20:35 +0000 (04:20 +0000)]
PG:: filter_snapc: Return immediately if no snapc need to trim
we can return immediately if no snapc need to trim. Do not iterater snapc vector and do extra judgement and ops.
Sage Weil [Tue, 23 Dec 2014 20:39:08 +0000 (12:39 -0800)]
mon: provide encoded canonical full OSDMap from primary
Currently we make each monitor apply the incremental and encode the full
map locally. The original motivation was to save bandwidth, but the
savings are minimal to modest and the complexity associated with doing this
is huge.
This strategy also causes problems now that we have OSDMap crc's and old
mons/clusters may have diverging full OSDMaps due to mixed version
clusters. See #10422
Instead, include the encoded full map in the paxos transaction. We will
still apply the incremental and check the crc, but if it fails and we have
the correct version, reload it from disk and move on. If we don't, we
will continue as we have before--the primary mon doesn't have support for
crc's yet. When it does we will start verifying and/or get our
full map back into sync.
Fixes: #10422 Signed-off-by: Sage Weil <sage@redhat.com>
Mykola Golub [Tue, 23 Dec 2014 11:39:33 +0000 (13:39 +0200)]
10132: osd: tries to set ioprio when the config option is blank
According to documentation, ioprio params will only be used if both
osd disk thread ioprio class and osd disk thread ioprio priority are
set to a non default value.
So, add a proper check and do not generate "set_disk_tp_priority(22)
Invalid argument" warning for the default settings.