Sage Weil
dbc002eaa9
common/AsyncReserver: support preemption
...
If an (optional) preemption context is provided, use that to preempt
and existing reservation and grant a higher-priority one.
Signed-off-by: Sage Weil <sage@redhat.com>
2017-09-27 15:40:18 -04:00
Adam C. Emerson
16de0fc1c5
rgw: Check bucket versioning operations in policy
...
Add code to check s3:GetBucketVersioning and s3:PutBucketVersioning
operations against bucket policy.
Fixes: http://tracker.ceph.com/issues/21389
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1490278
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
2017-09-27 14:35:59 -04:00
Adam C. Emerson
f9d1ae1d15
rgw: Check payment operations in policy
...
Add code to check s3:GetBucketRequestPayment and
s3:PutBucketRequestPayment operations against bucket policy.
Fixes: http://tracker.ceph.com/issues/21389
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1490278
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
2017-09-27 13:58:32 -04:00
Sage Weil
2237624846
Merge pull request #17978 from alram/rbdmap-fix
...
rbdmap: fix umount when multiple mounts use the same RBD
Reviewed-by: Dan Mick <dmick@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
2017-09-27 12:57:33 -05:00
Patrick Donnelly
bfc4902495
mds: fix conf types
...
This correct an assertion failure.
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2017-09-27 09:29:39 -07:00
Patrick Donnelly
8a5d71bf45
mds: fix whitespace
...
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2017-09-27 09:29:23 -07:00
Casey Bodley
f3e0e0171d
Merge pull request #17962 from joscollin/wip-test-signed-unsigned-warning
...
test: silence warnings from -Wsign-compare
Reviewed-by: Amit Kumar <amitkuma@redhat.com>
Reviewed-by: Casey Bodley <cbodley@redhat.com>
2017-09-27 10:26:49 -04:00
John Spray
f409099fa2
mgr/dashboard: sort servers and OSDs in OSD list
...
Fixes: http://tracker.ceph.com/issues/21572
Signed-off-by: John Spray <john.spray@redhat.com>
2017-09-27 15:14:58 +01:00
John Spray
f43859d4dc
mgr/dashboard: handle null in format_number
...
Fixes: http://tracker.ceph.com/issues/21570
Signed-off-by: John Spray <john.spray@redhat.com>
2017-09-27 14:33:58 +01:00
John Spray
409b8923a2
mgr/dashboard: remove ceph.com ref to favicon
...
We have a local copy referenced in the very next line.
Signed-off-by: John Spray <john.spray@redhat.com>
2017-09-27 14:30:07 +01:00
xie xingguo
076e94d0ca
osd/osd_types: kill osd_peer_stat_t
...
Which currently has no more consumers.
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2017-09-27 18:57:36 +08:00
Matt Boyle
3bae00a033
doc: Fix typos in placement-groups.rst
...
Signed-off-by: Matt Boyle <matt.boyle@gmail.com>
2017-09-27 11:11:23 +01:00
Jos Collin
4483bc7c61
Merge pull request #17988 from wumingqiao/wip-rados-update
...
include/rados: fix typo in librados.h
Reviewed-by: Jos Collin <jcollin@redhat.com>
2017-09-27 09:07:29 +00:00
xie xingguo
db20328b45
osd/PrimaryLogPG: kick off recovery on backoffing a degraded object
...
As we are now blocking frontend ops from accessing that very object!
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2017-09-27 16:58:19 +08:00
wumingqiao
99d79afe6e
include/rados: fix typo in librados.h
...
opeprate -> operate
Signed-off-by: wumingqiao <wumingqiao@inspur.com>
2017-09-27 16:31:14 +08:00
Kefu Chai
671a4106b3
doc: fix hyper link to radosgw/config-ref
...
Signed-off-by: Kefu Chai <kchai@redhat.com>
2017-09-27 11:13:35 +08:00
Zac Medico
18cbba4d2d
osd/PGPool::update: optimize with subset_of
...
Replace expensive inverval_set intersection_of and operator==
calls with a single subset_of call. I borrowed this idea from
Piotr Dałek's "osd/PGPool: don't use intermediate interval set"
patch. The following benchmark program demonstrates a 38%
performance increase:
#include <iostream>
#include <chrono>
#include "include/interval_set.h"
#define NANOSECONDS(d) \
std::chrono::duration_cast<std::chrono::nanoseconds>(d).count()
typedef uint64_t snapid_t;
typedef std::chrono::steady_clock::duration duration;
duration PGPool_update_old(const interval_set<snapid_t> &rs) {
std::chrono::steady_clock::time_point start, end;
interval_set<snapid_t> newly_removed_snaps, cached_removed_snaps;
// initialize state
cached_removed_snaps = rs;
// start timed simulation
start = std::chrono::steady_clock::now();
{
newly_removed_snaps = cached_removed_snaps;
interval_set<snapid_t> intersection;
intersection.intersection_of(newly_removed_snaps, cached_removed_snaps);
assert(intersection == cached_removed_snaps);
cached_removed_snaps.swap(newly_removed_snaps);
newly_removed_snaps = cached_removed_snaps;
newly_removed_snaps.subtract(intersection);
}
// end timed simulation
end = std::chrono::steady_clock::now();
return end - start;
}
duration PGPool_update_new(const interval_set<snapid_t> &rs) {
std::chrono::steady_clock::time_point start, end;
interval_set<snapid_t> newly_removed_snaps, cached_removed_snaps;
// initialize state
cached_removed_snaps = rs;
// start timed simulation
start = std::chrono::steady_clock::now();
{
newly_removed_snaps = cached_removed_snaps;
assert(cached_removed_snaps.subset_of(newly_removed_snaps));
interval_set<snapid_t> removed_snaps = newly_removed_snaps;
newly_removed_snaps.subtract(cached_removed_snaps);
cached_removed_snaps.swap(removed_snaps);
}
// end timed simulation
end = std::chrono::steady_clock::now();
return end - start;
}
int main(int argc, char *argv[])
{
assert(argc == 3);
const int sample_count = std::stoi(argv[1]);
const int interval_count = std::stoi(argv[2]);
const int interval_distance = 4;
const int interval_size = 2;
const int max_offset = interval_count * interval_distance;
interval_set<snapid_t> removed_snaps;
for (int i = 0; i < max_offset; i += interval_distance)
removed_snaps.insert(i, interval_size);
duration old_delta(0), new_delta(0);
for (int i = 0; i < sample_count; ++i) {
old_delta += PGPool_update_old(removed_snaps);
new_delta += PGPool_update_new(removed_snaps);
}
float ratio = float(NANOSECONDS(old_delta)) / NANOSECONDS(new_delta);
std::cout << ratio << std::endl;
}
Suggested-by: Piotr Dałek <piotr.dalek@corp.ovh.com>
Signed-off-by: Zac Medico <zmedico@gmail.com>
2017-09-26 18:33:15 -07:00
Zac Medico
5c3775815a
inverval_set: optimize subset_of with sequential search
...
Optimize subset_of to use sequential search when it
performs better than the lower_bound method, for set
size ratios smaller than 10. This is analogous to
intersection_of behavior since commit 825470fcf9
.
The subset_of method can be used in some cases as a
less-expensive alternative to the intersection_of
method, since subset_of can return early if any element
of the smaller set is not contained in the larger set,
and intersection_of has the added burden of storing
the intersecting elements.
Signed-off-by: Zac Medico <zmedico@gmail.com>
2017-09-26 17:33:35 -07:00
Alexandre Marangone
40825daece
rbdmap: fix umount when multiple mounts use the same RBD
...
When a Kubernetes Pod consumes a RBD it is mounted two
times on the same host. When the host shutdown umount will
fail leading to a hung system
Signed-off-by: Alexandre Marangone <amarango@redhat.com>
2017-09-26 16:19:25 -07:00
Yuri Weinstein
85f3227885
Merge pull request #17063 from bspark8/wip-dynamic-cli-info-f
...
osd: use dmclock library client_info_f function dynamically
Reviewed-by: J. Eric Ivancich <ivancich@redhat.com>
2017-09-26 16:02:19 -07:00
Yuri Weinstein
cf1bcf5b3b
Merge pull request #17335 from Carudy/cxw
...
crush: safe check for 'ceph osd crush swap-bucket'
Reviewed-by: Kefu Chai <kchai@redhat.com>
2017-09-26 16:01:14 -07:00
Yuri Weinstein
4d50fb56b8
Merge pull request #17410 from zmedico/PGPool-update-optimize-removed_snaps-comparison-when-possible
...
PGPool::update: optimize removed_snaps comparison when possible
Reviewed-by: Gregory Farnum <gfarnum@redhat.com>
2017-09-26 15:59:59 -07:00
Adam C. Emerson
0d8c52a906
common/options.h: Do not use linked lists of pointers
...
Especially since we're just pushing things in from the end. The linked
list has more overhead, is slower, and adds no capability.
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
2017-09-26 18:37:31 -04:00
Sage Weil
36c178feb0
Merge pull request #17980 from liewegas/wip-boost-url
...
make-dist,cmake: move boost tarball location to download.ceph.com
Reviewed-by: Jeff Layton <jlayton@redhat.com>
2017-09-26 17:07:03 -05:00
Sage Weil
19987549e0
make-dist,cmake: move boost tarball location to download.ceph.com
...
Sourceforge is down. Also, we can hammer our servers instead of
theirs.
Signed-off-by: Sage Weil <sage@redhat.com>
2017-09-26 17:22:36 -04:00
amitkuma
b9ff4510aa
include,messages,rbd: Initialize counter,group_pool
...
Fixes the coverity issues:
** 1396182 Uninitialized scalar field
CID 1396182 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)
2. uninit_member: Non-static class member counter is not initialized
in this constructor nor in any functions that it calls.
** 1396194 Uninitialized scalar field
CID 1396194 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)
2. uninit_member: Non-static class member group_pool is not initialized
in this constructor nor in any functions that it calls
Signed-off-by: Amit Kumar <amitkuma@redhat.com>
2017-09-26 23:32:42 +05:30
Matt Benjamin
bf99f4d86b
Merge pull request #17589 from myENA/feature/20883-adminapi_sync_stats_master
...
rgw: admin api - add ability to sync user stats from admin api
2017-09-26 12:45:24 -04:00
Matt Benjamin
fcc014cdb0
Merge pull request #17433 from C2python/check_action
...
rgw: Return Error if Bucket Policy Contians Undefined Action
2017-09-26 12:40:08 -04:00
Jason Dillaman
2360bfca75
Merge pull request #17969 from ceph/rbd-mirror-reboot
...
systemd: rbd-mirror does not start on reboot
Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2017-09-26 12:10:16 -04:00
xie xingguo
ef0c60fe08
os/bluestore/BlueFS: check device id before using hint
...
As we might be allocating space from different devices (though
the chance is rare).
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2017-09-26 21:45:54 +08:00
xie xingguo
80e14271db
os/bluestore/BlueFS: drop redundant merge logic of pextents
...
As Allocator will handle it automatically and efficiently!
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2017-09-26 21:45:54 +08:00
xie xingguo
6228d5ee22
os/bluestore/BlueFS: kill block_total
...
As block_all will suffice for the same purpose.
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2017-09-26 21:45:54 +08:00
Sage Weil
62bbfc1b4d
Merge pull request #17929 from renhwztetecs/renhw-wip-mgrmon-command_descs_prefix
...
mon/mgr: sync "mgr_command_descs","osd_metadata" and "mgr_metadata" prefixes to new mons
Reviewed-by: Kefu Chai <kchai@redhat.com>
2017-09-26 08:38:14 -05:00
Sage Weil
0227c91649
Merge pull request #17932 from jcsp/wip-21197
...
mgr: store declared_types in MgrSession
Reviewed-by: Kefu Chai <kchai@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
2017-09-26 08:36:24 -05:00
Sage Weil
03137272eb
Merge pull request #17933 from jcsp/wip-17737
...
mgr: fix crashable DaemonStateIndex::get calls
Reviewed-by: Kefu Chai <kchai@redhat.com>
2017-09-26 08:35:52 -05:00
Sage Weil
e2aef59dd7
Merge pull request #17944 from thmour/tmour_upmap
...
osd/OSDMap: upmap should respect the osd reweights
Reviewed-by: Sage Weil <sage@redhat.com>
2017-09-26 08:35:07 -05:00
Matt Benjamin
637eead62f
Merge pull request #17880 from amitkumar50/cov-rgw-9
...
rgw: Error check on return of read_line()
2017-09-26 08:29:09 -04:00
Sébastien Han
e6cd9570ba
rbd-mirorr: does not start on reboot
...
The current systemd unit file misses 'PartOf=ceph-rbd-mirror.target',
which results in the unit not starting after reboot.
If you have ceph-rbd-mirror@rbd-mirror.ceph-rbd-mirror0 , it won't start
after reboot even if enabled.
Adding 'PartOf=ceph-rbd-mirror.target' will enable
ceph-rbd-mirror.target when ceph-rbd-mirror@rbd-mirror.ceph-rbd-mirror0
gets enabled.
Signed-off-by: Sébastien Han <seb@redhat.com>
2017-09-26 14:05:37 +02:00
John Spray
99b15792a3
Merge pull request #17961 from tchaikov/wip-doc-local-pool-in-toc
...
doc/mgr: add "local pool" plugin to toc
Reviewed-by: John Spray <john.spray@redhat.com>
2017-09-26 11:31:09 +01:00
Kefu Chai
dca1306347
Merge pull request #17949 from asomers/nproc_freebsd
...
do_{cmake,freebsd}: Don't invoke nproc(1) on FreeBSD
Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Willem Jan Withagen <wjw@digiware.nl>
Reviewed-by: Kefu Chai <kchai@redhat.com>
2017-09-26 17:45:56 +08:00
Kefu Chai
d4da5e2063
Merge pull request #17940 from jcsp/wip-21534
...
mon: update get_store_prefixes implementations
Reviewed-by: Joao Eduardo Luis <joao@suse.de>
Reviewed-by: Kefu Chai <kchai@redhat.com>
2017-09-26 17:09:54 +08:00
Jos Collin
fdbbe8a32c
test: silence warnings from -Wsign-compare
...
Fixed the warnings:
ceph/src/test/bufferlist.cc:2150:3: required from here
ceph/src/googletest/googletest/include/gtest/gtest.h:1392:11: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (lhs == rhs) {
ceph/src/test/bufferlist.cc:2151:3: required from here
ceph/src/googletest/googletest/include/gtest/gtest.h:1392:11: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (lhs == rhs) {
Signed-off-by: Jos Collin <jcollin@redhat.com>
2017-09-26 10:24:15 +05:30
Kefu Chai
0b831e7886
doc/mgr: add "local pool" plugin to toc
...
Signed-off-by: Kefu Chai <kchai@redhat.com>
2017-09-26 12:10:28 +08:00
Kefu Chai
7682b50699
automake: remove files required by automake
...
INSTALL, NEWS, README, AUTHORS, and ChangeLog are required by automake,
since we've switched to cmake, remove the empty ones.
Signed-off-by: Kefu Chai <kchai@redhat.com>
2017-09-26 12:04:59 +08:00
Kefu Chai
0be2b8baf5
Merge pull request #17842 from MahatiC/fix_example
...
examples: fix link order in librados example Makefile
Reviewed-by: Kefu Chai <kchai@redhat.com>
2017-09-26 11:15:14 +08:00
Jason Dillaman
22149303a5
Merge pull request #17633 from yonghengdexin735/wip-zzz-doc
...
doc/rbd: add info for rbd group
Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2017-09-25 21:40:32 -04:00
Jason Dillaman
642afd2f5f
Merge pull request #17803 from amitkumar50/cov-librbd-5
...
test: address coverity false positives
Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2017-09-25 21:33:36 -04:00
Jason Dillaman
12d97f232f
Merge pull request #17800 from amitkumar50/cov-misc-8
...
test/librbd: initialize on_finish,locker,force,snap_id
Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2017-09-25 21:31:58 -04:00
Alan Somers
44c6a47fb6
do_{cmake,freebsd}: Don't invoke nproc(1) on FreeBSD
...
Use sysctl(8) instead. Also, there's no longer any need for /bin/bash
on FreeBSD.
Signed-off-by: Alan Somers <asomers@gmail.com>
2017-09-25 16:24:06 -06:00
Sage Weil
e643d5c0fe
Merge pull request #17813 from liewegas/wip-21410-note
...
PendingReleaseNotes: note about upmap mapping change in luminous release notes
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
2017-09-25 16:36:36 -05:00