Commit Graph

52351 Commits

Author SHA1 Message Date
Sage Weil
8166042a28 osd/Watch: slightly more informative debug output
Signed-off-by: Sage Weil <sage@redhat.com>
2016-04-13 15:32:39 -04:00
Etienne Menguy
0f8585c36c doc: fix dependencies
Signed-off-by: Etienne Menguy <etienne.menguy@corp.ovh.com>
2016-04-13 19:31:16 +00:00
Boris Ranto
62084375fa systemd: Use the same restart limits as upstart
Currently, the systemd daemons are not restarted on failure. This patch
adds this functionality and sets the defaults to those defined in
upstart. This resolves to 3 fails per 30 minutes for osd, mon and mds
and 5 fails per 30 seconds for radosgw.

Signed-off-by: Boris Ranto <branto@redhat.com>
2016-04-13 21:26:31 +02:00
Casey Bodley
a201365aaa rgw: call rgw_log_usage_finalize() on reconfiguration
RGWRealmReloader was calling rgw_log_usage_init() with the new RGWRados
instance, but never cleaned up the previous one with
rgw_log_usage_finalize()

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2016-04-13 13:30:18 -04:00
Jason Dillaman
4b1d1698ba test: image replayer needs dummy remote mirror peer uuid
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-13 12:35:32 -04:00
Sage Weil
4943a55528 Merge pull request #8498 from liewegas/wip-bluestore
os/bluestore: fix shortened bluefs paths in env mirror case
2016-04-13 11:26:44 -04:00
Casey Bodley
5230967dad rgw: RGWPeriod::reflect() sets master zonegroup as default
if RGWPeriod::reflect() is called right after a 'realm pull', it will
create the zonegroup objects but not set any as default.  so the next
time RGWRados is initialized, create_defaults() will add a new 'default'
zonegroup and set it as the master.  this causes a 'period update' to
find multiple master zonegroups and fail with EINVAL

reflect() now calls set_as_default(exclusive=true) on the master
zonegroup to guarantee that a default is set

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2016-04-13 10:44:17 -04:00
Jason Dillaman
877d44bcd0 journal: race possible when re-watching a journal object
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-13 10:34:24 -04:00
Matt Benjamin
b6297a704b rgw_file: fix silly abuse of flags in fh_lookup
Initially lookup_fh used its cflags argument just to proxy create
flags to new objects.  It's used for call path state now too, so
disambiguate it, and of course, fh->flags can't be consulted for
a call path state.

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-13 10:14:41 -04:00
Sage Weil
6651e51408 os/bluestore: fix shortened bluefs paths in env mirror case
If we are mirroring the rocksdb env, don't shorten the
paths.

Signed-off-by: Sage Weil <sage@redhat.com>
2016-04-13 09:29:16 -04:00
Matt Benjamin
fb924f2382 rgw_file: don't need to memset Latch
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-13 09:21:47 -04:00
Matt Benjamin
842828a32e cohort_lru: define ctor for TreeX::Latch
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-13 09:19:40 -04:00
Sage Weil
6abc5d761a Merge pull request #8556 from liewegas/wip-ext4
doc: recommend against ext4

Reviewed-by: Alfredo Deza <adeza@redhat.com>
Reviewed-by: Nathan Cutler <ncutler@suse.cz>
2016-04-13 09:19:19 -04:00
Kefu Chai
05968dbb61 Merge pull request #8574 from tchaikov/wip-readable-test-fix
test/encoding/readable: use [ for "test" not ((

Reviewed-by: Erwan Velu <erwan@redhat.com>
2016-04-13 20:32:50 +08:00
Orit Wasserman
1caef9807d Merge pull request #8567 from cbodley/wip-rgw-period-pull-url
radosgw-admin: allow 'period pull --url' without full multisite config
Reviewed-by: Orit Wasserman <owasserm@redhat.com>
2016-04-13 13:30:05 +02:00
Kefu Chai
8d346acb4f test/encoding/readable: use [ for "test" not ((
and use '&&' instead, easier to understand.

this also fixes following error in the ubuntu gitbuilder

error: Added files:
+ cat .git/added-files
src/0

where sh points to dash.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-04-13 16:21:09 +08:00
xie xingguo
f30db90465 osd: clear requeue_scrub_on_unblock flag after requeue scrub
We'd better clear requeue_scrub_on_unblock flag after successfully
requeuing scrub, this is for:
  1. if a newly initiated scrub is blocked by objectcontext again,
     reset requeue_scrub_on_unblock to true will be satisfied enough
     to meet such an appeal.
  2. so we don't push pg to the scrub queue when we don't want to
     by accident.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2016-04-13 11:12:57 +08:00
Jason Dillaman
760863f47e journal: potential for double-free of context on shut down
The context associated with a scheduled watch might be freed
by two ObjectPlayers.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-12 22:29:50 -04:00
Matt Benjamin
5b608ed661 rgw_file: fix 2 attr decoding issues
* fix general timestamp decoding (changing to a pointer notation)
* capture (std::swap) req_state->bucket_attrs in RGWLibStatBucketRequest

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 21:31:46 -04:00
Jason Dillaman
11a9722b45 journal: possible race condition during live replay
When two objects are being actively watched, it was possible for
the watch context to complete before the second watch was
associated.

Fixes: http://tracker.ceph.com/issues/15352
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-12 21:29:12 -04:00
Josh Durgin
aece82440b doc: reinstate accidentally removed section header
Accidentally removed in 63be401a411ffc7c2f78e450a29c69eee1af02d3

Signed-off-by: Josh Durgin <jdurgin@redhat.com>
2016-04-12 18:07:41 -07:00
Casey Bodley
942504d22d radosgw-admin: 'realm pull' only accepts --url
'realm pull' is defined as a 'raw storage op', so cannot use the
--remote argument to refer to endpoints from the period or local
zonegroup

refactored send_to_url() slightly to make it easier to call directly

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2016-04-12 17:14:50 -04:00
Casey Bodley
70ff086a50 radosgw-admin: allow 'period pull --url' without full multisite config
to support 'period pull --remote', radosgw-admin needs a complete
multisite configuration to look up remote endpoints by name

however, 'period pull' will also accept a --url argument, which doesn't
require a working configuration. this patch splits the handling of these
two cases, so that 'period pull --url' can succeed when run on a cluster
that hasn't yet been fully configured

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2016-04-12 17:14:50 -04:00
Sage Weil
18a5fddb90 Merge pull request #8520 from yuyuyu101/wip-15440
msg/async: AsyncConnection: avoid is_connected require connection's lock
2016-04-12 16:23:57 -04:00
Jason Dillaman
8451c0f86e librbd: cancel ops before blocking IO
Ops might have in-flight IO -- blocking IO after canceling the ops
will result in the in-flight IO being flushed.  Shutdown also requires
an intermediate state where is still acts like it downs the lock
until after all ops are canceled and all IO is flushed.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-12 16:23:44 -04:00
Jason Dillaman
e90e3d90eb librbd: delay invalidation of exclusive lock pointer
Certain IO and maintenance ops code paths have an expectation
that the exclusive lock pointer will be valid while in-flight.
Let the exclusive lock state machine clean up the pointer after
it has flushed all IO and canceled all ops.

Fixes: http://tracker.ceph.com/issues/15471
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-12 16:23:44 -04:00
Jason Dillaman
1e6fc45337 rbd: cleanly fail bench-write upon failure
Fixes: http://tracker.ceph.com/issues/15456
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-12 16:23:44 -04:00
Jason Dillaman
1761a38f76 librbd: gracefully handle blacklisted client in ImageWatcher
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-04-12 16:23:44 -04:00
Matt Benjamin
5d8b656136 rgw_file: force move semantics on rvalue refs in emplace_attrs
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:13:18 -04:00
Matt Benjamin
b9ce8405a5 rgw_file: remove RGWLibFS::mkdir() (no longer called)
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:13:10 -04:00
Matt Benjamin
917a25d047 rgw_file: fix nfsns unit test when !created and !create
Avoid dereferencing unitialized top-level objects when !found and the
create option not present (when means we cannot create them).

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:13:00 -04:00
Matt Benjamin
bd2c681837 rgw_file: check for leaf dir objects and restore their state
This change makes Unix/NFS attributes persistent.

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:12:50 -04:00
Matt Benjamin
9830f95878 rgw_file: use emplace_attr in both paths in mkdir2()
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:12:42 -04:00
Matt Benjamin
601b193874 rgw_file: use emplace_attr in RGWCreateBucket and RGWCopyObj
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:12:33 -04:00
Matt Benjamin
7a7de9b752 rgw_file: use emplace_attr in RGWPostObj and RGWPutMetadataBucket
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:12:23 -04:00
Matt Benjamin
8b2616b639 rgw_file: remove unused label in mkdir2()
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:12:15 -04:00
Matt Benjamin
6bda1e03e2 rgw_file: use emplace_attr in RGWPutObj::execute()
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:11:58 -04:00
Matt Benjamin
6a86ed9f8e rgw_file: encode ux attrs in mkdir2
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:11:09 -04:00
Matt Benjamin
8f5ff953c8 rgw_file: implement new mkdir2 with atomicity
Re-order lookup_fh, FLAG_CREATE and remote create operations,
and provide FLAG_LOCK, to get atomicity.

Other ops which need to linearize at lookup_fh still need to be
converted.

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:11:00 -04:00
Matt Benjamin
34ba7c02ad rgw_file: add encode/decode hooks, emplace_attr
This change implements attr encode/decode glue for RGWGetObj and
RGWPutObj.  Both now have attr maps as member variables.

To save copies, callers producing attrs can use emplace_attr to
move attrs into the map.

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:10:52 -04:00
Matt Benjamin
2dbefba0d8 rgw_file: move internals of rgw_read into RGWLibFS::read(...)
Initially, all RGWRequest logic was open coded, but it's all
moving into RGWLibFS to get better encapsulation (e.g., for atomicity).

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:10:44 -04:00
Matt Benjamin
8b01e12860 rgw_file: declare encoder for Unix object attributes
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:10:22 -04:00
Matt Benjamin
f87af2547f rgw_file: declare an attribute for all Unix/rgw_file attrs
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2016-04-12 16:09:57 -04:00
Sage Weil
77276aa709 Merge pull request #8559 from liewegas/wip-15643
rgw: fix unsafe c_str() usage

Reviewed-by: Casey Bodley <cbodley@redhat.com>
2016-04-12 14:03:56 -04:00
Jenkins Build Slave User
4a2a6f7264 10.1.2 2016-04-12 17:42:56 +00:00
Sage Weil
489324f113 doc/configuration/filesystem-recommendations: recommend against ext4
Signed-off-by: Sage Weil <sage@redhat.com>
2016-04-12 13:24:56 -04:00
Sage Weil
a8e286915d doc/release-notes: mention ext4 in the release notes
Signed-off-by: Sage Weil <sage@redhat.com>
2016-04-12 13:07:50 -04:00
Sage Weil
112649fc02 doc/start/os-recommendations: drop ancient 'syncfs' note
...and with it it's mention of ext4.

Signed-off-by: Sage Weil <sage@redhat.com>
2016-04-12 13:07:49 -04:00
Sage Weil
638fd2ec2b doc/rados/configuration: minor cleanup of inline xattr description
- whitespace
- it's not omap

Signed-off-by: Sage Weil <sage@redhat.com>
2016-04-12 11:19:13 -04:00
Sage Weil
2601e2fb7e rgw/rgw_rados: use to_str() instead of c_str()
bufferlist::c_str() doesn't guarantee null termination.

Fixes: http://tracker.ceph.com/issues/15463
Signed-off-by: Sage Weil <sage@redhat.com>
2016-04-12 11:15:14 -04:00