The zlib1g-dev is installed indirectly for Ubuntu 12.04 or Ubuntu 14.04
but it is only suggested in Debian/jessie. Adding it to the
Build-depends is redundant and harmless for Ubuntu and resolves the
missing dependency for Debian.
http://tracker.ceph.com/issues/11068Fixes: #11068
Signed-off-by: Loic Dachary <ldachary@redhat.com>
The str_p("straw2") won't parse straw2, it seems because the digit is throwing
it off. Use the existing name rule instead which is more robust. Note that
not constraining the alg value here is better anyway because instead of a
'cannot parse' error that is hard to debug we instead get a 'unknown alg foo'
error when doing the semantic pass.
Fixes: #11015
Signed-off-by: Sage Weil <sage@redhat.com>
Go into non interactive mode when installing the compilation
dependencies, in case a package has a different default mode.
Signed-off-by: Loic Dachary <ldachary@redhat.com>
Alternatives were introduced lately and the | needs to be stripped from
the list of packages to install otherwise apt-get will try to install
all packages.
Signed-off-by: Yann Dupont <yann@objoo.org>
In Debian, the ceph-test package can be installed with any version of
ceph-common.
Prior to this commit, in RHEL, we're much more strict about which
version of the dependencies we require. We depend directly on
librados2/librbd1/libcephfs1 instead of ceph-common, and we also require
the specific versions of these libraries to match the version of
ceph-test.
For testing Ceph, it is nice to have the ability to upgrade the
librados2/librbd1/libcephfs1 libraries on a host without having to also
upgrade the ceph-test package as well.
Remove the version number requirements, and change the dependencies from
librados2/librbd1/libcephfs1 to simply "ceph-common". That will make
/etc/ceph/ and /var/log/ceph present for the tests.
http://tracker.ceph.com/issues/10989 Refs: #10989
Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
(cherry picked from commit 924f85f157)
! doesn't do what we want in bash -e. Use a more explicit helper
instead, and specify expected error codes.
Signed-off-by: Josh Durgin <jdurgin@redhat.com>
Calling this unconditionally in close_image() simplifies error
handling when open_image() fails due to an error like EPERM from
registering a watch.
Signed-off-by: Josh Durgin <jdurgin@redhat.com>
If the object map is enabled, it's possible for a read request to
instantly complete due to the skipped librados operations. Now
AioRequest will block the completion of read_from_parent requests
to prevent the possibility of the parent image being closed while
the read_from_parent method invocation is in-progress.
Fixes: #10968
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
Blocked AioCompletions will not fire their callback until unblocked.
This is an expansion / replacement of the previous 'building' flag
used to block completions while additional requests were added to the
completion.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
If an object map update is not required when modifying an image,
properly free the memory allocated for the callback Context.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
AioRead and CopyupRequest were not properly handling possible
error codes from aio_read. They now correctly free the completion
and invoke the callback context.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
The crushtool is aborted if it takes more than mon lease seconds. Since
the monitor blocks while running it, this is mandatory otherwise the
monitor will be considered down and new elections triggered.
http://tracker.ceph.com/issues/10947Fixes: #10947
Signed-off-by: Loic Dachary <ldachary@redhat.com>
Make crushtool a configuration value that defaults to crushtool and
allow it to be injected. It helps with testing: the command can be
replaced with another that misbehaves in various ways.
Signed-off-by: Loic Dachary <loic@dachary.org>
rbd CLI now includes rbd image flags and no longer defaults
to enabling the new exclusive locking feature.
Fixes: #10962
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
rbd did not previously support specifying striping params
for cloned and imported images. Extend the behavior to
these other CLI commands.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
All feature flags were being displayed when using JSON/XML
formatted output. Now use the same formatting routing for
plain/JSON/XML output for features and flags.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
If the exclusive lock feature is enabled, all locks need
to be removed prior removing the image.
Fixes: #10990
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
There was a potential race condition between a delayed AIO
operation waiting on acquiring a lock and a snap_create
flushing all pending IO. Since snap_create owned md_lock, the
delayed AIO would not be allowed to complete -- deadlocking the
flush.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
In the case where concurrent IO is occurring when a trim resize
operation is initiated, hold the snap_lock between clipping the
IO operation and registering the pending op. That allows the
resize state machine to properly flush all operations issued
before the clip region was updated.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
The --output-csv option to crushtool will create files in the current
directory of the monitor. The only reason for using it is because
crushtool requires at least one option for display. Relax this
constraint in crushtool and remove the option from the call made by the
monitor to validate a new crushmap.
Signed-off-by: Loic Dachary <ldachary@redhat.com>