Commit Graph

40237 Commits

Author SHA1 Message Date
Yan, Zheng
c173ceafad mds: disable snapshot rstat temporarily
that code that propagates snapshot rstat is buggy and
difficult to fix. (the main problem this code causes is
that snapshot rstat is always propagated to parent node,
which results large size of CInode:old_inodes).

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-03-13 09:46:44 +08:00
Yan, Zheng
b815cf61c1 mds: pin inode when openning snap parent
make sure SnapRealm not get freed before C_SR_RetryOpenParents
get executed.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-03-13 09:46:43 +08:00
Ilya Dryomov
c365cac767 rbd: regenerate rbd(8) man page
merge-diff and status commands, --image-features and --image-shared
options, other stuff.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit 356a749f63)
2015-03-12 14:37:00 -07:00
Josh Durgin
6e56438b01 Merge pull request #3979 from ceph/wip-rbd-map-options
rbd: default map options, new options, misc

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
2015-03-12 14:36:05 -07:00
David Zafman
416cbff0b4 doc: Fix typo in ceph pg dump_stuck usage in man page
Cause by 9db596974c

Signed-off-by: David Zafman <dzafman@redhat.com>
2015-03-12 14:33:52 -07:00
Josh Durgin
4304951b58 Merge pull request #3981 from ceph/wip-librbd-invalidate-object-map
librbd: invalid snapshot object maps should only affect the snapshot

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
2015-03-12 14:27:37 -07:00
Loic Dachary
1cba9b821f Merge pull request #3978 from tchaikov/hammer-sca-fixes
sca fixes ported from master

Reviewed-by: Loic Dachary <ldachary@redhat.com>
2015-03-12 22:06:15 +01:00
Jason Dillaman
ba77bda554 librbd: invalidating snapshot object maps should set snapshot flag
Instead of setting the HEAD image flag to indicate an invalid
object map, set the flag for the specific snapshot that is
invalid.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2015-03-12 13:20:59 -04:00
Dmytro Iurchenko
1b722bbcd6 rgw: Swift API. Allows setting attributes with COPY object operation.
http://developer.openstack.org/api-ref-objectstorage-v1.html says: "With COPY, you can add additional metadata to the object."

Fixes: #10662
Backport: hammer
Reported-by: Ahmad Faheem <ahmad.faheem@ril.com>
Signed-off-by: Dmytro Iurchenko <diurchenko@mirantis.com>
2015-03-12 19:07:11 +02:00
Jason Dillaman
ba4bb22bc1 test_cls_rbd: verify set_flags updates snapshots
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2015-03-12 13:02:54 -04:00
Jason Dillaman
fa25b84ede cls_rbd_client: add snap_id param to set_flags
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2015-03-12 12:59:17 -04:00
Jason Dillaman
2d86898de1 cls_rbd: set_flags can now update snapshots
It's possible for an object map to be invalid only for
a snapshot, so allow snapshot flags to be updated. This
will also be required when rebuilding the object map and
clearing the invalid flag.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2015-03-12 12:56:14 -04:00
Ilya Dryomov
6d9fbbe6f9 rbd: fix rw option skipping logic
We slip in an extraneous comma if { "rw": "rw" } happens to be the
first map_options pair:

    # ./rbd map -o rw,share foo
    /dev/rbd0

    -> 127.0.0.1:6789 name=admin,key=client.admin,,share rbd foo -

The kernel mount options parser can handle it, but fix it nonetheless.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2015-03-12 14:28:01 +03:00
Ilya Dryomov
2769da40d7 rbd: recognize cephx_require_signatures and tcp_nodelay options
Support for these went into 3.19 and 4.0 kernels respectively.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2015-03-12 14:27:32 +03:00
Ilya Dryomov
84adff4c74 rbd: add rbd default map options config option
Allow supplying rbd map -o / --options through 'rbd default map
options' config option.  Options specified on the command line take
precedence on a per-option basis, i.e. default and cli options are
merged with a preference for the latter.  For example:

    # grep 'rbd default map options' ceph.conf
            rbd default map options = "ro,nocrc"
    # ./rbd map -o noshare,rw foo
    /dev/rbd0

results in a rw mapping with nocrc,noshare.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2015-03-12 14:27:32 +03:00
Ilya Dryomov
cd761bb6d3 rbd: drop redefining map option warning
For example:

    # ./rbd map -o share,noshare foo
    rbd: warning: redefining map option share: 'share' -> 'noshare'
    /dev/rbd0

mount(8) doesn't do this and it's a bit silly to begin with.  Drop this
in preparation for adding rbd default map options config option.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2015-03-12 14:27:32 +03:00
Ilya Dryomov
356a749f63 rbd: regenerate rbd(8) man page
merge-diff and status commands, --image-features and --image-shared
options, other stuff.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2015-03-12 14:27:32 +03:00
Danny Al-Gaaf
b6d1effee6 Merge pull request #3924 from ktdreyer/wip-doc-rm-old-ceph-deploy-reference
rm old ceph-deploy reference

Reviewed-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-12 11:11:36 +01:00
Danny Al-Gaaf
c1892a0195 rgw_main.cc: fix null-deref in case get_storage() fails
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
(cherry picked from commit 921c08fce5)
2015-03-12 17:38:10 +08:00
Danny Al-Gaaf
f5b01515d0 rgw/rgw_op.cc: fix potential null-deref in strcmp()
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
(cherry picked from commit de7bcfd8d0)
2015-03-12 17:37:59 +08:00
Matt Benjamin
595e87f20b Fix XioLoopbackConnection Lifecycle.
Since XioLoopbackConnection is a RefCountedObject, it can't be
an expanded member of XioMessenger.

Fixes cleanup/shutdown errors.

Signed-off-by: Matt Benjamin <matt@cohortfs.com>
(cherry picked from commit f5735b28d1)
2015-03-12 17:20:52 +08:00
Kefu Chai
c0d8089556 Merge pull request #3965 from linuxbox2/xio-fixes
xio: Xio fixes

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-03-12 17:19:39 +08:00
Zhiqiang Wang
d8bf378314 osd/ReplicatePG: correctly checking if an object is in hit set
For the write case when the oid.snap is CEPH_NOSNAP, the obc is created
in find_object_context, and missing_oid is setting to a NULL object.
Checking if the missing_oid is in the hit set is not the correct way
since it's NULL. Instead, we should check the obc->obs.oi.soid.

Signed-off-by: Zhiqiang Wang <zhiqiang.wang@intel.com>
2015-03-12 16:15:45 +08:00
Kefu Chai
e1eebb32de osd: refactor RepScrubWQ::_process()
use Mutex::Locker instead of releasing the lock manually.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2015-03-11 21:13:12 -07:00
Kefu Chai
052debd4f8 osd: fix a msg leak when OSD is stopping
Signed-off-by: Kefu Chai <kchai@redhat.com>
2015-03-11 21:13:12 -07:00
Matt Benjamin
f5735b28d1 Fix XioLoopbackConnection Lifecycle.
Since XioLoopbackConnection is a RefCountedObject, it can't be
an expanded member of XioMessenger.

Fixes cleanup/shutdown errors.

Signed-off-by: Matt Benjamin <matt@cohortfs.com>
2015-03-11 14:14:28 -04:00
Matt Benjamin
76d4d4c6b7 Fix CMake build w/o RADOSGW.
Just fixes linkage of dencoder in test.  Fix the false assumption
that cls is only used if WITH_RADOSGW.

Signed-off-by: Matt Benjamin <matt@cohortfs.com>
2015-03-11 14:14:20 -04:00
Jason Dillaman
64d9e05d42 Merge pull request #3625 from majianpeng/objectcacher
Bugs fix about ObjectCacher

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2015-03-11 11:53:43 -04:00
Kefu Chai
fdf9e1cd6e Merge pull request #3881 from ceph/wip-da-SCA-20150304
SCA fixes

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-03-11 23:52:16 +08:00
Loic Dachary
f5acf6bb6a ceph-disk: more robust parted output parser
In some cases, depending on the implementation or the operating system,

   parted --machine -- /dev/sdh print

may contain empty lines. The current parsing code is fragile and highly
depends on output details. Replace it with code that basically does the
same sanity checks (output not empty, existence of units, existence of
the dev entry) but handles the entire output instead of checking line by
line.

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

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-11 14:02:54 +01:00
Danny Al-Gaaf
faa7937f2f tools/rados/rados.cc: init some vars in constructor
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 14:00:08 +01:00
Danny Al-Gaaf
db175fb938 rgw_rados: don't assign value to parameter
Fix for cppcheck issue:
Assignment of function parameter has no effect outside the function.

Remove assignment to need_to_wait before exit.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 14:00:08 +01:00
Danny Al-Gaaf
778e0ef10d src/msg/xio/*: reduce scope of some vars
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 14:00:08 +01:00
Danny Al-Gaaf
6f79e4a616 rgw_quota.cc: init variables in constructor
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
16c92378d1 TestErasureCodeShec_thread.cc: reduce scope of var
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
ff760bee26 ObjectStoreTransactionBenchmark.cc: reduce scope of var
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
828fc737f1 objectstore/store_test.cc: reduce scope of variable
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
649f0f3e7e rgw_rados.cc: reduce scope of variable
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
0a5e6af484 rgw_rados.cc: remove unused string vars
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
e11f9d2c71 librbd/internal.cc: reduce scope of some variables
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
0d78f4402f librbd/ObjectMap.cc: reduce scope of variable, prevent redef
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
54aa23a699 ErasureCodeShec::minimum_to_decode: reduce scope of variables
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:42 +01:00
Danny Al-Gaaf
de7bcfd8d0 rgw/rgw_op.cc: fix potential null-deref in strcmp()
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00
Danny Al-Gaaf
921c08fce5 rgw_main.cc: fix null-deref in case get_storage() fails
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00
Danny Al-Gaaf
ab4e37f314 mds/MDS.cc: add missing asserts to check return values
Change existing asserts in set_up_admin_socket() to
check (VAR == 0).

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00
Danny Al-Gaaf
a3d0c80bda TestErasureCodeShec_all.cc: fix sprintf specifier
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00
Danny Al-Gaaf
51bec737d9 rgw: use static_cast instead of c-style cast
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00
Danny Al-Gaaf
48d27ba1ed osd/ReplicatedPG.cc: use static_cast instead of c-style cast
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00
Danny Al-Gaaf
5393f32bbf TestErasureCodeShec_thread.cc: use static_cast instead of c-style
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00
Danny Al-Gaaf
bfe58833d4 itest/msgr/test_msgr.cc: prefer ++operator for non-primitive iter
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-11 13:58:41 +01:00