]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
13 years agoMerge branch 'wip-rbd-protect' into master
Josh Durgin [Thu, 16 Aug 2012 19:03:41 +0000 (12:03 -0700)]
Merge branch 'wip-rbd-protect' into master

Conflicts:
src/librbd.cc
src/librbd/cls_rbd_client.h

13 years agoceph-fuse: add --fuse-debug option to enable libfuse debugging
Sage Weil [Thu, 16 Aug 2012 16:33:23 +0000 (09:33 -0700)]
ceph-fuse: add --fuse-debug option to enable libfuse debugging

We consume -d (which fuse uses), so it can't be silently passed through
like we used to be able to do.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoMerge branch 'next'
Samuel Just [Wed, 15 Aug 2012 22:21:09 +0000 (15:21 -0700)]
Merge branch 'next'

13 years agoMerge branch 'testing' into next
Samuel Just [Wed, 15 Aug 2012 22:19:02 +0000 (15:19 -0700)]
Merge branch 'testing' into next

13 years agoPG,Message: move intrusive_ptr_* into top namespace
Samuel Just [Wed, 15 Aug 2012 21:40:17 +0000 (14:40 -0700)]
PG,Message: move intrusive_ptr_* into top namespace

gcc 4.7 requires that the intrusive_ptr_* functions be in
the same namespace as the templated class.

Signed-off-by: Samuel Just <sam.just@inktank.com>
13 years agomon: make 'clocks too skewed' message for accurate
Sage Weil [Wed, 15 Aug 2012 18:13:46 +0000 (11:13 -0700)]
mon: make 'clocks too skewed' message for accurate

It could be that the mons are laggy, not skewed.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoMerge branch 'next'
Sage Weil [Tue, 14 Aug 2012 23:54:17 +0000 (16:54 -0700)]
Merge branch 'next'

13 years agoMerge branch 'testing' into next
Sage Weil [Tue, 14 Aug 2012 23:53:48 +0000 (16:53 -0700)]
Merge branch 'testing' into next

13 years agomkcephfs: fix mon_data check
Sage Weil [Tue, 14 Aug 2012 23:53:18 +0000 (16:53 -0700)]
mkcephfs: fix mon_data check

* check the right path <facepalm>
* behave if the directory doesn't exist at all yet

Fixes: #2922
Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoMerge branch 'wip-2918'
Sage Weil [Tue, 14 Aug 2012 23:17:48 +0000 (16:17 -0700)]
Merge branch 'wip-2918'

Reviewed-by: Dan Mick <dan.mick@inktank.com>
13 years agoosdmap: apply mon_max_osd when generating osdmap from conf
Sage Weil [Tue, 14 Aug 2012 21:26:23 +0000 (14:26 -0700)]
osdmap: apply mon_max_osd when generating osdmap from conf

This prevents users from having an [osd.1234567] section and blowing up
their memory usage.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoosdmap: fix pg_num calculation when generating osdmap from conf
Sage Weil [Tue, 14 Aug 2012 23:06:54 +0000 (16:06 -0700)]
osdmap: fix pg_num calculation when generating osdmap from conf

Base num_pg calculation on the number of osds, not the max osd id.

Fixes: #2918
Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoglobal: only print banner if type is daemon
Sage Weil [Tue, 14 Aug 2012 21:59:36 +0000 (14:59 -0700)]
global: only print banner if type is daemon

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomon: throttle daemon messages independently from client messages
Sage Weil [Tue, 14 Aug 2012 22:07:06 +0000 (15:07 -0700)]
mon: throttle daemon messages independently from client messages

This lets us set a higher limit on messages from daemons (osd, mds) than
from clients, and throttle them independently.

Fixes: #2942
Signed-off-by: Sage Weil <sage@inktank.com>
13 years agofilejournal: instrument journal write counts, sizes
Sage Weil [Tue, 14 Aug 2012 21:43:34 +0000 (14:43 -0700)]
filejournal: instrument journal write counts, sizes

This rounds out the low-hanging fruit that are coming to mind.  Moving on.

Fixes: #2619
Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoperfcounters: add u64 average type
Sage Weil [Tue, 14 Aug 2012 21:31:38 +0000 (14:31 -0700)]
perfcounters: add u64 average type

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoglobal: fix version banner in log on startup
Sage Weil [Tue, 14 Aug 2012 21:06:47 +0000 (14:06 -0700)]
global: fix version banner in log on startup

Log banner from global_init().  This puts it at the very top of the log,
right when the daemon starts.

Fixes: #2940
Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoMerge branch 'wip-crush-tunables'
Sage Weil [Tue, 14 Aug 2012 20:13:03 +0000 (13:13 -0700)]
Merge branch 'wip-crush-tunables'

Reviewed-by: Greg Farnum <greg@inktank.com>
13 years agodoc: document use of CRUSH tunables
Sage Weil [Tue, 14 Aug 2012 20:11:15 +0000 (13:11 -0700)]
doc: document use of CRUSH tunables

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomon: require CRUSH_TUNABLES when latest osdmap has tunables set
Sage Weil [Mon, 13 Aug 2012 17:46:30 +0000 (10:46 -0700)]
mon: require CRUSH_TUNABLES when latest osdmap has tunables set

This is an imperfect check in that tunables may be set in past osdmaps,
and the OSDs may need that in order to peer correctly.  However, in the
general case, this will catch most users.  In particular, it will catch

 - set tunables
 - nothing works (osds or clients lack feature)
 - reset/clear tunables
 - things recover

But not

 - set tunables
 - osds have feature, behave
 - new osds with old code added, lack feature
 - remove tunables
 - new osds may fail to peer properly because they lack the feature

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoosd: require CRUSH_TUNABLES feature of peers, clients when used
Sage Weil [Mon, 13 Aug 2012 17:44:08 +0000 (10:44 -0700)]
osd: require CRUSH_TUNABLES feature of peers, clients when used

If the current crush map has non-default tunables, set our messengers to
require the tunables feature bit.  If it does not, clear the bit.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoosd: put throttler on default policy
Sage Weil [Mon, 13 Aug 2012 17:43:39 +0000 (10:43 -0700)]
osd: put throttler on default policy

Before we were associating the throttler with a CLIENT specific policy
that didn't cover MDS.  That's silly.  Instead, associate the throttler
with the default policy (which is now possible).

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsgr: make set_policy_throttler safe, act on default
Sage Weil [Mon, 13 Aug 2012 17:49:03 +0000 (10:49 -0700)]
msgr: make set_policy_throttler safe, act on default

Add locking in set_policy_throttler.

Also, make it act on the default policy when the specified type does not
have a sepcific policy set for it.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsgr: make set_policy() and set_default_policy() safe to re-use
Sage Weil [Mon, 13 Aug 2012 17:48:20 +0000 (10:48 -0700)]
msgr: make set_policy() and set_default_policy() safe to re-use

Introduce a policy_lock in SimpleMessenger to make this safe even after
the messenger has been started up.  The user needs to be aware that
policy changes will not affect connections that are already established.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agodoc: v0.48.1argonaut release notes, changelog
Sage Weil [Tue, 14 Aug 2012 17:06:16 +0000 (10:06 -0700)]
doc: v0.48.1argonaut release notes, changelog

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoMerge branch 'wip-msgr'
Sage Weil [Mon, 13 Aug 2012 20:34:29 +0000 (13:34 -0700)]
Merge branch 'wip-msgr'

13 years agomsg/Accepter: fix nonce initialization
Sage Weil [Mon, 13 Aug 2012 20:15:55 +0000 (13:15 -0700)]
msg/Accepter: fix nonce initialization

This needs to be provided to the Accepter at bind time, not by start().
Otherwise the nonce is effectively always 0, which is useless and breaks
all sorts of things.  Broken by 8453a8198c65712db968ff42be4fd10d2d216582.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoceph-osd: log journal-creation failure with derr
Dan Mick [Mon, 13 Aug 2012 18:46:48 +0000 (11:46 -0700)]
ceph-osd: log journal-creation failure with derr

Fixes: #2938
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Signed-off-by: Dan Mick <dan.mick@inktank.com>
13 years agomsgr: expose get_policy() through generic Messenger API
Sage Weil [Mon, 13 Aug 2012 17:38:52 +0000 (10:38 -0700)]
msgr: expose get_policy() through generic Messenger API

Return a copy instead of a const reference, too...

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agocrush: add helper has_nondefault_tunables()
Sage Weil [Sat, 21 Jul 2012 00:50:35 +0000 (17:50 -0700)]
crush: add helper has_nondefault_tunables()

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agoMerge branch 'wip-msgr'
Sage Weil [Mon, 13 Aug 2012 16:58:49 +0000 (09:58 -0700)]
Merge branch 'wip-msgr'

13 years agocephtool: make command wait for osdmap explicit
Sage Weil [Mon, 13 Aug 2012 16:56:59 +0000 (09:56 -0700)]
cephtool: make command wait for osdmap explicit

If we are waiting for an osdmap for a command, track that explicitly so
that we know when to retry send_command().

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agov0.50 v0.50
Sage Weil [Mon, 13 Aug 2012 16:49:24 +0000 (09:49 -0700)]
v0.50

13 years agoMerge tag 'v0.50'
Sage Weil [Mon, 13 Aug 2012 16:48:49 +0000 (09:48 -0700)]
Merge tag 'v0.50'

v0.50

13 years agomsg/Pipe: discard_queue() -> discard_out_queue()
Sage Weil [Sat, 11 Aug 2012 15:13:39 +0000 (08:13 -0700)]
msg/Pipe: discard_queue() -> discard_out_queue()

We only discard outgoing messages; incoming messages are handled by the
IncomingQueue.. but this method doesn't touch that.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsg/Pipe: simplify Pipe::tcp_read() return value
Sage Weil [Sat, 11 Aug 2012 15:10:14 +0000 (08:10 -0700)]
msg/Pipe: simplify Pipe::tcp_read() return value

0 for success; no reason to return length (always == len).

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsg/Pipe: document tcp_*()
Sage Weil [Sat, 11 Aug 2012 15:03:52 +0000 (08:03 -0700)]
msg/Pipe: document tcp_*()

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsg/Accepter: use learned_addr() from Accepter::bind()
Sage Weil [Sat, 11 Aug 2012 14:52:28 +0000 (07:52 -0700)]
msg/Accepter: use learned_addr() from Accepter::bind()

Normally we never go from need_addr == false to need_addr == true.
It always starts out as true, so this else is useless on the first
call to Accepter::bind().

The only exception is rebind().  Add an unlearn_addr() that will clear
need_addr.  This is almost unnecessary, but doing so fixes a small bug
where the local_connection->peer_addr doesn't get updated when we do a
rebind().

Drop now-unused set_need_addr().  We keep get_need_addr() only because
it is useful in the debug output and for the assert.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsg/SimpleMessenger: push need_addr check into learned_addr()
Sage Weil [Sat, 11 Aug 2012 14:45:18 +0000 (07:45 -0700)]
msg/SimpleMessenger: push need_addr check into learned_addr()

This puts all of the do/do not lock logic in one place, and documents
it.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsg/Accepter: pass nonce on start
Sage Weil [Sat, 11 Aug 2012 14:37:45 +0000 (07:37 -0700)]
msg/Accepter: pass nonce on start

This lets us drop the otherwise awkward SimpleMessenger::get_nonce()
accessor.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsgr: protect set_myaddr()
Sage Weil [Sat, 11 Aug 2012 14:31:35 +0000 (07:31 -0700)]
msgr: protect set_myaddr()

This is used by Messenger implementation (and their constituent
components).

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsg/Accepter: make members private
Sage Weil [Sat, 11 Aug 2012 14:29:38 +0000 (07:29 -0700)]
msg/Accepter: make members private

Nobody uses these.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsgr: remove useless SimpleMessenger::msgr
Sage Weil [Sat, 11 Aug 2012 14:28:32 +0000 (07:28 -0700)]
msgr: remove useless SimpleMessenger::msgr

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agomsgr: some SimpleMessenger docs
Sage Weil [Sat, 11 Aug 2012 14:24:04 +0000 (07:24 -0700)]
msgr: some SimpleMessenger docs

Document basic modules and the lock ordering.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agocephtool: send keepalive to tell target
Sage Weil [Tue, 31 Jul 2012 22:02:55 +0000 (15:02 -0700)]
cephtool: send keepalive to tell target

If we 'ceph tell <foo> ...' to a non-monitor, we need to send keepalives to
ensure we detect a tcp drop.  (Not so for monitors; monclient already does
its own keepalive thing.)

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agocephtool: retry 'ceph tell <who> ...' command if connection fails
Sage Weil [Tue, 31 Jul 2012 21:47:26 +0000 (14:47 -0700)]
cephtool: retry 'ceph tell <who> ...' command if connection fails

It was easy to reproduce a hang with 'ceph osd tell osd.0 foo' and
messenger failure injection.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agocephtool: set messenger policy
Sage Weil [Tue, 31 Jul 2012 21:46:13 +0000 (14:46 -0700)]
cephtool: set messenger policy

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agocephtool: fix deadlock on fault when waiting for osdmap
Sage Weil [Tue, 31 Jul 2012 21:45:51 +0000 (14:45 -0700)]
cephtool: fix deadlock on fault when waiting for osdmap

send_command() was blocking for the osdmap, and also called from the
connect callback.  Instead, re-call it from the handle_osd_map() callback
so that it never blocks.

This was easy to trigger with 'ceph osd tell osd.0 foo' and ms failure
injection.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agorbd: show snap protection status
Josh Durgin [Sun, 12 Aug 2012 23:42:42 +0000 (16:42 -0700)]
rbd: show snap protection status

If you do rbd info image@snap, include whether that snapshot is protected.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agoMonMap: return error on failure in build_initial
Josh Durgin [Wed, 8 Aug 2012 22:24:57 +0000 (15:24 -0700)]
MonMap: return error on failure in build_initial

If mon_host fails to parse, return an error instead of success.
This avoids failing later on an assert monmap.size() > 0 in the
monmap in MonClient.

Fixes: #2913
Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agoaddr_parsing: report correct error message
Josh Durgin [Wed, 8 Aug 2012 22:10:27 +0000 (15:10 -0700)]
addr_parsing: report correct error message

getaddrinfo uses its return code to report failures.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agorbd: fix test compilation on 32-bit
Josh Durgin [Thu, 9 Aug 2012 22:13:46 +0000 (15:13 -0700)]
rbd: fix test compilation on 32-bit

32-bit can't implicitly convert size_t or unsigned to uint64_t

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agotest_librbd_fsx: fix warning
Josh Durgin [Thu, 9 Aug 2012 22:12:55 +0000 (15:12 -0700)]
test_librbd_fsx: fix warning

fstat was included implicitly before.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agorbd: fix cli tests
Josh Durgin [Thu, 9 Aug 2012 21:53:24 +0000 (14:53 -0700)]
rbd: fix cli tests

add flatten, snap protect, and snap unprotect

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agorgw: modify some error messages
Yehuda Sadeh [Thu, 9 Aug 2012 20:54:15 +0000 (13:54 -0700)]
rgw: modify some error messages

Make them more correct, clearer.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agoMerge remote-tracking branch 'origin/wip-rgw-admin'
Yehuda Sadeh [Thu, 9 Aug 2012 20:39:20 +0000 (13:39 -0700)]
Merge remote-tracking branch 'origin/wip-rgw-admin'

13 years agorgw: use multiple notification objects
Yehuda Sadeh [Mon, 18 Jun 2012 20:25:44 +0000 (13:25 -0700)]
rgw: use multiple notification objects

Issue #2504. This makes us listen and notify on more than
a single object, which reduces the contention of cache
notifications.

NOTE: This change requires that any radosgw and radosgw-admin
use the same 'rgw num control oids' config value. A config value
of 0 will maintain old compatibility, and will allow an upgraded
process run in conjuction with an old one. Setting value other
than 0 (or using the non-zero default) will require upgrading
and restarting all the gateways together. Failing to do so
might lead to inconsistent user and buckets metadata (which
will be resolved once gateways are restarted).

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agoradosgw-admin.rst: Misc doccumentation update.
caleb miles [Wed, 25 Jul 2012 19:56:59 +0000 (12:56 -0700)]
radosgw-admin.rst: Misc doccumentation update.

Signed-off-by: caleb miles <caleb.miles@inktank.com>
13 years agorgw_admin.cc: Allow removal of a user's buckets during user removal.
caleb miles [Thu, 9 Aug 2012 20:27:21 +0000 (13:27 -0700)]
rgw_admin.cc: Allow removal of a user's buckets during user removal.

Allow the buckets, and any child objects, of a user to be deleted when the
user is deleted through radosgw-admin. In reference to feature request
2499: http://tracker.newdream.net/issues/2499.

Signed-off-by: caleb miles <caleb.miles@inktank.com>
13 years agolibrados: add method to get the fsid of a cluster
Josh Durgin [Thu, 9 Aug 2012 02:13:45 +0000 (19:13 -0700)]
librados: add method to get the fsid of a cluster

This will be used by OpenStack to check whether two components
have access to the same backend cluster.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: fix memory leak on error in clone
Josh Durgin [Sat, 4 Aug 2012 00:30:04 +0000 (17:30 -0700)]
librbd: fix memory leak on error in clone

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agorbd: add snap [un]protect commands
Josh Durgin [Fri, 3 Aug 2012 23:31:12 +0000 (16:31 -0700)]
rbd: add snap [un]protect commands

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: add methods for protecting/unprotecting snapshots
Josh Durgin [Fri, 3 Aug 2012 23:30:42 +0000 (16:30 -0700)]
librbd: add methods for protecting/unprotecting snapshots

Unprotect will be more useful once integrated with the rbd_children object.
Right now we just check that a snapshot is protected before cloning it,
and that it's unprotected before removing it.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agorgw_admin.cc: Allow for deletion of objects through radosgw-admin.
caleb miles [Thu, 9 Aug 2012 16:55:27 +0000 (09:55 -0700)]
rgw_admin.cc: Allow for deletion of objects through radosgw-admin.

Allow objects to be deleted through radosgw-admin with an optional flag
to delete the tail of that object during the processing of the intent log.

Signed-off-by: caleb miles <caleb.miles@inktank.com>
13 years agodoc: New example usage.
John Wilkins [Thu, 9 Aug 2012 16:21:38 +0000 (09:21 -0700)]
doc: New example usage.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
13 years agorgw: fix usage trim call encoding
Yehuda Sadeh [Wed, 1 Aug 2012 20:22:38 +0000 (13:22 -0700)]
rgw: fix usage trim call encoding

Fixes: #2841.
Usage trim operation was encoding the wrong op structure (usage read).
Since the structures somewhat overlapped it somewhat worked, but user
info wasn't encoded.

Backport: argonaut
Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agocls_rgw: fix rgw_cls_usage_log_trim_op encode/decode
Yehuda Sadeh [Wed, 8 Aug 2012 22:21:53 +0000 (15:21 -0700)]
cls_rgw: fix rgw_cls_usage_log_trim_op encode/decode

It was not encoding user, adding that and reset version
compatibility.
This changes affects command interface, makes use of
radosgw-admin usage trim incompatible. Use of old
radosgw-admin usage trim should be avoided, as it may
remove more data than requested. In any case, upgraded
server code will not handle old client's trim requests.

backport: argonaut
Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agocls_rbd: add methods for getting/setting protection status
Josh Durgin [Fri, 3 Aug 2012 00:22:34 +0000 (17:22 -0700)]
cls_rbd: add methods for getting/setting protection status

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agorgw: expand date format support
Yehuda Sadeh [Tue, 31 Jul 2012 23:17:22 +0000 (16:17 -0700)]
rgw: expand date format support

Relaxing the date format parsing function to allow UTC
instead of GMT.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agorgw: complete multipart upload can handle chunked encoding
Yehuda Sadeh [Thu, 2 Aug 2012 18:13:05 +0000 (11:13 -0700)]
rgw: complete multipart upload can handle chunked encoding

Fixes: #2878
We now allow complete multipart upload to use chunked encoding
when sending request data. With chunked encoding the HTTP_LENGTH
header is not required.

Backport: argonaut
Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agorgw_xml: xml_handle_data() appends data string
Yehuda Sadeh [Wed, 1 Aug 2012 18:19:32 +0000 (11:19 -0700)]
rgw_xml: xml_handle_data() appends data string

Fixes: #2879.
xml_handle_data() appends data to the object instead of just
replacing it. Parsed data can arrive in pieces, specifically
when data is escaped.

Backport: argonaut
Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agorgw: ETag is unquoted in multipart upload complete
Yehuda Sadeh [Wed, 1 Aug 2012 20:09:41 +0000 (13:09 -0700)]
rgw: ETag is unquoted in multipart upload complete

Fixes #2877.
Removing quotes from ETag before comparing it to what we
have when completing a multipart upload.

Backport: argonaut
Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
13 years agodoc: Added debug and logging reference.
John Wilkins [Wed, 8 Aug 2012 22:06:57 +0000 (15:06 -0700)]
doc: Added debug and logging reference.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
13 years agomkcephfs: use default osd_data, _journal values
Sage Weil [Wed, 8 Aug 2012 21:01:53 +0000 (14:01 -0700)]
mkcephfs: use default osd_data, _journal values

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Greg Farnum <greg@inktank.com>
13 years agomkcephfs: use new default keyring locations
Sage Weil [Wed, 8 Aug 2012 21:01:35 +0000 (14:01 -0700)]
mkcephfs: use new default keyring locations

The ceph-conf command only parses the conf; it does not apply default
config values.  This breaks mkcephfs if values are not specified in the
config.

Let ceph-osd create its own key, fix copying, and fix creation/copying for
the mds.

Fixes: #2845
Reported-by: Florian Haas <florian@hastexo.com>
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Greg Farnum <greg@inktank.com>
13 years agoMerge remote-tracking branch 'gh/next'
Sage Weil [Wed, 8 Aug 2012 20:05:12 +0000 (13:05 -0700)]
Merge remote-tracking branch 'gh/next'

13 years agobuffer: make release() private
Sage Weil [Wed, 8 Aug 2012 15:09:59 +0000 (08:09 -0700)]
buffer: make release() private

This should only be called by ~ptr or when we are replacing the current
target with something new.  It is not suitable for external consumption
Because it doesn't reset length and offset.

Signed-off-by: Sage Weil <sage@inktank.com>
13 years agolibrbd: fix bounds of memcpy in info()
Josh Durgin [Wed, 1 Aug 2012 22:42:15 +0000 (15:42 -0700)]
librbd: fix bounds of memcpy in info()

Caught by valgrind.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agotest_librbd_fsx: add cloning
Josh Durgin [Sat, 4 Aug 2012 01:49:44 +0000 (18:49 -0700)]
test_librbd_fsx: add cloning

5% of the time a clone op is chosen, create a snapshot, save the
current contents to a file, and continue operating on a clone.

At the end of the test, verify that all parents match their saved
data.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: expose feature bits through librbd.h
Josh Durgin [Mon, 30 Jul 2012 17:18:19 +0000 (10:18 -0700)]
librbd: expose feature bits through librbd.h

Move them to a separate header so we don't expose
rbd_types.h to the librbd user.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: close parent after shutting down cache
Josh Durgin [Mon, 30 Jul 2012 18:00:43 +0000 (11:00 -0700)]
librbd: close parent after shutting down cache

Requests that haven't been flushed yet might need the parent still.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: move flush on new snap outside of snap_lock
Josh Durgin [Mon, 30 Jul 2012 17:59:29 +0000 (10:59 -0700)]
librbd: move flush on new snap outside of snap_lock

snap_lock needs to be taken during writeback.
This is still protected by md_lock. The altered snapc doesn't
affect in-flight ops, so it's safe to update it before flushing.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: check new snapc for validity, not the old one
Josh Durgin [Mon, 30 Jul 2012 17:52:39 +0000 (10:52 -0700)]
librbd: check new snapc for validity, not the old one

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agotest_librbd: add a simple io to clone test
Josh Durgin [Mon, 30 Jul 2012 17:41:41 +0000 (10:41 -0700)]
test_librbd: add a simple io to clone test

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agotest_rbd.py: refactor cloning tests
Josh Durgin [Wed, 25 Jul 2012 21:32:56 +0000 (14:32 -0700)]
test_rbd.py: refactor cloning tests

Move into a separate class that requires layering to be enabled,
so the common step of creating and deleting a clone doesn't
need to be repeated in each test.

Move flatten tests into a subclass so they can be run separately
more easily.

Move the checks for the layering feature into a generic decorator
that skips tests if the specified feature is not being used.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: don't open parent again during get_parent_info
Josh Durgin [Fri, 20 Jul 2012 17:31:56 +0000 (10:31 -0700)]
librbd: don't open parent again during get_parent_info

The parent was already opened when the original ImageCtx
was initialized. We just need to lookup the pool and image
name for it.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agolibrbd: implement read/write from parent images
Josh Durgin [Tue, 24 Jul 2012 17:13:39 +0000 (10:13 -0700)]
librbd: implement read/write from parent images

Put the completion handling logic into new subclases of
librbd::AioRequest, so the caching/non-caching paths can share
logic. These AioRequests replace AioBlockCompletion as representing
the I/O to a single object in an RBD image.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agorados.py: add binding for rados_trunc
Evan Felix [Sat, 4 Aug 2012 00:56:25 +0000 (17:56 -0700)]
rados.py: add binding for rados_trunc

Fixes: #2909
Signed-off-by: Evan Felix <evan.felix@pnnl.gov>
Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
13 years agodoc: Explicitly state mount.ceph two first arguments are fixed.
Tommi Virtanen [Thu, 2 Aug 2012 23:03:19 +0000 (16:03 -0700)]
doc: Explicitly state mount.ceph two first arguments are fixed.

I've hurt myself too many times with this.

Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agodoc: mount.ceph is also needed for cephx.
Tommi Virtanen [Thu, 2 Aug 2012 23:00:15 +0000 (16:00 -0700)]
doc: mount.ceph is also needed for cephx.

Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agodoc: Fix toctree structure for man obsync(1).
Tommi Virtanen [Thu, 2 Aug 2012 22:56:57 +0000 (15:56 -0700)]
doc: Fix toctree structure for man obsync(1).

Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agorgw_admin.cc: Disallow addition of S3 keys with subuser creation
caleb miles [Fri, 27 Jul 2012 18:26:21 +0000 (11:26 -0700)]
rgw_admin.cc: Disallow addition of S3 keys with subuser creation

Fixes: #1855
It is no longer possible to create a subuser and new S3 key associated
with that user through the radosgw-admin utility. In reference to Bug 1855
http://tracker.newdream.net/issues/1855.

Reviewed-by: Yehuda Sadeh <yehuda@inktank.com>
Signed-off-by: caleb miles <caleb.miles@inktank.com>
13 years agoceph-authtool: Fix usage, it's --print-key not --print.
Tommi Virtanen [Thu, 2 Aug 2012 20:02:04 +0000 (13:02 -0700)]
ceph-authtool: Fix usage, it's --print-key not --print.

Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agoRevert "osd: peering: detect when log source osd goes down"
Samuel Just [Thu, 2 Aug 2012 17:58:31 +0000 (10:58 -0700)]
Revert "osd: peering: detect when log source osd goes down"

This reverts commit 0d3d75ec0d17e2f6bc5d42058f51eb2ff19ffb71.

Accidental double push.

13 years agodoc: cd to repository before running git status.
Tommi Virtanen [Thu, 2 Aug 2012 15:31:26 +0000 (08:31 -0700)]
doc: cd to repository before running git status.

Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agodoc: Say what to do if submodules are out of date.
Tommi Virtanen [Thu, 2 Aug 2012 15:29:50 +0000 (08:29 -0700)]
doc: Say what to do if submodules are out of date.

Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agodoc: Simplify submodules explanation.
Tommi Virtanen [Thu, 2 Aug 2012 15:27:55 +0000 (08:27 -0700)]
doc: Simplify submodules explanation.

``git clone --recursive`` does ``init`` & ``update`` for us. Also
avoids incorrect language; there never were submodules called ``init``
and ``update``.

Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agodoc: Correct Git URL for clone
Wido den Hollander [Thu, 2 Aug 2012 10:48:26 +0000 (12:48 +0200)]
doc: Correct Git URL for clone

Using git@github.com would mean SSHing in, and your average open
source consumer probably won't have a Github account.

Using HTTPS offers the best combination of resisting man-in-the-middle
attacks and passing through corporate firewalls.

Signed-off-by: Wido den Hollander <wido@widodh.nl>
Signed-off-by: Tommi Virtanen <tv@inktank.com>
13 years agoosd: peering: detect when log source osd goes down
Sage Weil [Tue, 31 Jul 2012 21:01:57 +0000 (14:01 -0700)]
osd: peering: detect when log source osd goes down

The Peering state has a generic check based on the prior set osds that
will restart peering if one of them goes down (or one of the interesting
down ones comes up).  The GetLog state, however, can pull the log from
a peer that is not in the prior set if it got a notify from them (e.g., an
osd in an old interval that was down when the prior set was calculated).
If that osd goes down, we don't detect it and will block forward.

Fix by adding a simple check in GetLog for the newest_update_osd going
down.

(BTW GetMissing does not suffer from this problem because
peer_missing_requested is a subset of the prior set, so the Peering check
is sufficient.)

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Samuel Just <sam.just@inktank.com>
13 years agoosd: peering: detect when log source osd goes down
Sage Weil [Tue, 31 Jul 2012 21:01:57 +0000 (14:01 -0700)]
osd: peering: detect when log source osd goes down

The Peering state has a generic check based on the prior set osds that
will restart peering if one of them goes down (or one of the interesting
down ones comes up).  The GetLog state, however, can pull the log from
a peer that is not in the prior set if it got a notify from them (e.g., an
osd in an old interval that was down when the prior set was calculated).
If that osd goes down, we don't detect it and will block forward.

Fix by adding a simple check in GetLog for the newest_update_osd going
down.

(BTW GetMissing does not suffer from this problem because
peer_missing_requested is a subset of the prior set, so the Peering check
is sufficient.)

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Samuel Just <sam.just@inktank.com>