]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
9 years agoosd/ReplicatedPG:wipe off param op from generate_subop() 10811/head
jimifm [Mon, 22 Aug 2016 12:31:19 +0000 (20:31 +0800)]
osd/ReplicatedPG:wipe off param op from generate_subop()

Signed-off-by: jimifm <hong.zhangoole@gmail.com>
9 years agoMerge pull request #10806 from tchaikov/wip-17087
Josh Durgin [Mon, 22 Aug 2016 07:21:35 +0000 (00:21 -0700)]
Merge pull request #10806 from tchaikov/wip-17087

test/librados: rados_connect() should succeed

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
9 years agotest/librados: rados_connect() should succeed 10806/head
Kefu Chai [Mon, 22 Aug 2016 03:57:17 +0000 (11:57 +0800)]
test/librados: rados_connect() should succeed

the "rados_osd_op_timeout" setting does not apply to the initial connection.
this regression was introduced by 6c67073

Fixes: http://tracker.ceph.com/issues/17087
Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10771 from xiexingguo/xxg-wip-fix-bluerockenv
Sage Weil [Sun, 21 Aug 2016 22:59:46 +0000 (17:59 -0500)]
Merge pull request #10771 from xiexingguo/xxg-wip-fix-bluerockenv

os/bluestore: misc fixes

Reviewed-by: Sage Weil <sage@redhat.com>
9 years agoMerge pull request #10435 from ceph/wip-debian-rbdmap-service
Kefu Chai [Sun, 21 Aug 2016 10:23:08 +0000 (18:23 +0800)]
Merge pull request #10435 from ceph/wip-debian-rbdmap-service

debian: replace SysV rbdmap with systemd service

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10725 from tchaikov/wip-17023
Kefu Chai [Sun, 21 Aug 2016 10:21:14 +0000 (18:21 +0800)]
Merge pull request #10725 from tchaikov/wip-17023

osd: subscribe for old osdmaps when pause flag is set

Reviewed-by: Samuel Just <sjust@redhat.com>
9 years agoMerge pull request #10739 from xiexingguo/xxg-wip-osdmon-2016-08-15
Kefu Chai [Sun, 21 Aug 2016 10:19:40 +0000 (18:19 +0800)]
Merge pull request #10739 from xiexingguo/xxg-wip-osdmon-2016-08-15

osd/OSDMonitor: misc. cleanups

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10753 from tchaikov/wip-16982
Kefu Chai [Sun, 21 Aug 2016 10:18:50 +0000 (18:18 +0800)]
Merge pull request #10753 from tchaikov/wip-16982

osd: bail out if transaction size overflows

Reviewed-by: Samuel Just <sjust@redhat.com>
9 years agoMerge pull request #10751 from ceph/wip-kefu-testing
Dan Mick [Fri, 19 Aug 2016 21:00:23 +0000 (14:00 -0700)]
Merge pull request #10751 from ceph/wip-kefu-testing

rgw: do not try to encode or decode time_t and fix compiling warnings

Reviewed-by: Dan Mick <dmick@redhat.com>
9 years agoMerge pull request #10766 from liewegas/wip-bluestore-trivial
Sage Weil [Fri, 19 Aug 2016 17:21:46 +0000 (12:21 -0500)]
Merge pull request #10766 from liewegas/wip-bluestore-trivial

os/bluestore/BlueFS: disable buffered io

9 years agoMerge pull request #10773 from xiexingguo/xxg-wip-bluestore-2016-08-18
Sage Weil [Fri, 19 Aug 2016 17:17:06 +0000 (12:17 -0500)]
Merge pull request #10773 from xiexingguo/xxg-wip-bluestore-2016-08-18

os/bluestore: fix decoding hash of bnode

Reviewed-by: Sage Weil <sage@redhat.com>
9 years agoMerge pull request #10780 from liewegas/wip-bluestore-finishers
Sage Weil [Fri, 19 Aug 2016 17:15:17 +0000 (12:15 -0500)]
Merge pull request #10780 from liewegas/wip-bluestore-finishers

os/bluestore: add multiple finishers to bluestore

Reviewed-by: Sage Weil <sage@redhat.com>
9 years agoMerge pull request #10592 from michelmno/forpull
Nathan Cutler [Fri, 19 Aug 2016 15:36:58 +0000 (17:36 +0200)]
Merge pull request #10592 from michelmno/forpull

LTTng-UST disabled for openSUSE

Reviewed-by: Nathan Cutler <ncutler@suse.com>
9 years agoMerge pull request #10788 from ceph/wip-cmake
Kefu Chai [Fri, 19 Aug 2016 15:22:02 +0000 (23:22 +0800)]
Merge pull request #10788 from ceph/wip-cmake

debian and cmake cleanups

Reviewed-by: Oleh Prypin <oleh@pryp.in>
9 years agoMerge pull request #10762 from dillaman/wip-16654
Mykola Golub [Fri, 19 Aug 2016 13:01:45 +0000 (16:01 +0300)]
Merge pull request #10762 from dillaman/wip-16654

librbd: cache was not switching to writeback after first flush

Reviewed-by: Mykola Golub <mgolub@mirantis.com>
9 years agoMerge pull request #10741 from minshenglin/remove_non_exists_options
Kefu Chai [Fri, 19 Aug 2016 09:38:42 +0000 (17:38 +0800)]
Merge pull request #10741 from minshenglin/remove_non_exists_options

doc: remove the description of deleted options

Reviewed-by: Nathan Cutler <ncutler@suse.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agoos/filestore/FileJournal: bail out if transaction is too large 10753/head
Kefu Chai [Fri, 19 Aug 2016 06:50:38 +0000 (14:50 +0800)]
os/filestore/FileJournal: bail out if transaction is too large

if a transaction is too large to fit in the FileJournal's ring buffer,
we will wait. but if its size is larger than the max_size, it's likely
due to a bug or an invalid setting. in that case, we'd better fail
earlier.

Fixes: http://tracker.ceph.com/issues/16982
Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agoosd: bail out if transaction size overflows
Kefu Chai [Wed, 17 Aug 2016 11:39:12 +0000 (19:39 +0800)]
osd: bail out if transaction size overflows

with a large MOSDMap message, the transaction size could be greater than
UINT_MAX. so fail early with error messages.

Fixes: http://tracker.ceph.com/issues/16982
Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agoos/bluestore: fix assert 10771/head
xie xingguo [Fri, 19 Aug 2016 06:13:05 +0000 (14:13 +0800)]
os/bluestore: fix assert

This assert is used to guarantee that we don't access violation
but currently has no effect.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoos/bluestore: use hex if we are running out of space
xie xingguo [Fri, 19 Aug 2016 06:11:58 +0000 (14:11 +0800)]
os/bluestore: use hex if we are running out of space

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoos/bluestore: use bluefs_max_prefetch for log file prefetch
xie xingguo [Fri, 19 Aug 2016 03:20:31 +0000 (11:20 +0800)]
os/bluestore: use bluefs_max_prefetch for log file prefetch

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoos/bluestore: fix race condition during get_fs_usage()
xie xingguo [Fri, 19 Aug 2016 02:30:49 +0000 (10:30 +0800)]
os/bluestore: fix race condition during get_fs_usage()

file_map should be accessed under the protection
of the global lock.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoMerge pull request #10591 from xiexingguo/xxg-wip-osdmon-2016-08-05
Kefu Chai [Fri, 19 Aug 2016 03:58:42 +0000 (11:58 +0800)]
Merge pull request #10591 from xiexingguo/xxg-wip-osdmon-2016-08-05

mon: misc cleanups

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10516 from wjwithagen/wip-wjw-freebsd-pidfile
Kefu Chai [Fri, 19 Aug 2016 03:58:15 +0000 (11:58 +0800)]
Merge pull request #10516 from wjwithagen/wip-wjw-freebsd-pidfile

src/global/pidfile.cc: Assign elements in structures individually

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10451 from songbaisen/c0
Kefu Chai [Fri, 19 Aug 2016 03:57:37 +0000 (11:57 +0800)]
Merge pull request #10451 from songbaisen/c0

tools: fix the core dump when get the crushmap do not exist

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #9694 from renhwztetecs/renhw-wip-librados-iotest
Kefu Chai [Fri, 19 Aug 2016 03:57:07 +0000 (11:57 +0800)]
Merge pull request #9694 from renhwztetecs/renhw-wip-librados-iotest

test: add the necessary judgment

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
9 years agodebian: drop python-argparse dependency 10788/head
Kefu Chai [Fri, 19 Aug 2016 02:42:14 +0000 (10:42 +0800)]
debian: drop python-argparse dependency

and bump up the dependency of python version to 2.7.
py2.6 support was only necessary for older (now unsupported) distro
versions.

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agodebian: exclude python3* packages in dh_shlibdeps
Kefu Chai [Fri, 19 Aug 2016 02:33:11 +0000 (10:33 +0800)]
debian: exclude python3* packages in dh_shlibdeps

since we are not using subvar of ${shlibs:Depends} in python3-* packages,
just exclude them in dh_shlibdeps.
this silences warnings like
```
warning: dpkg-gencontrol: package python3-cephfs: unused substitution
variable ${shlibs:Depends}
```

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agodebian: enable dh_python3 for python3 packages
Kefu Chai [Fri, 19 Aug 2016 02:31:40 +0000 (10:31 +0800)]
debian: enable dh_python3 for python3 packages

so we can use subvars like ${python3:Depends} in debian/control.
this silences the warnings like:
```
warning: dpkg-gencontrol: Depends field of package python3-cephfs:
unknown substitution variable ${python3:Depends}
```

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agocmake: fix unmatched endforeach
Kefu Chai [Fri, 19 Aug 2016 01:51:11 +0000 (09:51 +0800)]
cmake: fix unmatched endforeach

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agoos/bluestore: fix decoding hash of bnode 10773/head
xie xingguo [Thu, 18 Aug 2016 10:12:23 +0000 (18:12 +0800)]
os/bluestore: fix decoding hash of bnode

We encode reversed bits of hash and then write it onto disk,
therefore we shall decode and then reserse to get it back.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoMerge pull request #10782 from BlaXpirit/rados-test-py3
Josh Durgin [Thu, 18 Aug 2016 21:19:45 +0000 (14:19 -0700)]
Merge pull request #10782 from BlaXpirit/rados-test-py3

qa/workunits/rados/test_python.sh: Allow specifying Python executable

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
9 years agoqa/workunits/rados/test_python.sh: Allow specifying Python executable 10782/head
Oleh Prypin [Thu, 18 Aug 2016 20:36:30 +0000 (23:36 +0300)]
qa/workunits/rados/test_python.sh: Allow specifying Python executable
(through an environment variable)

Signed-off-by: Oleh Prypin <oleh@pryp.in>
9 years agoMerge pull request #10777 from linuxbox2/rgw-token-base64
Casey Bodley [Thu, 18 Aug 2016 19:09:30 +0000 (15:09 -0400)]
Merge pull request #10777 from linuxbox2/rgw-token-base64

rgw ldap:  protect rgw::from_base64 from non-base64 input

Reviewed-by: Casey Bodley <cbodley@redhat.com>
9 years agoMerge pull request #10772 from ceph/wip-cmake
Casey Bodley [Thu, 18 Aug 2016 18:48:10 +0000 (14:48 -0400)]
Merge pull request #10772 from ceph/wip-cmake

cmake: recompile erasure src for different variants

Reviewed-by: Casey Bodley <cbodley@redhat.com>
9 years agoos/bluestore: add multiple finishers to bluestore 10780/head
Ilsoo Byun [Thu, 18 Aug 2016 18:29:38 +0000 (14:29 -0400)]
os/bluestore: add multiple finishers to bluestore

- The single finisher of a bluestore can be a bottleneck
when using an SSD as a backend device. If too much load
is given to the single finisher, client-side IO latency
increases. So we add multiple finishers to the
bluestore, which shows better performance.

- 'bluestore_shard_finishers' option is added to
be able to configure wheather finsihers is multiple or
not.

- a finisher is selected according to the shard id of a
sequencer.

- the number of finishers is decided by
osd_op_num_shards.

Signed-off-by: Ilsoo Byun <ilsoo.byun@sk.com>
9 years agoos/bluestore/BlueFS: rename buffered_io option 10766/head
Sage Weil [Wed, 17 Aug 2016 16:35:43 +0000 (12:35 -0400)]
os/bluestore/BlueFS: rename buffered_io option

This is not a bluestore option.

Signed-off-by: Sage Weil <sage@redhat.com>
9 years agoos/bluestore/BlueFS: do direct io by default (not buffered)
Sage Weil [Wed, 17 Aug 2016 16:35:12 +0000 (12:35 -0400)]
os/bluestore/BlueFS: do direct io by default (not buffered)

Somnath is doing this in his testing with good results.

Signed-off-by: Sage Weil <sage@redhat.com>
9 years agoos/bluestore: break down onode vs bnode_map size in log
Sage Weil [Wed, 17 Aug 2016 14:31:08 +0000 (10:31 -0400)]
os/bluestore: break down onode vs bnode_map size in log

Signed-off-by: Sage Weil <sage@redhat.com>
9 years agoMerge pull request #10717 from liewegas/wip-bluefs-async-compaction
Sage Weil [Thu, 18 Aug 2016 18:21:40 +0000 (13:21 -0500)]
Merge pull request #10717 from liewegas/wip-bluefs-async-compaction

os/bluestore/BlueFS: async compaction

Reviewed-by: Sage Weil <sage@redhat.com>
9 years agoMerge pull request #10698 from liewegas/wip-bluestore-bluefs-allocation
Sage Weil [Thu, 18 Aug 2016 16:27:53 +0000 (11:27 -0500)]
Merge pull request #10698 from liewegas/wip-bluestore-bluefs-allocation

bluestore: do not use freelist to track bluefs_extents

9 years agoMerge pull request #10550 from tanghaodong25/in-memory-db
Sage Weil [Thu, 18 Aug 2016 16:14:13 +0000 (11:14 -0500)]
Merge pull request #10550 from tanghaodong25/in-memory-db

kv: fix some bugs in memdb

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Ramesh Chander <Ramesh.Chander@sandisk.com>
9 years agoMerge pull request #10775 from xiexingguo/xxg-wip-clean-storetest
Sage Weil [Thu, 18 Aug 2016 16:11:24 +0000 (11:11 -0500)]
Merge pull request #10775 from xiexingguo/xxg-wip-clean-storetest

test/store_test: tidy-up SyntheticWorkloadState class

Reviewed-by: Sage Weil <sage@redhat.com>
9 years agorgw ldap: protect rgw::from_base64 from non-base64 input 10777/head
Matt Benjamin [Thu, 18 Aug 2016 14:54:16 +0000 (10:54 -0400)]
rgw ldap:  protect rgw::from_base64 from non-base64 input

Also adds unit tests for:
1. empty output from from_base64 (turns out to be harmless)
2. random and specific non-base64 and sort strings

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
9 years agodebian: replace SysV rbdmap with systemd service 10435/head
Ken Dreyer [Tue, 16 Feb 2016 19:56:34 +0000 (12:56 -0700)]
debian: replace SysV rbdmap with systemd service

Stop shipping /etc/init.d/rbdmap in the Debian packages. Ship the
rbdmap.service systemd unit file instead.

The corresponding change has already been made for RPMs, in
9224ac2ad25f7d017916f58b642c0ea25305c3e5.

For Upstart-based systems (eg Ubuntu Trusty), the Debian packages
already contain rbdmap.conf.

(This gets us a tiny bit closer to being able to remove the rbdmap SysV
script from our tree entirely.)

Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
9 years agomon/PGMonitor: fix potential underflow 10739/head
xie xingguo [Thu, 18 Aug 2016 11:54:07 +0000 (19:54 +0800)]
mon/PGMonitor: fix potential underflow

h.h.size() could be 0(theoretically), so "h.h.size() - 1" could underflow.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agomon/PGMonitor: drop redundant loading of dumpcontents
xie xingguo [Wed, 17 Aug 2016 06:34:01 +0000 (14:34 +0800)]
mon/PGMonitor: drop redundant loading of dumpcontents

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agomon/PGMonitor: skip scrub checking if we can
xie xingguo [Wed, 17 Aug 2016 03:22:38 +0000 (11:22 +0800)]
mon/PGMonitor: skip scrub checking if we can

The PG-scrub checking may become expensive once the cluster
is big. Since the scrub-warn related options are defaulted to be off,
we should skip this checking when it is possible, which
is good for performance.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoosd/OSDMonitor: drop redundant check of exists()
xie xingguo [Tue, 16 Aug 2016 06:55:31 +0000 (14:55 +0800)]
osd/OSDMonitor: drop redundant check of exists()

Which is aready included by the is_up() method.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoosd/OSDMonitor: avoid duplicated assignment of oldest_map/newest_map
xie xingguo [Tue, 16 Aug 2016 06:34:49 +0000 (14:34 +0800)]
osd/OSDMonitor: avoid duplicated assignment of oldest_map/newest_map

As build_incremental() has done this for us.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agomon/OSDMonitor: avoid duplicated calls when determining osdmap boundary
xie xingguo [Mon, 15 Aug 2016 09:06:27 +0000 (17:06 +0800)]
mon/OSDMonitor: avoid duplicated calls when determining osdmap boundary

We have caculdated the oldest/newest map epochs already,
so we can use it directly here.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agomon/OSDMonitor: get rid of snprintf when formatting output string
xie xingguo [Mon, 15 Aug 2016 09:00:06 +0000 (17:00 +0800)]
mon/OSDMonitor: get rid of snprintf when formatting output string

We can use the standard precision() and fixed method to achieve the same
effect.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agomon/OSDMonitor: fix potential division-by-zero error
xie xingguo [Mon, 15 Aug 2016 08:40:11 +0000 (16:40 +0800)]
mon/OSDMonitor: fix potential division-by-zero error

By checking pg_num against 0, we could avoid the risk of
division-by-zero error.

Also, we limit the loop to 50 or pg_num, whichever is smaller,
when trying to generate some pg_temps randomly.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agocmake: recompile erasure src for different variants 10772/head
Kefu Chai [Wed, 17 Aug 2016 16:32:03 +0000 (00:32 +0800)]
cmake: recompile erasure src for different variants

* instead of reusing the object libraries, we should recompile jerasure
  code for different plugin flavors like neon, sse3, sse4.
* do not version plugin so, as they are not supposed to be used by
  user directly.

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agotest/store_test: avoid dynamic allocation of trans 10775/head
xie xingguo [Thu, 7 Jul 2016 07:04:42 +0000 (15:04 +0800)]
test/store_test: avoid dynamic allocation of trans

For the sake of performance.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agotest/store_test: drop redundant transaction of callbacks
xie xingguo [Thu, 7 Jul 2016 06:34:21 +0000 (14:34 +0800)]
test/store_test: drop redundant transaction of callbacks

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agotest/store_test: fix incorrect prompt given by stash callback
xie xingguo [Thu, 7 Jul 2016 06:02:15 +0000 (14:02 +0800)]
test/store_test: fix incorrect prompt given by stash callback

"clone finish" belongs to C_SyntheticOnClone instead.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agokv: fix iterator bug in prev 10550/head
haodong [Wed, 17 Aug 2016 15:26:18 +0000 (23:26 +0800)]
kv: fix iterator bug in prev

Signed-off-by: Haodong Tang <haodong.tang@intel.com>
9 years agokv: fill 'm_key_value' after 'seek_to_first' or 'seek_to_last'
haodong [Wed, 17 Aug 2016 15:19:37 +0000 (23:19 +0800)]
kv: fill 'm_key_value' after 'seek_to_first' or 'seek_to_last'

Signed-off-by: Haodong Tang <haodong.tang@intel.com>
9 years agokv: fix iterator invalidation in memdb.
haodong [Wed, 17 Aug 2016 15:14:59 +0000 (23:14 +0800)]
kv: fix iterator invalidation in memdb.

Signed-off-by: Haodong Tang <haodong.tang@intel.com>
9 years agokv: delete store after pg destructor is called in OSD shutdown.
haodong [Tue, 2 Aug 2016 18:19:03 +0000 (02:19 +0800)]
kv: delete store after pg destructor is called in OSD shutdown.

Using memdb for bluestore kvbackend, we will hit segfault when we use
'kill' command to shut down osd process. After destructing pg, some
reference to bluestore will be release, but bluestore has been deleted
at this time.

Signed-off-by: Haodong Tang <haodong.tang@intel.com>
9 years agoMerge pull request #10481 from dillaman/wip-16171
Ilya Dryomov [Wed, 17 Aug 2016 19:03:45 +0000 (21:03 +0200)]
Merge pull request #10481 from dillaman/wip-16171

librbd: request exclusive lock if current owner cannot execute op

Reviewed-off-by: Ilya Dryomov <idryomov@gmail.com>
9 years agoMerge pull request #10737 from weiqiaomiao/wqm-wip-rgw-core
Casey Bodley [Wed, 17 Aug 2016 18:39:47 +0000 (14:39 -0400)]
Merge pull request #10737 from weiqiaomiao/wqm-wip-rgw-core

rgw: fix radosgw daemon core when reopen logs

Reviewed-by: Casey Bodley <cbodley@redhat.com>
9 years agoMerge pull request #10728 from xiexingguo/xxg-wip-kill-bs-warn
Sage Weil [Wed, 17 Aug 2016 16:13:50 +0000 (12:13 -0400)]
Merge pull request #10728 from xiexingguo/xxg-wip-kill-bs-warn

bluestore: initialize csum_order properly

Reviewed-by: Sage Weil <sage@redhat.com>
9 years agolibrbd: cache was not switching to writeback after first flush 10762/head
Jason Dillaman [Wed, 17 Aug 2016 16:08:37 +0000 (12:08 -0400)]
librbd: cache was not switching to writeback after first flush

Fixes: http://tracker.ceph.com/issues/16654
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #10703 from dillaman/wip-16855
Mykola Golub [Wed, 17 Aug 2016 15:16:17 +0000 (18:16 +0300)]
Merge pull request #10703 from dillaman/wip-16855

rbd-mirror: improve split-brain detection logic

Reviewed-by: Mykola Golub <mgolub@mirantis.com>
9 years agoMerge pull request #10756 from linuxbox2/fix_gc_interval
Orit Wasserman [Wed, 17 Aug 2016 15:03:44 +0000 (17:03 +0200)]
Merge pull request #10756 from linuxbox2/fix_gc_interval

rgw_file: restore local definition of RGWLibFS gc interval
Reviewed-by: Orit Wasserman <owasserm@redhat.com>
9 years agoMerge pull request #10686 from liewegas/wip-bluefs-remove
Sage Weil [Wed, 17 Aug 2016 14:33:05 +0000 (10:33 -0400)]
Merge pull request #10686 from liewegas/wip-bluefs-remove

os/bluestore/BlueFS: do not op_file_update deleted files

Tested-by: Somnath Roy <somnath.roy@sandisk.com>
9 years agorgw_file: restore local definition of RGWLibFS gc interval 10756/head
Matt Benjamin [Wed, 17 Aug 2016 14:28:48 +0000 (10:28 -0400)]
rgw_file: restore local definition of RGWLibFS gc interval

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
9 years agoMerge pull request #10755 from SUSE/wip-cmake-use-pie
Kefu Chai [Wed, 17 Aug 2016 13:46:19 +0000 (21:46 +0800)]
Merge pull request #10755 from SUSE/wip-cmake-use-pie

cmake: Add -pie to CMAKE_EXE_LINKER_FLAGS

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10754 from SUSE/wip-cmake-fix-rgw-soversion
Kefu Chai [Wed, 17 Aug 2016 13:42:43 +0000 (21:42 +0800)]
Merge pull request #10754 from SUSE/wip-cmake-fix-rgw-soversion

cmake: Fix mismatched librgw VERSION / SOVERSION

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agocmake: Add -pie to CMAKE_EXE_LINKER_FLAGS 10755/head
Tim Serong [Wed, 17 Aug 2016 11:46:40 +0000 (21:46 +1000)]
cmake: Add -pie to CMAKE_EXE_LINKER_FLAGS

Without this, rpmlint (on openSUSE Tumbleweed) fails with:

ceph-radosgw.x86_64: E: non-position-independent-executable
(Badness: 10000) /usr/bin/radosgw
This executable must be position independent.  Check that it
is built with -fPIE/-fpie in compiler flags and -pie in linker
flags.

Signed-off-by: Tim Serong <tserong@suse.com>
9 years agocmake: Fix mismatched librgw VERSION / SOVERSION 10754/head
Tim Serong [Wed, 17 Aug 2016 11:14:46 +0000 (21:14 +1000)]
cmake: Fix mismatched librgw VERSION / SOVERSION

Without this, rpmlint (on openSUSE Tumbleweed) fails with:

librgw2.x86_64: E: shlib-policy-name-error (Badness: 10000) librgw1
Your package contains a single shared library but is not named
after its SONAME.

It seems that the VERSION/SOVERSION mismatch results in the
creation of librgw.so.1 and librgw.so.2.0.0, whereas it should
be librgw.so.2 and librgw.so.2.0.0.

Signed-off-by: Tim Serong <tserong@suse.com>
9 years agorgw: silence a compiling warning 10751/head
Kefu Chai [Wed, 17 Aug 2016 10:57:30 +0000 (18:57 +0800)]
rgw: silence a compiling warning

printf() a uint64 in a portable way (i.e. C98 compliant way).

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agotest/rbd: silence compiling warnings
Kefu Chai [Wed, 17 Aug 2016 07:17:35 +0000 (15:17 +0800)]
test/rbd: silence compiling warnings

silence warnings like:
```
src/test/librbd/fsx.cc:1589:21: comparison between signed and unsigned
integer expressions [-Wsign-compare]
(offset + size > monitorstart &&
^
```

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agoos/filestore: silence compiling warnings
Kefu Chai [Wed, 17 Aug 2016 07:15:57 +0000 (15:15 +0800)]
os/filestore: silence compiling warnings

silence warnings like
```
src/os/filestore/FileStore.h:55:27: comparison between signed and
unsigned integer expressions [-Wsign-compare]
^
/srv/autobuild-ceph/gitbuilder.git/build/out~/ceph-11.0.0-1566-ga98ddf7/src/os/filestore/BtrfsFileStoreBackend.cc:269:29:
note: in expansion of macro ‘BTRFS_SUPER_MAGIC’
if (currentfs.f_type == BTRFS_SUPER_MAGIC && basest.st_dev != st.st_dev)
{
^
```

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10749 from mikulely/fix-rgw-client-cb
Orit Wasserman [Wed, 17 Aug 2016 07:12:20 +0000 (09:12 +0200)]
Merge pull request #10749 from mikulely/fix-rgw-client-cb

rgw: fix flush_read_list() error msg
Reviewed-by: Orit Wasserman <owasserm@redhat.com>
9 years agoMerge pull request #10747 from oliveiradan/master
Brad Hubbard [Wed, 17 Aug 2016 06:53:58 +0000 (16:53 +1000)]
Merge pull request #10747 from oliveiradan/master

gcc 6.1.1 complains about missing include: <random>. 4.8.3 does not c…

9 years agomsg/async: fix compiler warnings
Kefu Chai [Wed, 17 Aug 2016 06:38:44 +0000 (14:38 +0800)]
msg/async: fix compiler warnings

fix warnings like
```
comparison between signed and unsigned integer expressions
[-Wsign-compare]
```

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agocls_rgw: fix the compiler warning
Kefu Chai [Wed, 17 Aug 2016 06:31:16 +0000 (14:31 +0800)]
cls_rgw: fix the compiler warning

fixes the warning of
```
warning:
/srv/autobuild-ceph/gitbuilder.git/build/out~/ceph-11.0.0-1566-ga98ddf7/src/objclass/objclass.h:35:72:
format ‘%lu’ expects argument of type ‘long unsigned int’, but argument
6 has type ‘std::basic_string::size_type {aka unsigned int}’ [-Wformat=]
cls_log(level, " %s:%d: " fmt, __FILE__, __LINE__, ##__VA_ARGS__)
^
/srv/autobuild-ceph/gitbuilder.git/build/out~/ceph-11.0.0-1566-ga98ddf7/src/cls/rgw/cls_rgw.cc:477:7:
note: in expansion of macro ‘CLS_LOG’
CLS_LOG(20, "start_key=%s len=%lu", start_key.c_str(),
start_key.size());
^
```

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agorgw: fix flush_read_list() error msg 10749/head
Jiaying Ren [Wed, 17 Aug 2016 06:19:48 +0000 (14:19 +0800)]
rgw: fix flush_read_list() error msg

Signed-off-by: Jiaying Ren <jiaying.ren@umcloud.com>
9 years agotest: gcc 6.1.1 complains about missing include: <random>. 4.8.3 does not complain... 10747/head
oliveiradan [Wed, 17 Aug 2016 02:49:30 +0000 (20:49 -0600)]
test: gcc 6.1.1 complains about missing include: <random>. 4.8.3 does not complain about it

Signed-off-by: Daniel Oliveira <doliveira@suse.com>
9 years agomon/LogMonitor: remove "host" and "fsid" from handle_conf_change() 10591/head
xie xingguo [Fri, 12 Aug 2016 04:38:10 +0000 (12:38 +0800)]
mon/LogMonitor: remove "host" and "fsid" from handle_conf_change()

Because these two fields are not used and tracked.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoosd/OSDMonitor: drop redundant check of assert
xie xingguo [Thu, 11 Aug 2016 03:51:25 +0000 (11:51 +0800)]
osd/OSDMonitor: drop redundant check of assert

Below here version can never be identical to osdmap.epoch,
otherwise we shall have returned above.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agoosd/OSDMonitor: drop redundant null check of max_failed_since
xie xingguo [Thu, 11 Aug 2016 03:39:11 +0000 (11:39 +0800)]
osd/OSDMonitor: drop redundant null check of max_failed_since

Because the "max_failed_since < failed_since" will catch both.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agomon/OSDMonitor: add sanity check before setting use_gmt_hitset attribute
xie xingguo [Thu, 11 Aug 2016 02:20:06 +0000 (10:20 +0800)]
mon/OSDMonitor: add sanity check before setting use_gmt_hitset attribute

As "use_gmt_hitset" is a tier-specified attribute which is not applicable
for normal pools.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
9 years agorgw: do not try to encode or decode time_t
Kefu Chai [Wed, 17 Aug 2016 04:12:37 +0000 (12:12 +0800)]
rgw: do not try to encode or decode time_t

time_t is `signed int` on linux, which is ambiguous when encode() or decode() on i386-linux.
see also 8f9e7b0b.

Signed-off-by: Kefu Chai <kchai@redhat.com>
9 years agoMerge pull request #10264 from yuyuyu101/wip-async-abstract-backend
Kefu Chai [Tue, 16 Aug 2016 18:18:39 +0000 (02:18 +0800)]
Merge pull request #10264 from yuyuyu101/wip-async-abstract-backend

msg/async: allow other async backend implementations

Reviewed-by: Kefu Chai <kchai@redhat.com>
9 years agotest_msgr: ensure wait for ms_dispatch executed 10264/head
Haomai Wang [Mon, 18 Jul 2016 09:27:31 +0000 (17:27 +0800)]
test_msgr: ensure wait for ms_dispatch executed

Otherwise in slow runner, ms_dispatch may not executed when assert

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async/Event: remove global_centers assert
Haomai Wang [Fri, 15 Jul 2016 07:20:10 +0000 (15:20 +0800)]
msg/async/Event: remove global_centers assert

In tests we allow to reset EventCenter instance in the same CephContext,
so it may let global_centers->centers to set the same position multi times.

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agotest_async_networkstack: add networkstack tests
Haomai Wang [Fri, 15 Jul 2016 04:14:17 +0000 (12:14 +0800)]
test_async_networkstack: add networkstack tests

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async/AsyncConnection: fix _conn_prefix racing when stopped
Haomai Wang [Tue, 12 Jul 2016 17:26:04 +0000 (01:26 +0800)]
msg/async/AsyncConnection: fix _conn_prefix racing when stopped

When the connection is lossy and enter fault, it will dispatch reset event.
If cleanup handler is executed as well as ms_handle_reset call mark_down,
it may exists racing for "cs". cleanup handler will reset "cs" but
_conn_prefix in mark_down will access "cs".

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async: readd set_priority call
Haomai Wang [Tue, 12 Jul 2016 07:51:23 +0000 (15:51 +0800)]
msg/async: readd set_priority call

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async: allow EventCenter::set_owner reentry
Haomai Wang [Tue, 12 Jul 2016 06:15:23 +0000 (14:15 +0800)]
msg/async: allow EventCenter::set_owner reentry

If daemonlize we need to respawn event threads, it need to allow set_owner again

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async/Stack: register fork watcher
Haomai Wang [Tue, 12 Jul 2016 04:30:50 +0000 (12:30 +0800)]
msg/async/Stack: register fork watcher

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agocommon/ceph_context: add prefork/postfork wathcher support
Haomai Wang [Tue, 12 Jul 2016 04:26:30 +0000 (12:26 +0800)]
common/ceph_context: add prefork/postfork wathcher support

Because daemon() will termniate all existing threads, it will make something go
wrong.

So we want to add hook at CephContext, do something before/after fork.

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async/Stack: disable smart thread spawn now
Haomai Wang [Tue, 12 Jul 2016 02:16:33 +0000 (10:16 +0800)]
msg/async/Stack: disable smart thread spawn now

New async msgr runtime need to spawn threads when binding, but ceph-osd will
call daemon() after binding port. So we need to respawn threads if forked.

Then thread spawn delay will increase complexity for this change and it's
really a simple strategy which help less, we disable auto spawn now.

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async/PosixStack: increase log level
Haomai Wang [Mon, 11 Jul 2016 11:59:23 +0000 (19:59 +0800)]
msg/async/PosixStack: increase log level

AsyncMessenger will try to loop the bind port range, so it will produce
some addr inuse errors which is not abnormal.

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async/Event: remove event wakeup flag
Haomai Wang [Sun, 10 Jul 2016 08:19:29 +0000 (16:19 +0800)]
msg/async/Event: remove event wakeup flag

Now only dispatch external event will wakeup event thread(previously
delete_time_event will call wakeup), we only need to use
"external_num_events" to indicate whether we have extra events.

Signed-off-by: Haomai Wang <haomai@xsky.com>
9 years agomsg/async/Event: debug event address when dispatching and executing
Haomai Wang [Sat, 9 Jul 2016 16:18:22 +0000 (00:18 +0800)]
msg/async/Event: debug event address when dispatching and executing

Signed-off-by: Haomai Wang <haomai@xsky.com>