Commit Graph

40078 Commits

Author SHA1 Message Date
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
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
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
Loic Dachary
af3a37fb9d tests: ceph-disk.sh /dev/disk/by-partuuid and /dev/loop fixes
On CentOS 6.X and RHEL 6.X:

* /dev/disk/by-partuuid is not updated, support files must be installed
  to create them when udev notices a partition modification.

* /dev/loop is not configured to handle partition tables, the default
  2.6.32 kernel must be configured with loop.max_part=16

Sanity checks are added to verify the above, attempt to fix it and fail
if it cannot be fixed or if a machine reboot is necessary.

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-11 13:55:10 +01:00
Yan, Zheng
07f5d7d316 Merge pull request #3666 from xroche/master
Added ceph_flock() to libcephfs.
2015-03-11 20:30:26 +08:00
Kefu Chai
ea7a127250 Merge pull request #3920 from rajukv/xio-bugfix
XIO: Handle requeue case of XIO messages

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-03-11 14:37:57 +08:00
Raju Kurunkad
dbb8c93d41 XIO: Handle requeue case of XIO messages
If we are not able to send the XIO message using xio_send_msg(),
remove the XIO message from the send Q, before queuing it to the resend
Q. Otherwise, boost will generate a assert.

Signed-off-by: Raju Kurunkad <raju.kurunkad@sandisk.com>
2015-03-11 12:00:36 +05:30
xinxin shu
af0986b4e0 cleanup in_prefix function
Signed-off-by: xinxin shu <xinxin.shu@intel.com>
2015-03-11 09:43:04 +08:00
Sage Weil
5d5b510810 doc/release-notes: v0.80.8 and .9 changelogs
Signed-off-by: Sage Weil <sage@redhat.com>
2015-03-10 12:32:47 -07:00
Loic Dachary
af890731da tests: ceph-disk paritition creation and partition table in use
The kernel partition table notification (via partprobe, partx, etc.) may
behave differently when a partition is in use. Add a test case that
checks a new journal partition shows as expected, even if another
journal partition is in use.

http://tracker.ceph.com/issues/10987 Refs: #10987

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 17:50:29 +01:00
Loic Dachary
da22e22e7f tests: ceph-disk.sh test for second journal partition
Create an OSD with data on a disk, journal on another
This will add a new partition to $journal, the previous
one will remain.

Add 200MB to the file supporting the pseudo disk exposed via the loop
device: as we create more OSDs, more 100MB partitions will be created
for journals.

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 17:50:29 +01:00
Loic Dachary
1e462a4520 tests: ceph-disk.sh cosmetic changes and reduced verbosity
Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 17:50:29 +01:00
Loic Dachary
064a05e138 tests: do not use --journal-dio=true
Direct IO for the journal may cause subtle errors while running the
tests withing a container. Disable Direct IO for all ceph-disk.sh tests.

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 17:50:29 +01:00
Loic Dachary
dda58cd4d8 tests: ceph-disk.sh may use uuidgen without PATH
Store the absolute path in a variable to find uuidgen even if PATH is
empty.

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 17:50:29 +01:00
Loic Dachary
fbb6df525c tests: ceph-disk.sh can be confused if there are two OSDs
Replace the fragile extaction of the whoami file with an explicit uuid
set for a given OSD. It can conveniently be translated back into an osd
id with ceph osd create uuid if needed.

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 17:50:29 +01:00
Loic Dachary
8d52dc185e tests: teardown on ceph-disk error
The activate_dev error must kill all process with teardown before
attempting to umount the devices when an error happens. Otherwise the
device fails to be unmounted and the loop devices are never freed.

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 17:50:29 +01:00
Ken Dreyer
51f5feccac Merge pull request #3871 from dachary/wip-install-deps
tests: install-deps.sh install EPEL and RHEL Optional

Reviewed-by: Ken Dreyer <kdreyer@redhat.com>
2015-03-10 10:42:16 -06:00
Ken Dreyer
e6dcaa8688 rm old ceph-deploy reference
There's no need to refer to this old version of ceph-deploy. v1.1.3 is
circa June 2013, and since that time, we have shipped much newer version
of ceph-deploy (1.5.22 at the time of this writing). We should simply
state the behavior of modern ceph-deploys here.

Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
2015-03-10 10:28:02 -06:00
Kefu Chai
d2057bd6d9 Merge pull request #3887 from stiopaa1/feature10891
mon: add "osd pool get $pool all" command

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-03-10 22:16:29 +08:00
Sage Weil
faa1f2741c Merge remote-tracking branch 'gh/hammer'
Conflicts:
	src/gmock
2015-03-10 06:24:59 -07:00
Yan, Zheng
75bf4bec28 mds: fix assertion caused by system clock backwards
Fixes: #11053
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-03-10 20:05:16 +08:00
Loic Dachary
830a4a1b6b tests: install-deps.sh install EPEL and RHEL Optional
On CentOS and RHEL, some dependencies come from EPEL.

Always enable RHEL Optional repository for RHEL as packages such as
packages such as libatomic_ops-devel or libedit-devel are only found
there in RHEL 6.5.

http://tracker.ceph.com/issues/11061 Refs: #11061

Signed-off-by: Loic Dachary <ldachary@redhat.com>
2015-03-10 11:39:52 +01:00
Danny Al-Gaaf
b17c3ebbdc Merge pull request #3901 from dachary/wip-10922-ceph-deploy-documentation
doc: preparing a device implies activate

Reviewed-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2015-03-10 10:53:56 +01:00