Commit Graph

44025 Commits

Author SHA1 Message Date
Kefu Chai
7a09ea09e2 Merge pull request #5655 from duduribeiro/patch-1
doc: update ruby doc with the aws-sdk gem usage

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-08-31 22:33:15 +08:00
Kadu Ribeiro
d05e531dc0 doc: update ruby doc with the aws-sdk gem usage
Since I'm using ceph with the `aws-sdk` gem (https://github.com/aws/aws-sdk-ruby) instead `aws-s3` (https://github.com/marcel/aws-s3) because the aws-s3 have a trouble with the new active support (https://github.com/marcel/aws-s3/issues/98) (and the downgrade active-support wasn't a option), I proposed change the doc to receive the usage instructions with the aws-sdk gem.

I used ceph with aws-sdk gem with this commands.

Thanks so much

Signed-off-by: Carlos E Ribeiro <mail@carlosribeiro.me>
2015-08-31 11:28:05 -03:00
Sage Weil
f030af3cd3 Merge pull request #4869 from joaquimrocha/cls_numops
CLS numops

Reviewed-by: Noah Watkins <noahwatkins@gmail.com>
2015-08-31 10:16:10 -04:00
Gregory Farnum
728e2229a8 Merge pull request #5724 from ceph/wip-i386
perf_serialize: fix i386 build

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
2015-08-31 15:12:19 +01:00
Sage Weil
63bd5a729e Merge pull request #5713 from yuyuyu101/wip-12798
Fix keyvaluestore fails ceph_test_objectstore

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-08-31 09:24:02 -04:00
Kefu Chai
6dc9ed5814 Merge pull request #5603 from wonzhq/doc-read-recency
doc: add the description for min_read_recency_for_promote

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-08-31 18:12:43 +08:00
Kefu Chai
3b089b0a97 Merge pull request #5460 from ceph/port/new
OSX and BSD derivatives port

Reviewed-by: Kefu Chai <kchai@redhat.com>
2015-08-31 17:43:52 +08:00
Joao Eduardo Luis
35c80951ca Merge pull request #4896 from xinxinsh/wip-monitor-dump-transaction
MonitorDBStore : make monitor transaction more readable

Reviewed-by: Joao Eduardo Luis <joao@suse.de>
Reviewed-by: Sage Weil <sage@redhat.com>
2015-08-31 10:17:58 +01:00
Kefu Chai
109e5b127b make: do not compile XFS.cc if --without-libxfs
Signed-off-by: Kefu Chai <kchai@redhat.com>
2015-08-31 16:00:29 +08:00
Kefu Chai
8ef07420b1 os/fs: include <sys/mount.h> on osx
Signed-off-by: Kefu Chai <kchai@redhat.com>
2015-08-31 16:00:29 +08:00
Yan, Zheng
491d8939bb test_c_headers: don't use -Werror option for clang
When using clang to compile ceph, there are lots of warnings:
clang: warning: argument unused during compilation: '-Wp,-D_FORTIFY_SOURCE=2'

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:29 +08:00
Yan, Zheng
d36e514935 ceph: use 'sed -ie' to edit file in-place
On OSX, 'sed -i script' does not work, because it considers 'script'
as suffix of backup file. 'sed -ie script' works on both OSX and Linux.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:29 +08:00
Yan, Zheng
68db9f6fda client: fix compile error on OSX
On OSX, type of the 3rd parameters of getgrouplist is 'int *'

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:28 +08:00
Yan, Zheng
0b94867a93 common/blkdev: fix complie error on OSX/FreeBSD
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:28 +08:00
Yan, Zheng
8d527d4167 common/admin_socket: fix compile error on OSX
Invalid operands to binary expression ('__bind<int &, sockaddr *,
unsigned long>' and 'int')

Without :: clang confuses C bind function and std::bind().

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:28 +08:00
Yan, Zheng
2cd7d4fca1 tests: only use posix_fadvise on linux
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:28 +08:00
Yan, Zheng
c092b4fcc4 os/chain_xattr: set CHAIN_XATTR_MAX_NAME_LEN according to max length of xattr name
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:27 +08:00
Yan, Zheng
b06838a09d test/admin_socket: check error message according to OS
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:27 +08:00
Yan, Zheng
f6fa4a28d1 compat: move definitions in porting.h into include/compat.h
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:27 +08:00
Yan, Zheng
6a03fa5bbe TestLFNIndex.cc: don't use "cp --preserve=xattr"
--preserve option is not supported by OSX's cp. use 'cp -a' instead

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:27 +08:00
Yan, Zheng
126ee7dcad tests: replace std::tr1::shared_ptr with ceph::shared_ptr
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:27 +08:00
Yan, Zheng
e71269caf6 tests: disable unittest_blkdev on OSX
the test uses sysfs, which does not exist on OSX

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:26 +08:00
Yan, Zheng
9e37a37908 test/librados: replace sem_init() with sem_open()
sem_init() always fails on OSX (it's no longer supported).

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:26 +08:00
Yan, Zheng
b82ed61220 buffer: make buffer::exception classes undefined in dynamic objects
On OSX, if the an exception class is declared and defined in header file,
but it ends up being compiled as private symbols in different binaries.
The exception handling code will take the two compiled exception classes
as different types! In our case, the one in libcls_xxx.so and the one is
ceph-osd are considered as different classes, thus the try-catch statement
fails to work.

The fix is force buffer::exception classes undefined in libcls_xxx.so. The
ibcls_xxx.so are compiled with '-undefined dynamic_lookup' option. when
it is loaded into ceph-osd, buffer::exception classes in ceph-osd will be
used.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:26 +08:00
Yan, Zheng
c57ef8c3ed test/librados: replace errno -125 with -ECANCELED
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:26 +08:00
Yan, Zheng
4132805d70 client: convert XATTR_{CREATE,REPLACE} to CEPH_XATTR_{CREATE,REPLACE}
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:25 +08:00
Yan, Zheng
5db6915d80 xattr: convert ENOATTR to ENODATA on DARWIN
On Darwin, getxattr/removexattr return ENOATTR when extended
attribute does not exist. But lots of ceph codes expect ENODATA
is returned in that case. On Darwin, ENOATTR and ENODATA have
different values, so we convert ENOATTR to ENODATA.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:25 +08:00
Yan, Zheng
731f6aaa68 test_libcephfs: disable flock test on OSX
there is no sem_timedwait on OSX. For inter-threads communication,
we can replace sem_t with pthread_cond_t. But for inter-processes
communication, it's extremely hard to figure out how to do a timed
wait. So disable the test case on OSX

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:25 +08:00
Yan, Zheng
ad056c12c0 libradosstriper/striping.cc: include "include/types.h"
include definitions of __le{32,64)

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:25 +08:00
Yan, Zheng
078691977d test_c_headers: don't use -Wold-style-declaration option for clang
clang does not support this option

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:25 +08:00
Yan, Zheng
bcbddab500 libcephfs: define loff_t as off_t on OSX
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:24 +08:00
Yan, Zheng
b800303e19 tools: link ceph-client-debug to LIBCLIENT
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:24 +08:00
Yan, Zheng
bb1fa7f399 init-ceph: check if /lib/lsb/init-functions exists
On OSX/FreeBSD, /lib/lsb/init-functions does not exist

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:24 +08:00
Yan, Zheng
4594adbc8f init-ceph: don't use procfs to check if daemon is running
use ps(1) instead, which is portable

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:24 +08:00
Yan, Zheng
69e2060f17 init-ceph: replace 'echo -n' with printf
'echo -n' is no portable. On OSX, output of 'echo -n' can be '-n'

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:24 +08:00
Yan, Zheng
4536cb52fe vstart.sh: use portable way to get ip address
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:23 +08:00
Yan, Zheng
e92aaea1bd vstart.sh: append ceph library path to {LD,DYLD}_LIBRARY_PATH
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:23 +08:00
Yan, Zheng
05fbfd1102 On Darwin: subfix of dynamic library is dylib
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:23 +08:00
Kefu Chai
a55891650c porting.h: add TODO comment
Signed-off-by: Kefu Chai <kchai@redhat.com>
2015-08-31 16:00:23 +08:00
Kefu Chai
4ec4177f56 Makefile: add porting.h to dist tarball
Signed-off-by: Kefu Chai <kchai@redhat.com>
2015-08-31 16:00:22 +08:00
Yan, Zheng
760f5874ca Don't use '--exclude-libs' linker option on DARWIN
Only GNU linker supports this option

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:22 +08:00
Yan, Zheng
d5c43d9c75 client: don't try trimming kernel dcache on DARWIN/FreeBSD
still don't know if the methods used on linux also works on
DARWIN/FreeBSD

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:22 +08:00
Yan, Zheng
aa71c20734 client: don't include unsupported mount options on DARWIN/FreeBSD
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:22 +08:00
Yan, Zheng
f064e90ae5 Link ceph-fuse to fuse on DARWIN
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:22 +08:00
Yan, Zheng
44458db5a7 msg: fix encoding/decoding sockaddr_storage on DARWIN/FreeBSD
sockaddr_storage on DARWIN/FreeBSD is different from sockaddr_storage
on Linux. sockaddr_storage on DARWIN/FreeBSD includes a ss_len field.
Besides, Its ss_len and ss_family fields are 'unsigned char'.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2015-08-31 16:00:21 +08:00
Dennis Schafroth
11a936e3a2 librbd: Need to include errno.h on DARWIN.
The file is not really required

Signed-off-by: Dennis Schafroth <dennis@schafroth.com>
2015-08-31 15:35:58 +08:00
Dennis Schafroth
cd93656e15 porting.h: add porting.h for porting/compatibility on DARWIN
Collection of porting/compatibility defines to compile on DARWIN

Signed-off-by: Dennis Schafroth <dennis@schafroth.com>
2015-08-31 15:35:58 +08:00
Dennis Schafroth
fb1b6bc3da tools/ceph_objectstore_tool: Missing O_LARGEFILE on DARWIN
Signed-off-by: Dennis Schafroth <dennis@schafroth.com>
2015-08-31 15:35:57 +08:00
Dennis Schafroth
0fbacb306b test: Fix error with clang on DARWIN (LLVM 3.6.0svn)
Signed-off-by: Dennis Schafroth <dennis@schafroth.com>
2015-08-31 15:35:57 +08:00
Dennis Schafroth
126c327842 rbd-replay: Different location of endian.h on DARWIN
Signed-off-by: Dennis Schafroth <dennis@schafroth.com>
2015-08-31 15:35:57 +08:00