]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
10 years agomon: add 'osd crush {get,set}-tunable <name> [value]' commands
Sage Weil [Wed, 3 Dec 2014 00:43:16 +0000 (16:43 -0800)]
mon: add 'osd crush {get,set}-tunable <name> [value]' commands

For now, just add the straw_calc_version tunable.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 9000068ae45a8b89315c152b7d5509ac873f2957)

Conflicts:
src/mon/OSDMonitor.cc

10 years agocrush: fix crush_calc_straw() scalers when there are duplicate weights
Sage Weil [Wed, 3 Dec 2014 00:33:11 +0000 (16:33 -0800)]
crush: fix crush_calc_straw() scalers when there are duplicate weights

The straw bucket was originally tested with uniform weights and with a
few more complicated patterns, like a stair step (1,2,3,4,5,6,7,8,9).  And
it worked!

However, it does not behave with a pattern like
 1, 2, 2, 3, 3, 4, 4

Strangely, it does behave with
 1, 1, 2, 2, 3, 3, 4, 4

and more usefully it does behave with
 1, 2, 2.001, 3, 3.001, 4, 4.001

That is, the logic that explicitly copes with weights that are duplicates
is broken.

The fix is to simply remove the special handling for duplicate weights --
it isn't necessary and doesn't work correctly anyway.

Add a test that compares the mapping result of  [1, 2, 2, 3, 3, ...] with
[1, 2, 2.001, 3, 3.001, ...] and verifies that the difference is small.
With the fix, we get .00012, whereas the original implementation gets
.015.

Note that this changes the straw bucket scalar *precalculated* values that
are encoded with the map, and only when the admin opts into the new behavior.

Backport: giant, firefly
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 43d5c7caa7ce478477bde1bbd4f0649b5159cdcf)

10 years agocrush: fix distortion of straw scalers by 0-weight items
Sage Weil [Tue, 2 Dec 2014 22:50:21 +0000 (14:50 -0800)]
crush: fix distortion of straw scalers by 0-weight items

The presence of a 0-weight item in a straw bucket should have no effect
on the placement of other items.  Add a test validating that and fix
crush_calc_straw() to fix the distortion.

Note that this effects the *precalculation* of the straw bucket inputs and
does not effect the actually mapping process given a compiled or encoded
CRUSH map, and only when straw_calc_version == 1 (i.e., the admin opted in
to the new behavior).

Backport: giant, firefly
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 85498bc8f62ca56506b33f3c5ec4fc4b111ed73d)

10 years agocrush/builder: break out new version 1 of crush_calc_straw
Sage Weil [Tue, 2 Dec 2014 22:49:42 +0000 (14:49 -0800)]
crush/builder: break out new version 1 of crush_calc_straw

No change, yet.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 7c1203635f2b5911f281ce3a441905df6e9bd103)

10 years agocrush: pass crush_map * to various builder methods
Sage Weil [Tue, 2 Dec 2014 22:45:04 +0000 (14:45 -0800)]
crush: pass crush_map * to various builder methods

In particular, we will need it for crush_calc_straw().

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit f35a3d88cb944c292e966f679ac7a8d7a1cd3093)

Conflicts:
src/crush/CrushWrapper.cc

10 years agocrush: fix incorrect use of adjust_item_weight method
Rongze Zhu [Fri, 10 Oct 2014 11:18:00 +0000 (19:18 +0800)]
crush: fix incorrect use of adjust_item_weight method

adjust_item_weight method will adjust all buckets which the item
inside. If the osd.0 in host=fake01 and host=fake02, we execute
"ceph osd crush osd.0 10 host=fake01", it not only will adjust fake01's
weight, but also will adjust fake02's weight.

the patch add adjust_item_weightf_in_loc method and fix remove_item,
_remove_item_under, update_item, insert_item, detach_bucket methods.

Signed-off-by: Rongze Zhu <zrzhit@gmail.com>
(cherry picked from commit 9850227d2f0ca2f692a154de2c14a0a08e751f08)

Conflicts:
src/crush/CrushWrapper.cc

10 years agocrush/CrushWrapper: fix detach_bucket
Sage Weil [Thu, 13 Nov 2014 18:59:22 +0000 (10:59 -0800)]
crush/CrushWrapper: fix detach_bucket

In commit 9850227d2f0ca2f692a154de2c14a0a08e751f08 we changed the call that
changed the weight of all instances of item to one that explicitly
changes it in the parent bucket, but parent_id may not be valid at the
call site.  Move this into the conditional block to fix.

Fixes: #10095
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 6f8b96a9fe4793906c74a571109a457aca7ca220)

10 years agocrush: default to straw_calc_version 1
Sage Weil [Tue, 2 Dec 2014 22:10:49 +0000 (14:10 -0800)]
crush: default to straw_calc_version 1

Stick with bobtail tunables where it affects compatibility.  Use v1 of
straw_calc, though, since that does not, and we want the best for new
clusters.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 9565621d6007302fdd68ba27b6aef22e487f0985)

10 years agocrush: add straw_calc_version tunable
Sage Weil [Fri, 13 Feb 2015 16:30:35 +0000 (08:30 -0800)]
crush: add straw_calc_version tunable

It doesn't do anything, yet.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 50e2ceefee6a5dfbecbe54890139b1fa80a313c8)

(Modified from original to not create the 'hammer' tunable profile, which
we will not backport in its entirety.)

10 years agocrush/CrushWrapper: dump chooseleaf_vary_r with other tunables
Sage Weil [Tue, 2 Dec 2014 22:04:34 +0000 (14:04 -0800)]
crush/CrushWrapper: dump chooseleaf_vary_r with other tunables

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit c133a83fe7b77e2a7e7c711cb8ab943c59ff0885)

10 years agocrush/CrushTester: add new --show-mappings option
Sage Weil [Tue, 2 Dec 2014 18:12:25 +0000 (10:12 -0800)]
crush/CrushTester: add new --show-mappings option

This makes --show-utilization and --show-statistics usable.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 3877f00877f53e9f86630c2d89e81ab9cff729ec)

10 years agocrushtool/CrushTester: output utilization even with 1 batch
Sage Weil [Tue, 2 Dec 2014 18:11:57 +0000 (10:11 -0800)]
crushtool/CrushTester: output utilization even with 1 batch

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 294b06c6424f4cb69394976add826d9725073b50)

10 years agocrush: recalculate straw scalers during a reweight
Sage Weil [Tue, 2 Dec 2014 18:08:18 +0000 (10:08 -0800)]
crush: recalculate straw scalers during a reweight

The crushtool --reweight function triggers a fresh calculation of bucket
weights so that they are always the sum of the item weights.  In the
straw bucket case, the weights were updated but the corresponding straw
scalers were not being recalculated.  The result is that there was not
effect on placement in adjusted buckets until the next time a bucket item's
weight was adjusted.

Backport: giant, firefly
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 35062937f174a45fb13d9c177eaa1fe4ed5ff4c2)

10 years agoosdmaptool: --test-map-pgs-dump
Sage Weil [Tue, 2 Dec 2014 16:36:41 +0000 (08:36 -0800)]
osdmaptool: --test-map-pgs-dump

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 7a99b489909b368bade36d8cc9722ad33d03a2e8)

10 years agocrush: add dprintk's for crush_calc_straw
Sage Weil [Tue, 2 Dec 2014 14:53:20 +0000 (06:53 -0800)]
crush: add dprintk's for crush_calc_straw

These are compiled out by default.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 946bebd94b109642f95710802e892c59eb4f0b76)

10 years agocrush: fix tree bucket functions
Rongze Zhu [Mon, 10 Nov 2014 16:13:42 +0000 (00:13 +0800)]
crush: fix tree bucket functions

There are incorrect nodes' weight in tree bucket when construct tree
bucket. The tree bucket don't store item id in items array, so the tree
bucket will not work correctly. The patch fix above bugs and add a
simple test for tree bucket.

Signed-off-by: Rongze Zhu <zrzhit@gmail.com>
(cherry picked from commit 13425488882d360fa740613dfcfd0d098c1b7616)

10 years agocrush/builder: replace printf with an empty dprintk macro
Sage Weil [Tue, 11 Nov 2014 19:16:58 +0000 (11:16 -0800)]
crush/builder: replace printf with an empty dprintk macro

This mirrors mapper.c.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit e444b221733360cdea4f4bbdbbbfbf2b6ee30ff5)

10 years ago0.80.8 v0.80.8
Jenkins [Tue, 13 Jan 2015 14:28:08 +0000 (06:28 -0800)]
0.80.8

10 years agomon/OSDMonitor: fix double-free on old MOSDBoot
Sage Weil [Tue, 19 Aug 2014 23:43:02 +0000 (16:43 -0700)]
mon/OSDMonitor: fix double-free on old MOSDBoot

send_latest() does an m->put().

Backport: firefly, dumpling
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 97f9b6df668315fba6a5924b79024c7a986f4110)

10 years agoosd: requeue PG when we skip handling a peering event
Sage Weil [Thu, 8 Jan 2015 19:17:03 +0000 (11:17 -0800)]
osd: requeue PG when we skip handling a peering event

If we don't handle the event, we need to put the PG back into the peering
queue or else the event won't get processed until the next event is
queued, at which point we'll be processing events with a delay.

The queue_null is not necessary (and is a waste of effort) because the
event is still in pg->peering_queue and the PG is queued.

This is a firefly-specific patch; a (very) similar one will appear in master
in 492ccc900c3358f36b6b14a207beec071eb06707.

Backport: giant, firefly
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #3217 from boydc2014/firefly
Sage Weil [Fri, 9 Jan 2015 02:31:26 +0000 (18:31 -0800)]
Merge pull request #3217 from boydc2014/firefly

clear data and payload after removed from ops_in_flight

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #3127 from ktdreyer/firefly-no-epoch
Loic Dachary [Fri, 9 Jan 2015 00:32:17 +0000 (01:32 +0100)]
Merge pull request #3127 from ktdreyer/firefly-no-epoch

Revert "ceph.spec.: add epoch"

Reviewed-by: Ken Dreyer <kdreyer@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #3128 from dachary/wip-10281-make-check-fedora-20
Loic Dachary [Fri, 9 Jan 2015 00:31:29 +0000 (01:31 +0100)]
Merge pull request #3128 from dachary/wip-10281-make-check-fedora-20

tests: fixes to run make check on fedora 20

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #3169 from ceph/wip-8797-firefly
Loic Dachary [Fri, 9 Jan 2015 00:30:59 +0000 (01:30 +0100)]
Merge pull request #3169 from ceph/wip-8797-firefly

Wip 8797 firefly

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #3179 from dachary/wip-9998-crush-underfloat-firefly
Loic Dachary [Fri, 9 Jan 2015 00:28:49 +0000 (01:28 +0100)]
Merge pull request #3179 from dachary/wip-9998-crush-underfloat-firefly

crush: fix weight underfloat issue (firefly)

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #3220 from ceph/wip-mon-backports.firefly
Loic Dachary [Fri, 9 Jan 2015 00:28:11 +0000 (01:28 +0100)]
Merge pull request #3220 from ceph/wip-mon-backports.firefly

mon: backports for #9987 against firefly

Reviewed-by: Joao Eduardo Luis <joao@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #3258 from ceph/wip-10372-firefly
Loic Dachary [Fri, 9 Jan 2015 00:26:30 +0000 (01:26 +0100)]
Merge pull request #3258 from ceph/wip-10372-firefly

osd: fix librados pool deletion race on firefly

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoIf trusty, use older version of qemu
Warren Usui [Fri, 19 Dec 2014 04:00:28 +0000 (20:00 -0800)]
If trusty, use older version of qemu

Fixes #10319
Signed-off-by: Warren Usui <warren.usui@inktank.com>
(cherry-picked from 46a1a4cb670d30397979cd89808a2e420cef2c11)

10 years agoclear data and payload inside ops_in_flight_lock 3217/head
Lei Dong [Tue, 30 Dec 2014 13:02:45 +0000 (21:02 +0800)]
clear data and payload inside ops_in_flight_lock

http://tracker.ceph.com/issues/9916 Fixes: #9916
Signed-off-by: Dong Lei <leidong@yahoo-inc.com>
10 years agoMerge pull request #3264 from dachary/wip-jerasure-firefly
Sage Weil [Mon, 29 Dec 2014 22:31:23 +0000 (14:31 -0800)]
Merge pull request #3264 from dachary/wip-jerasure-firefly

erasure-code: update links to jerasure upstream

10 years agoMerge pull request #3268 from ceph/firefly-10415
Sage Weil [Mon, 29 Dec 2014 18:55:39 +0000 (10:55 -0800)]
Merge pull request #3268 from ceph/firefly-10415

libcephfs/test.cc: close fd before umount

10 years agoerasure-code: update links to jerasure upstream 3264/head
Loic Dachary [Sun, 28 Dec 2014 09:29:54 +0000 (10:29 +0100)]
erasure-code: update links to jerasure upstream

It moved from bitbucket to jerasure.org

Signed-off-by: Loic Dachary <ldachary@redhat.com>
(cherry picked from commit 8e86f901939f16cc9c8ad7a4108ac4bcf3916d2c)

10 years agolibcephfs/test.cc: close fd before umount 3268/head
Yan, Zheng [Tue, 23 Dec 2014 02:22:00 +0000 (10:22 +0800)]
libcephfs/test.cc: close fd before umount

Fixes: #10415
Signed-off-by: Yan, Zheng <zyan@redhat.com>
(cherry picked from commit d3fb563cee4c4cf08ff4ee01782e52a100462429)

10 years agoosdc/Objecter: handle reply race with pool deletion 3258/head
Sage Weil [Tue, 23 Dec 2014 23:49:26 +0000 (15:49 -0800)]
osdc/Objecter: handle reply race with pool deletion

We need to handle this scenario:

 - send request in epoch X
 - osd replies
 - pool is deleted in epoch X+1
 - client gets map X+1, sends a map check
 - client handles reply
   -> asserts that no map checks are in flight

This isn't the best solution.  We could infer that a map check isn't needed
since the pool existed earlier and doesn't now.  But this is firefly and
the fix is no more expensive than the old assert.

Fixes: #10372
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agotest/ceph-disk.sh: mkdir -p 3128/head
Sage Weil [Tue, 5 Aug 2014 22:11:18 +0000 (15:11 -0700)]
test/ceph-disk.sh: mkdir -p

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit c2f58e6694a2457200ab3d59e037ad17b9c82028)

10 years agotest/ceph-disk.sh: resolve symlinks before check
Danny Al-Gaaf [Thu, 4 Sep 2014 10:23:27 +0000 (12:23 +0200)]
test/ceph-disk.sh: resolve symlinks before check

Make sure symlinks are resolved in command_fixture()
before compare result of which command and the current
path.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
(cherry picked from commit 8ea86dfa7c4a3d7e089cf9d4e49586657875f851)

10 years agotest/ceph-disk.sh: fix for SUSE
Danny Al-Gaaf [Tue, 24 Jun 2014 17:54:17 +0000 (19:54 +0200)]
test/ceph-disk.sh: fix for SUSE

On SUSE 'which' returns always the full path of (shell) commands and
not e.g. './ceph-conf' as on Debian. Add check also for full
path returned by which.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
(cherry picked from commit 39530536ff923b91899f6303507c283b78040a20)

10 years agotests: prevent kill race condition
Loic Dachary [Fri, 13 Jun 2014 12:41:39 +0000 (14:41 +0200)]
tests: prevent kill race condition

When trying to kill a daemon, keep its pid in a variable instead of
retrieving it from the pidfile multiple times. It prevents the following
race condition:

  * try to kill ceph-mon
  * ceph-mon is in the process of dying and removed its pidfile
  * try to kill ceph-mon fails because the pidfile is not found
  * another ceph-mon is spawned and fails to bind the port
    because the previous ceph-mon is still holding it

Signed-off-by: Loic Dachary <loic@dachary.org>
(cherry picked from commit a1c13c57ba20fc329d943ea57523913e11067dc7)

10 years agoosd/OSD.cc: parse lsb release data via lsb_release
Danny Al-Gaaf [Tue, 24 Jun 2014 22:31:48 +0000 (00:31 +0200)]
osd/OSD.cc: parse lsb release data via lsb_release

Use lsb_release tool to be portable since parsing /etc/lsb-release
is not the same between different distributions. The old code failed
e.g. for SUSE products to parse LSB information.

Fixes: #8654
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
(cherry picked from commit 0b3a3987d382ff33fdf892f189b30df22be80e59)

10 years agotests: histogram prevent re-use of local variables
Loic Dachary [Tue, 26 Aug 2014 19:59:39 +0000 (21:59 +0200)]
tests: histogram prevent re-use of local variables

By moving the tests to separate functions.

http://tracker.ceph.com/issues/9235 Fixes: #9235

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
(cherry picked from commit 4b8b25ecd128c34a386ad7c4cc89f323c4d384e1)

10 years agotests: histogram prevent re-use of local variables
Loic Dachary [Tue, 26 Aug 2014 19:59:39 +0000 (21:59 +0200)]
tests: histogram prevent re-use of local variables

By moving the test to a separate function.

http://tracker.ceph.com/issues/9235 Fixes: #9235

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
(cherry picked from commit ee02293ad2ef050672fa8c164ba17b10e8d4ceeb)

10 years agotests: avoid tab interpretation problem on fedora 20
Loic Dachary [Tue, 9 Dec 2014 23:08:57 +0000 (00:08 +0100)]
tests: avoid tab interpretation problem on fedora 20

Use . instead of tab in echo to avoid variations in how escape sequences
are interpreted by the shell.

http://tracker.ceph.com/issues/10281 Fixes: #10281

Signed-off-by: Loic Dachary <ldachary@redhat.com>
10 years agomon/PGMap and PGMonitor: update last_epoch_clean cache from new osd keys 3220/head
Sage Weil [Sun, 2 Nov 2014 16:50:59 +0000 (08:50 -0800)]
mon/PGMap and PGMonitor: update last_epoch_clean cache from new osd keys

We were only invalidating the cached value from apply_incremental, which
is no longer called on modern clusters.

Fix this by storing the update epoch in the key as well (it is not part
of osd_stat_t).

Backport: giant, firefly, dumpling(?)
Fixes: #9987
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 093c5f0cabeb552b90d944da2c50de48fcf6f564)

10 years agomon/PGMap: invalidate cached min_last_epoch_clean from new-style pg keys
Sage Weil [Sun, 2 Nov 2014 16:49:48 +0000 (08:49 -0800)]
mon/PGMap: invalidate cached min_last_epoch_clean from new-style pg keys

We were only invalidating the cache from the legacy apply_incremental(),
which is no longer called on modern clusters.

Fixes: #9987
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 3fb731b722c50672a5a9de0c86a621f5f50f2d06)

10 years agocrush/CrushWrapper: fix create_or_move_item when name exists but item does not 3179/head
Sage Weil [Mon, 24 Nov 2014 02:50:51 +0000 (18:50 -0800)]
crush/CrushWrapper: fix create_or_move_item when name exists but item does not

We were using item_exists(), which simply checks if we have a name defined
for the item.  Instead, use _search_item_exists(), which looks for an
instance of the item somewhere in the hierarchy.  This matches what
get_item_weightf() is doing, which ensures we get a non-negative weight
that converts properly to floating point.

Backport: giant, firefly
Fixes: #9998
Reported-by: Pawel Sadowski <ceph@sadziu.pl>
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 9902383c690dca9ed5ba667800413daa8332157e)

10 years agocrush/builder: prevent bucket weight underflow on item removal
Sage Weil [Sat, 22 Nov 2014 01:47:56 +0000 (17:47 -0800)]
crush/builder: prevent bucket weight underflow on item removal

It is possible to set a bucket weight that is not the sum of the item
weights if you manually modify/build the CRUSH map.  Protect against any
underflow on the bucket weight when removing items.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 8c87e9502142d5b4a282b94f929ae776a49be1dc)

10 years agocrush/CrushWrapper: fix _search_item_exists
Sage Weil [Sat, 22 Nov 2014 01:37:03 +0000 (17:37 -0800)]
crush/CrushWrapper: fix _search_item_exists

Reported-by: Pawel Sadowski <ceph@sadziu.pl>
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit eeadd60714d908a3a033aeb7fd542c511e63122b)

10 years agoMerge pull request #3124 from ceph/wip-10194-firefly
Sage Weil [Fri, 12 Dec 2014 14:19:50 +0000 (06:19 -0800)]
Merge pull request #3124 from ceph/wip-10194-firefly

rgw: optionally call FCGX_Free() on the fcgi connection

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoCall Rados.shutdown() explicitly before exit 3169/head
Dan Mick [Wed, 10 Dec 2014 21:19:53 +0000 (13:19 -0800)]
Call Rados.shutdown() explicitly before exit

This is mostly a demonstration of good behavior, as the resources will
be reclaimed on exit anyway.

Signed-off-by: Dan Mick <dan.mick@redhat.com>
(cherry picked from commit b038e8fbf9103cc42a4cde734b3ee601af6019ea)

10 years agorados.py: remove Rados.__del__(); it just causes problems
Dan Mick [Wed, 10 Dec 2014 21:19:16 +0000 (13:19 -0800)]
rados.py: remove Rados.__del__(); it just causes problems

Recent versions of Python contain a change to thread shutdown that
causes ceph to hang on exit; see http://bugs.python.org/issue21963.
As it turns out, this is relatively easy to avoid by not spawning
threads on exit, as Rados.__del__() will certainly do by calling
shutdown(); I suspect, but haven't proven, that the problem is
that shutdown() tries to start() a threading.Thread() that never
makes it all the way back to signal start().

Also add a PendingReleaseNote and extra doc comments to clarify.

Fixes: #8797
Signed-off-by: Dan Mick <dan.mick@redhat.com>
(cherry picked from commit 5ba9b8f21f8010c59dd84a0ef2acfec99e4b048f)

Conflicts:
PendingReleaseNotes

10 years agoRevert "ceph.spec.: add epoch" 3127/head
Ken Dreyer [Tue, 9 Dec 2014 21:52:19 +0000 (14:52 -0700)]
Revert "ceph.spec.: add epoch"

If ICE ships 0.80.8, then it will be newer than what RHCEPH ships
(0.80.7), and users won't be able to seamlessly upgrade via Yum.

We have three options:
A) Revert the "Epoch: 1" change on the Firefly branch.
B) Revert the "Epoch: 1" change in the ICE packages.
C) Bump the Epoch to "2" in Red Hat's packages.

This commit does Option A.

Option B may or may not be feasible - it would require a "downstream"
change in ICE, and we haven't done that sort of thing before.

Due to the RHEL release schedule, Option C is not available to us at
this point.

This reverts commit b890c1e4706d7cfef7ed24c9df65b439b4f7ff1d.

10 years agorgw: optionally call FCGX_Free() on the fcgi connection 3124/head
Yehuda Sadeh [Wed, 26 Nov 2014 23:18:07 +0000 (15:18 -0800)]
rgw: optionally call FCGX_Free() on the fcgi connection

Fixes: #10194
A new configurable controls this behavior. This forces disconnection of
the fcgi connection when done with the request.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoMerge pull request #3109 from ceph/firefly-10263
Gregory Farnum [Mon, 8 Dec 2014 23:02:52 +0000 (15:02 -0800)]
Merge pull request #3109 from ceph/firefly-10263

mds: store backtrace for straydir

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
10 years agoMerge pull request #3009 from dachary/wip-10018-primary-erasure-code-hinfo-firefly
Samuel Just [Mon, 8 Dec 2014 21:19:44 +0000 (13:19 -0800)]
Merge pull request #3009 from dachary/wip-10018-primary-erasure-code-hinfo-firefly

osd: deep scrub must not abort if hinfo is missing (firefly)

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agomds: store backtrace for straydir 3109/head
Yan, Zheng [Fri, 7 Nov 2014 03:38:37 +0000 (11:38 +0800)]
mds: store backtrace for straydir

Backport: giant, firefly, emperor, dumpling
Signed-off-by: Yan, Zheng <zyan@redhat.com>
(cherry picked from commit 0d89db5d3e5ae5d552d4058a88a4e186748ab1d2)

10 years agoMerge pull request #3089 from dachary/wip-10063-hobject-shard-firefly
Sage Weil [Sat, 6 Dec 2014 19:06:02 +0000 (11:06 -0800)]
Merge pull request #3089 from dachary/wip-10063-hobject-shard-firefly

common: do not omit shard when ghobject NO_GEN is set (firefly)

10 years agoMerge pull request #2480 from dachary/wip-9420-erasure-code-non-regression-firefly
Sage Weil [Sat, 6 Dec 2014 18:59:44 +0000 (10:59 -0800)]
Merge pull request #2480 from dachary/wip-9420-erasure-code-non-regression-firefly

erasure-code: store and compare encoded contents (firefly)

10 years agoMerge pull request #3096 from dachary/wip-9785-dmcrypt-keys-permissions-firefly
Sage Weil [Sat, 6 Dec 2014 01:33:05 +0000 (17:33 -0800)]
Merge pull request #3096 from dachary/wip-9785-dmcrypt-keys-permissions-firefly

ceph-disk: dmcrypt file permissions (firefly)

10 years agoceph-disk: dmcrypt file permissions 3096/head
Loic Dachary [Thu, 4 Dec 2014 21:21:32 +0000 (22:21 +0100)]
ceph-disk: dmcrypt file permissions

The directory in which key files are stored for dmcrypt must be 700 and
the file 600.

http://tracker.ceph.com/issues/9785 Fixes: #9785

Signed-off-by: Loic Dachary <ldachary@redhat.com>
(cherry picked from commit 58682d1776ab1fd4daddd887d921ca9cc312bf50)

10 years agoMerge pull request #3086 from dachary/wip-10125-radosgw-init-firefly
Sage Weil [Fri, 5 Dec 2014 17:04:00 +0000 (09:04 -0800)]
Merge pull request #3086 from dachary/wip-10125-radosgw-init-firefly

rgw: run radosgw as apache with systemd (firefly)

10 years agocommon: do not omit shard when ghobject NO_GEN is set 3089/head
Loic Dachary [Fri, 14 Nov 2014 00:16:10 +0000 (01:16 +0100)]
common: do not omit shard when ghobject NO_GEN is set

Do not silence the display of shard_id when generation is NO_GEN.
Erasure coded objects JSON representation used by ceph_objectstore_tool
need the shard_id to find the file containing the chunk.

Minimal testing is added to ceph_objectstore_tool.py

http://tracker.ceph.com/issues/10063 Fixes: #10063

Signed-off-by: Loic Dachary <ldachary@redhat.com>
(cherry picked from commit dcf09aed121f566221f539106d10283a09f15cf5)

Conflicts:
src/test/ceph_objectstore_tool.py

10 years agorgw: run radosgw as apache with systemd 3086/head
Loic Dachary [Tue, 2 Dec 2014 17:10:48 +0000 (18:10 +0100)]
rgw: run radosgw as apache with systemd

Same as sysv.

http://tracker.ceph.com/issues/10125 Fixes: #10125

Signed-off-by: Loic Dachary <loic@dachary.org>
(cherry picked from commit 7b621f4abf63456272dec3449aa108c89504a7a5)

Conflicts:
src/init-radosgw.sysv

10 years agoMerge pull request #3078 from ceph/wip-10030-firefly
Josh Durgin [Thu, 4 Dec 2014 19:32:18 +0000 (11:32 -0800)]
Merge pull request #3078 from ceph/wip-10030-firefly

librbd: don't close an already closed parent image upon failure

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
10 years agoMerge pull request #3063 from ceph/wip-10123-firefly
Sage Weil [Thu, 4 Dec 2014 07:01:44 +0000 (23:01 -0800)]
Merge pull request #3063 from ceph/wip-10123-firefly

librbd: protect list_children from invalid child pool IoCtxs

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoReplicatedPG: don't move on to the next snap immediately
Samuel Just [Tue, 23 Sep 2014 22:52:08 +0000 (15:52 -0700)]
ReplicatedPG: don't move on to the next snap immediately

If we have a bunch of trimmed snaps for which we have no
objects, we'll spin for a long time.  Instead, requeue.

Fixes: #9487
Backport: dumpling, firefly, giant
Reviewed-by: Sage Weil <sage@redhat.com>
Signed-off-by: Samuel Just <sam.just@inktank.com>
(cherry picked from commit c17ac03a50da523f250eb6394c89cc7e93cb4659)

10 years agoosd: initialize purged_snap on backfill start; restart backfill if change
Sage Weil [Tue, 23 Sep 2014 23:21:33 +0000 (16:21 -0700)]
osd: initialize purged_snap on backfill start; restart backfill if change

If we backfill a PG to a new OSD, we currently neglect to initialize
purged_snaps.  As a result, the first time the snaptrimmer runs it has to
churn through every deleted snap for all time, and to make matters worse
does so in one go with the PG lock held.  This leads to badness on any
cluster with a significant number of removed snaps that experiences
backfill.

Resolve this by initializing purged_snaps when we finish backfill.  The
backfill itself will clear out any stray snaps and ensure the object set
is in sync with purged_snaps.  Note that purged_snaps on the primary
that is driving backfill will not change during this period as the
snaptrimmer is not scheduled unless the PG is clean (which it won't be
during backfill).

If we by chance to interrupt backfill, go clean with other OSDs,
purge snaps, and then let this OSD rejoin, we will either restart
backfill (non-contiguous log) or the log will include the result of
the snap trim (the events that remove the trimmed snap).

Fixes: #9487
Backfill: firefly, dumpling
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 255b430a87201c7d0cf8f10a3c1e62cbe8dd2d93)

10 years agolibrbd: don't close an already closed parent image upon failure 3078/head
Jason Dillaman [Thu, 6 Nov 2014 10:01:38 +0000 (05:01 -0500)]
librbd: don't close an already closed parent image upon failure

If librbd is not able to open a child's parent image, it will
incorrectly close the parent image twice, resulting in a crash.

Fixes: #10030
Backport: firefly, giant
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 61ebfebd59b61ffdc203dfeca01ee1a02315133e)

10 years agolibrbd: protect list_children from invalid child pool IoCtxs 3063/head
Jason Dillaman [Tue, 18 Nov 2014 02:49:26 +0000 (21:49 -0500)]
librbd: protect list_children from invalid child pool IoCtxs

While listing child images, don't ignore error codes returned
from librados when creating an IoCtx. This will prevent seg
faults from occurring when an invalid IoCtx is used.

Fixes: #10123
Backport: giant, firefly, dumpling
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 0d350b6817d7905908a4e432cd359ca1d36bab50)

10 years agoMerge pull request #3014 from dachary/wip-9665-ceph-disk-partprobe-firefly
Sage Weil [Sun, 30 Nov 2014 18:12:04 +0000 (10:12 -0800)]
Merge pull request #3014 from dachary/wip-9665-ceph-disk-partprobe-firefly

ceph disk zap must call partprobe

10 years agoceph-disk: use update_partition in prepare_dev and main_prepare 3014/head
Loic Dachary [Fri, 10 Oct 2014 08:26:31 +0000 (10:26 +0200)]
ceph-disk: use update_partition in prepare_dev and main_prepare

In the case of prepare_dev the partx alternative was missing and is not
added because update_partition does it.

http://tracker.ceph.com/issues/9721 Fixes: #9721

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
(cherry picked from commit 23e71b1ee816c0ec8bd65891998657c46e364fbe)

Conflicts:
src/ceph-disk

10 years agoceph-disk: run partprobe after zap
Loic Dachary [Thu, 9 Oct 2014 16:52:17 +0000 (18:52 +0200)]
ceph-disk: run partprobe after zap

Not running partprobe after zapping a device can lead to the following:

* ceph-disk prepare /dev/loop2
* links are created in /dev/disk/by-partuuid
* ceph-disk zap /dev/loop2
* links are not removed from /dev/disk/by-partuuid
* ceph-disk prepare /dev/loop2
* some links are not created in /dev/disk/by-partuuid

This is assuming there is a bug in the way udev events are handled by
the operating system.

http://tracker.ceph.com/issues/9665 Fixes: #9665

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
(cherry picked from commit fed3b06c47a5ef22cb3514c7647544120086d1e7)

10 years agoceph-disk: encapsulate partprobe / partx calls
Loic Dachary [Fri, 10 Oct 2014 08:23:34 +0000 (10:23 +0200)]
ceph-disk: encapsulate partprobe / partx calls

Add the update_partition function to reduce code duplication.
The action is made an argument although it always is -a because it will
be -d when deleting a partition.

Use the update_partition function in prepare_journal_dev

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
(cherry picked from commit 922a15ea6865ef915bbdec2597433da6792c1cb2)

Conflicts:
src/ceph-disk

10 years agoosd: deep scrub must not abort if hinfo is missing 3009/head
Loic Dachary [Thu, 6 Nov 2014 16:11:20 +0000 (17:11 +0100)]
osd: deep scrub must not abort if hinfo is missing

Instead it should set read_error.

http://tracker.ceph.com/issues/10018 Fixes: #10018

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
(cherry picked from commit 9d84d2e8309d26e39ca849a75166d2d7f2dec9ea)

10 years agoerasure-code: add corpus verification to make check 2480/head
Loic Dachary [Tue, 23 Sep 2014 09:38:09 +0000 (11:38 +0200)]
erasure-code: add corpus verification to make check

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: workunit to check for encoding regression
Loic Dachary [Sat, 13 Sep 2014 11:36:09 +0000 (13:36 +0200)]
erasure-code: workunit to check for encoding regression

Clone the archive of encoded objects and decode all archived objects, up
to and including the current ceph version.

http://tracker.ceph.com/issues/9420 Refs: #9420

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: store and compare encoded contents
Loic Dachary [Sat, 13 Sep 2014 08:16:31 +0000 (10:16 +0200)]
erasure-code: store and compare encoded contents

Introduce ceph_erasure_code_non_regression to check and compare how an
erasure code plugin encodes and decodes content with a given set of
parameters. For instance:

./ceph_erasure_code_non_regression \
      --plugin jerasure \
      --parameter technique=reed_sol_van \
      --parameter k=2 \
      --parameter m=2 \
      --stripe-width 3181 \
      --create \
      --check

Will create an encoded object (--create) and store it into a directory
along with the chunks, one chunk per file. The directory name is derived
from the parameters. The content of the object is a random pattern of 31
bytes repeated to fill the object size specified with --stripe-width.

The check function (--check) reads the object back from the file,
encodes it and compares the result with the content of the chunks read
from the files. It also attempts recover from one or two erasures.

Chunks encoded by a given version of Ceph are expected to be encoded
exactly in the same way by all Ceph versions going forward.

http://tracker.ceph.com/issues/9420 Refs: #9420

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoMerge pull request #2961 from ceph/wip-10114-firefly
Loic Dachary [Wed, 19 Nov 2014 01:45:26 +0000 (02:45 +0100)]
Merge pull request #2961 from ceph/wip-10114-firefly

Add annotation to all assembly files to turn off stack-execute bit

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoAdd annotation to all assembly files to turn off stack-execute bit 2961/head
Dan Mick [Sat, 15 Nov 2014 01:59:57 +0000 (17:59 -0800)]
Add annotation to all assembly files to turn off stack-execute bit

See discussion in http://tracker.ceph.com/issues/10114

Building with these changes allows output from readelf like this:

 $ readelf -lW src/.libs/librados.so.2 | grep GNU_STACK
  GNU_STACK      0x000000 0x0000000000000000 0x0000000000000000 0x000000
0x000000 RW  0x8

(note the absence of 'X' in 'RW')

Fixes: #10114
Signed-off-by: Dan Mick <dan.mick@redhat.com>
(cherry picked from commit 06a245a9845c0c126fb3106b41b2fd2bc4bc4df3)
(not-yet-present-in-firefly files in isa-l manually removed)

10 years agoMerge pull request #2760 from ceph/wip-9835-firefly
Samuel Just [Thu, 13 Nov 2014 18:36:12 +0000 (10:36 -0800)]
Merge pull request #2760 from ceph/wip-9835-firefly

osd: fix erasure hung op bug (9835)

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoosd: use OSDMap helper to tell if ops are misdirected 2760/head
Samuel Just [Wed, 5 Nov 2014 20:12:14 +0000 (12:12 -0800)]
osd: use OSDMap helper to tell if ops are misdirected

calc_pg_role doesn't actually take into account primary affinity.

Fixes: #9835
Signed-off-by: Samuel Just <sam.just@inktank.com>
10 years agoosd: discard rank > 0 ops on erasure pools
Sage Weil [Mon, 20 Oct 2014 20:55:33 +0000 (13:55 -0700)]
osd: discard rank > 0 ops on erasure pools

Erasure pools do not support read from replica, so we should drop
any rank > 0 requests.

This fixes a bug where an erasure pool maps to [1,2,3], temporarily maps
to [-1,2,3], sends a request to osd.2, and then remaps back to [1,2,3].
Because the 0 shard never appears on osd.2, the request sits in the
waiting_for_pg map indefinitely and cases slow request warnings.
This problem does not come up on replicated pools because all instances of
the PG are created equal.

Fix by only considering role == 0 for erasure pools as a correct mapping.

Fixes: #9835
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoosd/OSDMap: add osd_is_valid_op_target()
Sage Weil [Thu, 13 Nov 2014 01:04:35 +0000 (17:04 -0800)]
osd/OSDMap: add osd_is_valid_op_target()

Helper to check whether an osd is a given op target for a pg.  This
assumes that for EC we always send ops to the primary, while for
replicated we may target any replica.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 89c02637914ac7332e9dbdbfefc2049b2b6c127d)

10 years agoqa: allow small allocation diffs for exported rbds
Josh Durgin [Wed, 12 Nov 2014 02:16:02 +0000 (18:16 -0800)]
qa: allow small allocation diffs for exported rbds

The local filesytem may behave slightly differently. This isn't
foolproof, but seems to be reliable enough on rhel7 rootfs, where
exact comparison was failing.

Fixes: #10002
Signed-off-by: Josh Durgin <jdurgin@redhat.com>
(cherry picked from commit e94d3c11edb9c9cbcf108463fdff8404df79be33)

10 years agoosd: fix map advance limit to handle map gaps
Sage Weil [Sun, 25 May 2014 15:38:38 +0000 (08:38 -0700)]
osd: fix map advance limit to handle map gaps

The recent change in cf25bdf6b0090379903981fe8cee5ea75efd7ba0 would stop
advancing after some number of epochs, but did not take into consideration
the possibilty that there are missing maps.  In that case, it is impossible
to advance past the gap.

Fix this by increasing the max epoch as we go so that we can always get
beyond the gap.

Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 1e0a82fd55dede473c0af32924f4bcb5bb697a2b)

10 years agoMerge pull request #2880 from ceph/wip-10025-firefly
Gregory Farnum [Fri, 7 Nov 2014 22:10:18 +0000 (14:10 -0800)]
Merge pull request #2880 from ceph/wip-10025-firefly

#10025/firefly -- tools: fix MDS journal import

Reviewed-by: Greg Farnum <greg@inktank.com>
10 years agotools: fix MDS journal import 2880/head
John Spray [Fri, 7 Nov 2014 11:34:43 +0000 (11:34 +0000)]
tools: fix MDS journal import

Previously it only worked on fresh filesystems which
hadn't been trimmed yet, and resulted in an invalid
trimmed_pos when expire_pos wasn't on an object
boundary.

Fixes: #10025
Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit fb29e71f9a97c12354045ad2e128156e503be696)

10 years agoMerge remote-tracking branch 'origin/wip-sam-firefly-backports' into firefly
Samuel Just [Thu, 6 Nov 2014 18:37:42 +0000 (10:37 -0800)]
Merge remote-tracking branch 'origin/wip-sam-firefly-backports' into firefly

10 years agoMerge pull request #2737 from ceph/wip-9629-firefly
Samuel Just [Thu, 6 Nov 2014 18:30:20 +0000 (10:30 -0800)]
Merge pull request #2737 from ceph/wip-9629-firefly

osd: do not clone/preserve snapdir on cache-evict (firefly backport)

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #2657 from ceph/wip-9053-9301-firefly
Samuel Just [Thu, 6 Nov 2014 18:26:21 +0000 (10:26 -0800)]
Merge pull request #2657 from ceph/wip-9053-9301-firefly

mon: backport two paxos fixes to firefly

Reviewed-by: Joao Luis <joao@redhat.com>
10 years agoMerge pull request #2656 from ceph/wip-9502-firefly
Samuel Just [Thu, 6 Nov 2014 18:21:12 +0000 (10:21 -0800)]
Merge pull request #2656 from ceph/wip-9502-firefly

mon: backport mon disk full check to firefly

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #2764 from ceph/wip-9851
Samuel Just [Thu, 6 Nov 2014 18:18:27 +0000 (10:18 -0800)]
Merge pull request #2764 from ceph/wip-9851

osd: bring FileJournal in sync with giant

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #2776 from ceph/wip-9675.firefly
Samuel Just [Thu, 6 Nov 2014 18:12:17 +0000 (10:12 -0800)]
Merge pull request #2776 from ceph/wip-9675.firefly

CrushWrapper: pick a ruleset same as rule_id

Reviewed-by: Samuel Just <sam.just@inktank.com>
10 years agoceph-disk: mount xfs with inode64 by default
Sage Weil [Mon, 15 Sep 2014 22:29:08 +0000 (15:29 -0700)]
ceph-disk: mount xfs with inode64 by default

We did this forever ago with mkcephfs, but ceph-disk didn't.  Note that for
modern XFS this option is obsolete, but for older kernels it was not the
default.

Backport: firefly
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 11496399ef318498c11e551f139d96db52d3309c)

10 years agorgw: set length for keystone token validation request
Yehuda Sadeh [Thu, 9 Oct 2014 17:20:27 +0000 (10:20 -0700)]
rgw: set length for keystone token validation request

Fixes: #7796
Backport: giany, firefly
Need to set content length to this request, as the server might not
handle a chunked request (even though we don't send anything).

Tested-by: Mark Kirkwood <mark.kirkwood@catalyst.net.nz>
Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 3dd4ccad7fe97fc16a3ee4130549b48600bc485c)

10 years agorgw: subuser creation fixes
Yehuda Sadeh [Tue, 19 Aug 2014 20:15:46 +0000 (13:15 -0700)]
rgw: subuser creation fixes

Fixes: #8587
There were a couple of issues, one when trying to identify whether swift
user exists, we weren't using the correct swift id. The second problem
is that we relied on the gen_access flag in the swift case, where it
doesn't really need to apply.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 1441ffe8103f03c6b2f625f37adbb2e1cfec66bb)

10 years agoMerge pull request #2847 from dachary/wip-9752-past-intervals-firefly
Sage Weil [Fri, 31 Oct 2014 15:35:50 +0000 (08:35 -0700)]
Merge pull request #2847 from dachary/wip-9752-past-intervals-firefly

osd: past_interval display bug on acting

10 years agoosd: past_interval display bug on acting 2847/head
Loic Dachary [Thu, 30 Oct 2014 23:49:21 +0000 (00:49 +0100)]
osd: past_interval display bug on acting

The acting array was incorrectly including the primary and up_primary.

http://tracker.ceph.com/issues/9752 Fixes: #9752

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
(cherry picked from commit c5f8d6eded52da451fdd1d807bd4700221e4c41c)

10 years agoMerge pull request #2840 from ceph/firefly-9869
Yan, Zheng [Fri, 31 Oct 2014 00:01:24 +0000 (17:01 -0700)]
Merge pull request #2840 from ceph/firefly-9869

Backport "client: cast m->get_client_tid() to compare to 16-bit Inode::flushing_cap_tid"

10 years agoclient: cast m->get_client_tid() to compare to 16-bit Inode::flushing_cap_tid 2840/head
Greg Farnum [Thu, 23 Oct 2014 00:16:31 +0000 (17:16 -0700)]
client: cast m->get_client_tid() to compare to 16-bit Inode::flushing_cap_tid

m->get_client_tid() is 64 bits (as it should be), but Inode::flushing_cap_tid
is only 16 bits. 16 bits should be plenty to let the cap flush updates
pipeline appropriately, but we need to cast in the proper direction when
comparing these differently-sized versions. So downcast the 64-bit one
to 16 bits.

Fixes: #9869
Backport: giant, firefly, dumpling

Signed-off-by: Greg Farnum <greg@inktank.com>
(cherry picked from commit a5184cf46a6e867287e24aeb731634828467cd98)

10 years agoReplicatedPG: cancel cb on blacklisted watcher
Samuel Just [Thu, 11 Sep 2014 20:46:51 +0000 (13:46 -0700)]
ReplicatedPG: cancel cb on blacklisted watcher

Fixes: #8315
Backport: firefly
Signed-off-by: Samuel Just <sam.just@inktank.com>
(cherry picked from commit 16bd45777166c29c433af3b59254a7169e512d98)