]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
9 years agoCMake: fix rbd build
John Spray [Mon, 3 Aug 2015 15:11:22 +0000 (16:11 +0100)]
CMake: fix rbd build

Don't link with 'global' from rbd (to match
autotools update fa78739).  Fixes "g_ceph_context
defined twice" error.

Signed-off-by: John Spray <john.spray@redhat.com>
9 years agoCMake: libblkid not only needed with rbd
John Spray [Mon, 3 Aug 2015 11:59:00 +0000 (12:59 +0100)]
CMake: libblkid not only needed with rbd

It's linked in libcommon.

Signed-off-by: John Spray <john.spray@redhat.com>
9 years agoCMake: smalliobenchrbd should dep on rbd
John Spray [Mon, 3 Aug 2015 11:52:58 +0000 (12:52 +0100)]
CMake: smalliobenchrbd should dep on rbd

Signed-off-by: John Spray <john.spray@redhat.com>
9 years agoCMake: set WITH_CEPHFS by default
John Spray [Mon, 3 Aug 2015 11:48:32 +0000 (12:48 +0100)]
CMake: set WITH_CEPHFS by default

Option was referenced in CMakeLists but
not actually set.

Signed-off-by: John Spray <john.spray@redhat.com>
9 years agoCMake: fix cephfs cls build
John Spray [Mon, 3 Aug 2015 12:14:16 +0000 (13:14 +0100)]
CMake: fix cephfs cls build

Signed-off-by: John Spray <john.spray@redhat.com>
9 years agoCMake: fix cephfs test targets
John Spray [Mon, 3 Aug 2015 11:51:42 +0000 (12:51 +0100)]
CMake: fix cephfs test targets

These had bad lib names.

Signed-off-by: John Spray <john.spray@redhat.com>
9 years agoCMake: add cephfs tools
John Spray [Fri, 31 Jul 2015 12:26:12 +0000 (13:26 +0100)]
CMake: add cephfs tools

cephfs-table-tool, cephfs-data-scan, cephfs-journal-tool

Signed-off-by: John Spray <john.spray@redhat.com>
9 years agoMerge pull request #5422 from ceph/wip-fix-filestore-getattr
Kefu Chai [Mon, 3 Aug 2015 14:37:35 +0000 (22:37 +0800)]
Merge pull request #5422 from ceph/wip-fix-filestore-getattr

tests: fix the ObjectStore/StoreTest.SimpleCloneTest in "ceph_test_objectstore"

Reviewed-by: Loic Dachary <ldachary@redhat.com>
9 years agoMerge pull request #5375 from ceph/wip-config-root-ino
Yan, Zheng [Mon, 3 Aug 2015 13:28:47 +0000 (21:28 +0800)]
Merge pull request #5375 from ceph/wip-config-root-ino

Make UID of new root inos configurable

10 years agoMerge pull request #5445 from ceph/wip-12432
Orit Wasserman [Fri, 31 Jul 2015 19:39:04 +0000 (21:39 +0200)]
Merge pull request #5445 from ceph/wip-12432

Wip 12432

10 years agorgw: set http status in civetweb 5445/head
Yehuda Sadeh [Wed, 22 Jul 2015 17:01:00 +0000 (10:01 -0700)]
rgw: set http status in civetweb

Need to set the http status in civetweb so that we report it correctly.
Fixes: #12432
Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agocivetweb: update submodule to support setting of http status
Yehuda Sadeh [Fri, 31 Jul 2015 18:03:29 +0000 (11:03 -0700)]
civetweb: update submodule to support setting of http status

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoMerge pull request #5258 from zhouyuan/rgw_skip_first_chunk
Yehuda Sadeh [Fri, 31 Jul 2015 17:25:46 +0000 (13:25 -0400)]
Merge pull request #5258 from zhouyuan/rgw_skip_first_chunk

rgw: skip prefetch first chunk if range get falls to shadow objects

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agodoc: krbd supports clones since 3.10
Ilya Dryomov [Fri, 31 Jul 2015 16:50:58 +0000 (19:50 +0300)]
doc: krbd supports clones since 3.10

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agoMerge pull request #5438 from ceph/fix-doc-build
Loic Dachary [Fri, 31 Jul 2015 10:29:04 +0000 (12:29 +0200)]
Merge pull request #5438 from ceph/fix-doc-build

doc: fix the build of placement-groups.rst

Reviewed-by: Kefu Chai <kchai@redhat.com>
10 years agoos/FileStore: getattr() should return 0 if success 5422/head
Kefu Chai [Thu, 30 Jul 2015 14:19:41 +0000 (22:19 +0800)]
os/FileStore: getattr() should return 0 if success

* fix the test of ObjectStore/StoreTest.SimpleCloneTest, the expected
  return value of getattr() should be 0. otherwise it otherwise it fails
  on objectstore backends of "memstore" and "keyvaluestore".
* change FileStore::getattr() to return 0 on success
* tighten related tests in ceph_test_objectstore, to test the return value
  of getattr() using ASSERT_EQ(r, 0) instead of ASSERT_GE(r, 0)

Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agoKeyValueStore: Fix incorrect rm_keys behaviors
Haomai Wang [Fri, 31 Jul 2015 08:05:41 +0000 (16:05 +0800)]
KeyValueStore: Fix incorrect rm_keys behaviors

GenericObjectMap will copyup parents keys when rm keys, but if
caller(KeyValueStore) already buffer "set keys", it shouldn't
copyup reset keys.

Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
10 years agodoc: fix the build of placement-groups.rst 5438/head
Kefu Chai [Fri, 31 Jul 2015 09:07:29 +0000 (17:07 +0800)]
doc: fix the build of placement-groups.rst

add a reference target of "mapping pgs to osds"

Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agoMerge pull request #5432 from ceph/wip-fix-rbd-build
Kefu Chai [Fri, 31 Jul 2015 08:47:55 +0000 (16:47 +0800)]
Merge pull request #5432 from ceph/wip-fix-rbd-build

make: fix the build of "rbd"

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #5434 from tobegit3hub/remove_execute_mode
Loic Dachary [Fri, 31 Jul 2015 07:55:01 +0000 (09:55 +0200)]
Merge pull request #5434 from tobegit3hub/remove_execute_mode

Remove execute mode of source files

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoRemove execute mode of source files 5434/head
tobe [Fri, 31 Jul 2015 07:47:43 +0000 (15:47 +0800)]
Remove execute mode of source files

10 years agoMerge pull request #5398 from mingyuez/master
Haomai Wang [Fri, 31 Jul 2015 07:41:32 +0000 (15:41 +0800)]
Merge pull request #5398 from mingyuez/master

rbd:If the image has any protected snaps,'rbd snap purge image' will return failure without removing any snaps.

Reviewed-by: Josh During <jdurgin@redhat.com>
Reviewed-by: Haomai Wang <haomaiwang@gmail.com>
10 years agomake: fix the build of "rbd" 5432/head
Kefu Chai [Fri, 31 Jul 2015 06:41:51 +0000 (14:41 +0800)]
make: fix the build of "rbd"

`CEPH_GLOBAL` was removed in fa78739, but the linked libraries does not
offer all needed symbols for "rbd". so add them back.

Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agorbd:'rbd purge image' will return failure without removing any snaps if the image... 5398/head
mingyuez [Fri, 31 Jul 2015 04:06:05 +0000 (12:06 +0800)]
rbd:'rbd purge image' will return failure without removing any snaps if the image has a protected snap

Signed-off-by: mingyuez <zhao.mingyue@h3c.com>
10 years agoMerge pull request #5395 from tchaikov/wip-12512
Kefu Chai [Fri, 31 Jul 2015 02:24:30 +0000 (10:24 +0800)]
Merge pull request #5395 from tchaikov/wip-12512

common/syncfs: fall back to sync(2) if syncfs(2) not available

Reviewed-by: Haomai Wang <haomaiwang@gmail.com>
Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #5402 from ceph/wip-claim-sparse-read-buffer
Kefu Chai [Fri, 31 Jul 2015 02:14:02 +0000 (10:14 +0800)]
Merge pull request #5402 from ceph/wip-claim-sparse-read-buffer

osd/ReplicatedPG: claim the read buffer instead of copying it

Reviewed-by: David Zafman <dzafman@redhat.com>
10 years agoMerge pull request #5428 from ceph/wip-kill-rest-bench
Sage Weil [Fri, 31 Jul 2015 02:13:40 +0000 (22:13 -0400)]
Merge pull request #5428 from ceph/wip-kill-rest-bench

kill rest-bench

Reviewed-by: Ken Dreyer <kdreyer@redhat.com>
10 years agorgw: skip prefetch first chunk if range get falls to shadow objects 5258/head
Yuan Zhou [Thu, 16 Jul 2015 08:18:09 +0000 (16:18 +0800)]
rgw: skip prefetch first chunk if range get falls to shadow objects

Currently the head object will be prefetched in each GET:
 a) This is unnecessary if the Range GET falls to shadow objects.
 b) The GET request would be quite slow if we have a big head object
This patch adds some check on the Range. If it's not in the head
object(>=rgw_max_chunk_size) then skip the prefetch.

Fixes: #12539
Signed-off-by: Yuan Zhou <yuan.zhou@intel.com>
10 years agoMerge remote-tracking branch 'origin/next'
Josh Durgin [Thu, 30 Jul 2015 23:35:01 +0000 (16:35 -0700)]
Merge remote-tracking branch 'origin/next'

10 years agoMerge pull request #5425 from ceph/wip-12479-next
Josh Durgin [Thu, 30 Jul 2015 23:26:51 +0000 (16:26 -0700)]
Merge pull request #5425 from ceph/wip-12479-next

librbd: test crash during client upgrade suite

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
10 years agoMerge pull request #5423 from oddomatik/patch-1
Sage Weil [Thu, 30 Jul 2015 21:32:52 +0000 (17:32 -0400)]
Merge pull request #5423 from oddomatik/patch-1

doc: No CRUSH involvement in deciding PG target

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #5426 from ceph/wip-12383-next
Josh Durgin [Thu, 30 Jul 2015 21:08:32 +0000 (14:08 -0700)]
Merge pull request #5426 from ceph/wip-12383-next

rbd: remove dependency on non-ABI controlled CephContext

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
10 years agoMerge pull request #5399 from tchaikov/wip-12458
Josh Durgin [Thu, 30 Jul 2015 21:00:15 +0000 (14:00 -0700)]
Merge pull request #5399 from tchaikov/wip-12458

rbd: add "--keyring" option to help message

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
10 years agoMerge pull request #5414 from cxwshawn/master
Yehuda Sadeh [Thu, 30 Jul 2015 17:52:06 +0000 (13:52 -0400)]
Merge pull request #5414 from cxwshawn/master

doc: add bucket object version description.

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoremove libs3 submodule 5428/head
Sage Weil [Thu, 30 Jul 2015 17:24:00 +0000 (13:24 -0400)]
remove libs3 submodule

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoremove rest-bench
Sage Weil [Thu, 30 Jul 2015 17:21:36 +0000 (13:21 -0400)]
remove rest-bench

This is a weak tool; users should look to cosbench or others instead.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #5419 from ceph/wip-kfsx-invalidate
Josh Durgin [Thu, 30 Jul 2015 16:25:30 +0000 (09:25 -0700)]
Merge pull request #5419 from ceph/wip-kfsx-invalidate

test_librbd_fsx: invalidate before discard in krbd mode

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
10 years agoNo CRUSH involvement in deciding PG target 5423/head
oddomatik [Thu, 30 Jul 2015 14:33:09 +0000 (22:33 +0800)]
No CRUSH involvement in deciding PG target

Quoting from elsewhere "[we calculate] a placement group using the object name, a hash code, the number of PGs in the pool and the pool name"

10 years agolockdep: allow lockdep to be dynamically enabled/disabled 5425/head
Jason Dillaman [Wed, 29 Jul 2015 16:46:24 +0000 (12:46 -0400)]
lockdep: allow lockdep to be dynamically enabled/disabled

librbd test cases attempt to enable lockdep coverage via the librados
API.  Use a configuration observer to register/unregister lockdep
support.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
10 years agotests: librbd API test cannot use private md_config_t struct
Jason Dillaman [Tue, 28 Jul 2015 18:23:14 +0000 (14:23 -0400)]
tests: librbd API test cannot use private md_config_t struct

Remove all depencencies on md_config_t and instead use librados API
methods to get/set configuration values.

Fixes: #12479
Backport: hammer
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
10 years agolibrados_test_stub: implement conf get/set API methods
Jason Dillaman [Thu, 30 Jul 2015 13:00:57 +0000 (09:00 -0400)]
librados_test_stub: implement conf get/set API methods

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
10 years agorbd: add "--keyring" option to help message 5399/head
Kefu Chai [Wed, 29 Jul 2015 10:18:35 +0000 (18:18 +0800)]
rbd: add "--keyring" option to help message

Refs: #12458
Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agoMerge pull request #5401 from ceph/wip-12450
Kefu Chai [Thu, 30 Jul 2015 03:36:37 +0000 (11:36 +0800)]
Merge pull request #5401 from ceph/wip-12450

tools/rados: change the default max_ops to 16

Reviewed-by: David Zafman <dzafman@redhat.com>
10 years agodoc: add bucket object version description. 5414/head
shawn [Thu, 30 Jul 2015 02:09:12 +0000 (10:09 +0800)]
doc: add bucket object version description.
bucket object version has been supported, but do not have description in the docs,
so add this part.

Signed-off-by: shawn chen <cxwshawn@gmail.com>
10 years agotest_librbd_fsx: invalidate before discard in krbd mode 5419/head
Ilya Dryomov [Wed, 29 Jul 2015 17:50:20 +0000 (20:50 +0300)]
test_librbd_fsx: invalidate before discard in krbd mode

Commit bd050240ceef ("test_librbd_fsx: flush before discard in krbd
mode") added an fsync() before BLKDISCARD.  Don't know what I was
thinking at the time, but I missed the invalidate part, for which we
need to use the BLKFLSBUF ioctl.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agoLog::reopen_log_file: take m_flush_mutex
Samuel Just [Fri, 24 Jul 2015 22:38:18 +0000 (15:38 -0700)]
Log::reopen_log_file: take m_flush_mutex

Otherwise, _flush() might continue to write to m_fd after it's closed.
This might cause log data to go to a data object if the filestore then
reuses the fd during that time.

Fixes: #12465
Backport: firefly, hammer
Signed-off-by: Samuel Just <sjust@redhat.com>
(cherry picked from commit 8778ab3a1ced7fab07662248af0c773df759653d)

10 years agoMerge pull request #5348 from athanatos/wip-12465
Sage Weil [Wed, 29 Jul 2015 13:30:37 +0000 (09:30 -0400)]
Merge pull request #5348 from athanatos/wip-12465

log: take mutex when reopening log fd

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agotools/rados: change the first op id to 0 5401/head
Kefu Chai [Wed, 29 Jul 2015 11:49:53 +0000 (19:49 +0800)]
tools/rados: change the first op id to 0

the first op id was 16 by default, which is okay, but a non-zero
magic number could lead to questions. max_op was mixed up with
max_ops, and changed to 16 in 51e402e3 by mistake.

Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agotools/rados: change the default max_ops to 16
Kefu Chai [Wed, 29 Jul 2015 11:44:57 +0000 (19:44 +0800)]
tools/rados: change the default max_ops to 16

otherwise the load-gen will not emit any ops by default.

Fixes: #12450
Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agocommon/syncfs: fall back to sync(2) if syncfs(2) not available 5395/head
Kefu Chai [Wed, 29 Jul 2015 07:52:19 +0000 (15:52 +0800)]
common/syncfs: fall back to sync(2) if syncfs(2) not available

Fixes: #12512
Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agorbd: remove dependency on non-ABI controlled CephContext 5426/head
Jason Dillaman [Tue, 28 Jul 2015 19:27:24 +0000 (15:27 -0400)]
rbd: remove dependency on non-ABI controlled CephContext

The rbd CLI tool no longer attempts to initialize a CephContext
and pass said context to librados since it's possible that the
structure will not be ABI compatible between rbd and librados.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
10 years agoMerge pull request #5139 from jmunhoz/wip-7817-ms
Yehuda Sadeh [Tue, 28 Jul 2015 18:21:25 +0000 (14:21 -0400)]
Merge pull request #5139 from jmunhoz/wip-7817-ms

rgw: add minimum support for copy multipart part

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoMerge pull request #5313 from guce/rgw_access_invalid_argument
Yehuda Sadeh [Tue, 28 Jul 2015 17:55:39 +0000 (13:55 -0400)]
Merge pull request #5313 from guce/rgw_access_invalid_argument

rgw: check subuser illegal access parameter.

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agocrypto: use NSS_InitContext/NSS_ShutdownContex to avoid memory leak
Jason Dillaman [Tue, 28 Jul 2015 17:14:29 +0000 (13:14 -0400)]
crypto: use NSS_InitContext/NSS_ShutdownContex to avoid memory leak

Switched to context-aware NSS init/shutdown functions to avoid conflicts
with parent application.  Use a reference counter to properly shutdown the
NSS crypto library when the last CephContext is destroyed.  This avoids
memory leaks with the NSS library from users of librados.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
10 years agoMerge pull request #5364 from xdonghai/master
Josh Durgin [Tue, 28 Jul 2015 16:20:55 +0000 (09:20 -0700)]
Merge pull request #5364 from xdonghai/master

doc:modified librados-intro.rst an error of document representation

Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@ril.com>
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
10 years agoMerge pull request #5191 from theanalyst/v9.0.2/mailmap
Loic Dachary [Tue, 28 Jul 2015 14:32:04 +0000 (16:32 +0200)]
Merge pull request #5191 from theanalyst/v9.0.2/mailmap

doc: mailmap for v9.0.2 release

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #5130 from tchaikov/wip-12167
Kefu Chai [Tue, 28 Jul 2015 13:38:38 +0000 (21:38 +0800)]
Merge pull request #5130 from tchaikov/wip-12167

ceph-detect-init: do not require "argparse" on py2.6

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #5338 from hjwsm1989/wip-12459
Kefu Chai [Tue, 28 Jul 2015 13:18:18 +0000 (21:18 +0800)]
Merge pull request #5338 from hjwsm1989/wip-12459

common/WorkQueue: fix the FTBFS with GCC 4.4.7

* add nested-name-specifier ThreadPool before WorkQueueVal

Reviewed-by: Kefu Chai <kchai@redhat.com>
10 years agotools/cephfs: respect mds_root_ino_[gid|uid] 5375/head
John Spray [Tue, 28 Jul 2015 11:43:33 +0000 (12:43 +0100)]
tools/cephfs: respect mds_root_ino_[gid|uid]

...while injecting inodes.  So that if you're a cephfs
admin but not uid=0 on the client, you can get things
injected as your choice of uid/gid.

Definitely useful for dev/test, potentially useful
elsewhere too.

Signed-off-by: John Spray <john.spray@redhat.com>
10 years agomds: configurable uid/gid on new root inos
John Spray [Tue, 28 Jul 2015 10:13:21 +0000 (11:13 +0100)]
mds: configurable uid/gid on new root inos

This is to deal with the slightly perverse situation
where a user might have all the permissions they need
to create a filesystem and mount it with fuse, but then
be unable to do anything inside the mount because
we default to creating a root-owned "/" inode.

This is immediatley useful for dev/test environments without
root, but also potentially in production environments
where the filesystem configuration/mounting is done by
someone less privileged than root.

Signed-off-by: John Spray <john.spray@redhat.com>
10 years agoMerge pull request #5350 from ceph/wip-pgls-filter-enc
Sage Weil [Tue, 28 Jul 2015 13:12:32 +0000 (09:12 -0400)]
Merge pull request #5350 from ceph/wip-pgls-filter-enc

osdc: fix pgls_filter op encoding

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #5355 from ceph/wip-anotate-s-files
Sage Weil [Tue, 28 Jul 2015 13:10:49 +0000 (09:10 -0400)]
Merge pull request #5355 from ceph/wip-anotate-s-files

Anotate all the .s files

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #5116 from yuyuyu101/wip-compressor
Sage Weil [Tue, 28 Jul 2015 13:05:04 +0000 (09:05 -0400)]
Merge pull request #5116 from yuyuyu101/wip-compressor

Wip compressor

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agomodified librados-intro.rst 5364/head
x11507 [Tue, 28 Jul 2015 12:19:41 +0000 (20:19 +0800)]
modified librados-intro.rst

Signed-off-by: x11507 <xu.donghai@h3c.com>
10 years agoMerge pull request #5254 from vuhuong/wip-xio
Kefu Chai [Tue, 28 Jul 2015 10:49:49 +0000 (18:49 +0800)]
Merge pull request #5254 from vuhuong/wip-xio

@vuhuong sorry for the latency, could you please rebase & repush , to poke the built bot again?

once the build completes, will get it merged.

thanks,

10 years agoosd/ReplicatedPG: claim the read buffer instead of copying it 5402/head
Kefu Chai [Tue, 28 Jul 2015 09:54:08 +0000 (17:54 +0800)]
osd/ReplicatedPG: claim the read buffer instead of copying it

Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agoMerge pull request #5349 from yuyuyu101/wip-async-fix-21
Haomai Wang [Tue, 28 Jul 2015 09:20:44 +0000 (17:20 +0800)]
Merge pull request #5349 from yuyuyu101/wip-async-fix-21

AsyncConnection: Exit process loop if entering fault

10 years agoMerge remote-tracking branch 'origin/next'
Josh Durgin [Mon, 27 Jul 2015 23:42:12 +0000 (16:42 -0700)]
Merge remote-tracking branch 'origin/next'

10 years agoMerge pull request #5352 from ceph/wip-rbd-help-specs
Josh Durgin [Mon, 27 Jul 2015 22:21:40 +0000 (15:21 -0700)]
Merge pull request #5352 from ceph/wip-rbd-help-specs

rbd: cli help and arg parsing fixes

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
10 years agoMerge pull request #5336 from ceph/wip-migrate-event-seq
Gregory Farnum [Mon, 27 Jul 2015 11:39:16 +0000 (12:39 +0100)]
Merge pull request #5336 from ceph/wip-migrate-event-seq

mds: fix val used in inode->last_journaled

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
10 years agoAnotate all the .s files 5355/head
Boris Ranto [Mon, 27 Jul 2015 11:14:32 +0000 (13:14 +0200)]
Anotate all the .s files

Recent update to erasure code library in 59aa6700 caused a regression
where .s files are no longer properly anotated and yasm sets the exec
stack for them. This patch brings back the anotations as was done before
by Dan Mick, see Bug #10114.

Signed-off-by: Boris Ranto <branto@redhat.com>
10 years agorbd: rename --object-extents option to --whole-object 5352/head
Ilya Dryomov [Thu, 23 Jul 2015 12:49:31 +0000 (15:49 +0300)]
rbd: rename --object-extents option to --whole-object

--object-extents is a bit confusing - extent is generally something of
a varying length and here the meaning is "diff whole objects".  Rename
it to --whole-object (the name of diff_iterate() parameter).

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agorbd: du command should take spec as an argument
Ilya Dryomov [Thu, 23 Jul 2015 12:55:47 +0000 (15:55 +0300)]
rbd: du command should take spec as an argument

Change du to take <image-spec> | <snap-spec> as an argument instead of
going through --image option.  The new synopsis is

    (du | disk-usage) [<image-spec> | <snap-spec>]

This is to make it look more like the rest of the commands: the only
other command that takes pool as an argument is ls and it can't really
serve as a prototype for du, because the latter has to work on images
and snapshots as well.

Examples:

    # stats for pool rbd
    $ rbd du
    $ rbd -p rbd du

    # stats for pool foo
    $ rbd -p foo du

    # stats for snapshot mysnap of image baz in pool rbd
    $ rbd du baz@mysnap

    # stats for image bar in pool foo
    $ rbd du foo/bar

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agorbd: assorted cli arg parsing fixes
Ilya Dryomov [Tue, 21 Jul 2015 15:11:20 +0000 (18:11 +0300)]
rbd: assorted cli arg parsing fixes

- import-diff needs image-spec, yet OPT_IMPORT_DIFF was in the list of
  commands that don't need imgname

- check for lock id after imgname, so that if imgname isn't specified
  we fail with imgname rather than lock id error message

- error out if locker isn't specified

- move feature-name validity check after imgname checks so that if
  imgname is malformed we fail with imgname rather than feature error
  message

- error out if image-meta key or value isn't specified

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agorbd: error out if dest_snapname is specified
Ilya Dryomov [Tue, 21 Jul 2015 14:55:55 +0000 (17:55 +0300)]
rbd: error out if dest_snapname is specified

No command uses it as of now, but only clone command fails; cp, mv and
import simply ignore it.  Check if it's set and exit with a generic
error message.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agorbd: import doesn't require image-spec arg, ditto for export and path
Ilya Dryomov [Mon, 20 Jul 2015 14:22:54 +0000 (17:22 +0300)]
rbd: import doesn't require image-spec arg, ditto for export and path

Mark those as such in help and clarify what image-spec defaults to.

Related, all command args in our man page are enclosed into brackets.
I suppose the reason is that they are optional in the sense that you
can have commands like

    $ rbd clone --pool a --image b --snap -c --dest-pool d --dest e

with no args.  Given that we are trying to push people towards

    $ rbd clone a/b@c d/e

undo that so that real optional arguments can be marked optional.
While at it, add synopsis for each command and use backticks for
denoting commands more consistently.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agodoc: use spec syntax in rbd docs
Ilya Dryomov [Fri, 17 Jul 2015 09:41:29 +0000 (12:41 +0300)]
doc: use spec syntax in rbd docs

Use spec syntax instead of --pool, --image and --snap to hopefully push
people towards the former.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agorbd: use image-spec and snap-spec in rbd help
Vikhyat Umrao [Thu, 16 Jul 2015 16:09:54 +0000 (21:39 +0530)]
rbd: use image-spec and snap-spec in rbd help

This patch changes image-name instances to image-spec and snap-name
instances to snap-spec to try to clarify usage for some commands and
disambiguate the term {image,snap}-name, which has been used to denote
both simple names and compound names (specs).

<image-spec> is [<pool-name>]/<image-name>
<snap-spec> is [<pool-name>]/<image-name>@<snap-name>

This patch also removes duplicate checks for image-name and snap-name.

Signed-off-by: Vikhyat Umrao <vumrao@redhat.com>
[idryomov@gmail.com: some commands take either image-spec or snap-spec,
other fixes, formatting, changelog]
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
10 years agoosdc: fix pgls_filter op encoding 5350/head
John Spray [Fri, 24 Jul 2015 13:46:49 +0000 (14:46 +0100)]
osdc: fix pgls_filter op encoding

This was broken with respect to the OSD's expected order
of decoding.

Signed-off-by: John Spray <john.spray@redhat.com>
10 years agoCompressor: Remove thread affinity options 5116/head
Haomai Wang [Mon, 27 Jul 2015 06:28:42 +0000 (14:28 +0800)]
Compressor: Remove thread affinity options

Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
10 years agoAsyncConnection: Exit process loop if entering fault 5349/head
Haomai Wang [Mon, 27 Jul 2015 04:34:18 +0000 (12:34 +0800)]
AsyncConnection: Exit process loop if entering fault

"fault" will transmit state to exception state or STATE_CONNECTING, all
transmitted states don't need to check right now.

Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
10 years agoMerge pull request #5342 from tchaikov/wip-fix-perf-local-on-arm
Haomai Wang [Sat, 25 Jul 2015 07:19:50 +0000 (15:19 +0800)]
Merge pull request #5342 from tchaikov/wip-fix-perf-local-on-arm

test/perf_local: disable tests on unsupported archs

Reviewed-by: Haomai Wang <haomaiwang@gmail.com>
10 years agotest/perf_local: disable tests on unsupported archs 5342/head
Kefu Chai [Fri, 24 Jul 2015 16:25:37 +0000 (00:25 +0800)]
test/perf_local: disable tests on unsupported archs

* maybe we can have div32 tests on aarch64, but i don't
  think "udiv|sdiv" supports 64bits numerator. probably
  we can use float divde for the benchmark...
* disable cpuid test on non-intel archs.

Fixes: #12453
Reported-by: Tom Deneau <tom.deneau@amd.com>
Signed-off-by: Kefu Chai <kchai@redhat.com>
10 years agoLog::reopen_log_file: take m_flush_mutex 5348/head
Samuel Just [Fri, 24 Jul 2015 22:38:18 +0000 (15:38 -0700)]
Log::reopen_log_file: take m_flush_mutex

Otherwise, _flush() might continue to write to m_fd after it's closed.
This might cause log data to go to a data object if the filestore then
reuses the fd during that time.

Fixes: #12465
Backport: firefly, hammer
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #5316 from shylesh/bugfix
Loic Dachary [Fri, 24 Jul 2015 14:29:35 +0000 (16:29 +0200)]
Merge pull request #5316 from shylesh/bugfix

mon: ceph osd map shows NONE when an osd is missing

Reviewed-by: Kefu Chai <kchai@redhat.com>
Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years ago common: add nested-name-specifier ThreadPool before WorkQueueVal 5338/head
huangjun [Fri, 24 Jul 2015 09:17:17 +0000 (17:17 +0800)]
  common: add nested-name-specifier ThreadPool before WorkQueueVal
Fixes: #12459
Signed-off-by: huangjun <hjwsm1989@gmail.com>
10 years agoMerge pull request #5322 from majianpeng/mds-log
John Spray [Fri, 24 Jul 2015 08:43:22 +0000 (09:43 +0100)]
Merge pull request #5322 from majianpeng/mds-log

mmds/MDLog: No make sense set offset for LogEvent in _start_entry.

Reviewed-by: John Spray <john.spray@redhat.com>
10 years agomds: fix val used in inode->last_journaled 5336/head
John Spray [Fri, 24 Jul 2015 08:37:15 +0000 (09:37 +0100)]
mds: fix val used in inode->last_journaled

This was getting assigned with LogEvent::get_start_offset
on an uncommitted LogEvent, which is junk.  During replay
last_journaled is compared with the metablob's event_seq,
so that's what should be used here.

This change just from code inspection -- haven't seen this
manifest as an actual misbehaviour.

Signed-off-by: John Spray <john.spray@redhat.com>
10 years agoMerge pull request #5330 from liewegas/wip-cephtool-test
Loic Dachary [Fri, 24 Jul 2015 06:46:40 +0000 (08:46 +0200)]
Merge pull request #5330 from liewegas/wip-cephtool-test

qa/workunits/cephtool/test.sh: escape osd.* and mon.*

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoqa/workunits/cephtool/test.sh: escape osd.* and mon.* 5330/head
Sage Weil [Thu, 23 Jul 2015 21:04:53 +0000 (17:04 -0400)]
qa/workunits/cephtool/test.sh: escape osd.* and mon.*

Otherwise we get filenames if the glob happens to match something in the
source dir.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge branch 'next'
John Spray [Thu, 23 Jul 2015 19:26:51 +0000 (20:26 +0100)]
Merge branch 'next'

10 years agoMerge pull request #5327 from athanatos/wip-12223
David Zafman [Thu, 23 Jul 2015 19:16:09 +0000 (12:16 -0700)]
Merge pull request #5327 from athanatos/wip-12223

WBThrottle::clear_object: signal if we cleared an object

Reviewed-by: David Zafman <dzafman@redhat.com>
10 years agoMerge pull request #5328 from athanatos/wip-12263
David Zafman [Thu, 23 Jul 2015 19:13:00 +0000 (12:13 -0700)]
Merge pull request #5328 from athanatos/wip-12263

ReplicatedPG::finish_promote: do not prefill new_clones

Reviewed-by: David Zafman <dzafman@redhat.com>
10 years agoWBThrottle::clear_object: signal if we cleared an object 5327/head
Samuel Just [Tue, 7 Jul 2015 15:49:54 +0000 (08:49 -0700)]
WBThrottle::clear_object: signal if we cleared an object

Fixes: #12223
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #5189 from athanatos/wip-recovery-defaults
David Zafman [Thu, 23 Jul 2015 18:47:37 +0000 (11:47 -0700)]
Merge pull request #5189 from athanatos/wip-recovery-defaults

config_opts: turn down default recovery tunables

Reviewed-by: David Zafman <dzafman@redhat.com>
10 years agoMerge pull request #5329 from athanatos/wip-8193
David Zafman [Thu, 23 Jul 2015 18:46:17 +0000 (11:46 -0700)]
Merge pull request #5329 from athanatos/wip-8193

test/librados/tier.cc: we can exceed the hitset limit while backfilling

Reviewed-by: David Zafman <dzafman@redhat.com>
10 years agoMerge pull request #5323 from ceph/wip-12426
John Spray [Thu, 23 Jul 2015 18:43:53 +0000 (19:43 +0100)]
Merge pull request #5323 from ceph/wip-12426

mon: fix checks on mds add_data_pool

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
10 years agoMerge pull request #4982 from branch-predictor/bp-lighter-rwlocks
Samuel Just [Thu, 23 Jul 2015 18:02:48 +0000 (11:02 -0700)]
Merge pull request #4982 from branch-predictor/bp-lighter-rwlocks

common/RWLock: allow disabling read/write lock counts

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #5152 from branch-predictor/bp-rados-aio-overrun
Samuel Just [Thu, 23 Jul 2015 18:00:01 +0000 (11:00 -0700)]
Merge pull request #5152 from branch-predictor/bp-rados-aio-overrun

tools: fix race condition in seq/rand bench

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #5093 from guangyy/wip-12162
Samuel Just [Thu, 23 Jul 2015 17:49:00 +0000 (10:49 -0700)]
Merge pull request #5093 from guangyy/wip-12162

osd - pg_interval_t::check_new_interval should not rely on pool.min_size to determine if the PG was active

Reviewed-by: Samuel Just <sjust@redhat.com>