summaryrefslogtreecommitdiffstats
path: root/src/librbd/AsyncObjectThrottle.cc (unfollow)
Commit message (Collapse)AuthorFilesLines
2020-11-20github/labeler: label manpages changes with related component labelsKefu Chai1-10/+22
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-19github/labeler: add rbd label to pybind/mgr/rbd_supportJason Dillaman1-0/+1
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2020-11-19crimson: fix a debug in BackfillState::Enqueuing::Enqueuing.Radoslaw Zarzynski1-1/+1
Printed messages were messed up due to the erroneous comma. Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
2020-11-19crimson: add a debug in update_on_peers() of the backfill code.Radoslaw Zarzynski1-0/+1
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
2020-11-19crimson: fix a typo in errorator-related comment.Radoslaw Zarzynski1-1/+1
It was introduced in dca575992b34611d20f50c5db47e4b533cd7dc69. Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
2020-11-19ceph-volume: cover devices.lvm.prepare.setup_deviceGuillaume Abrioux1-0/+44
Add some unit tests to cover setup_device() in devices.lvm.prepare Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
2020-11-19ceph-volume: fix filestore/dmcrypt activateGuillaume Abrioux1-8/+10
The uuid set for tags['ceph.journal_uuid'] should point to its corresponding lv_uuid instead of the uuid generated for the lv_name. The variable name 'uuid' used so far was probably too confusing so let's change it to make it more clear. Closes: https://tracker.ceph.com/issues/48271 Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
2020-11-19doc/script/gen_state_diagram: wrap lines which is over 80 charsKefu Chai1-7/+13
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-19doc/script/gen_state_diagram: use itertools.cycle() for cycling in colorsKefu Chai1-11/+5
for better readability Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-19doc: pass graphviz options in conf.pyKefu Chai2-1/+3
easier to maintain the options of sphinx extensions in a single place. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-19doc: generate peering graph in conf.pyKefu Chai2-2/+20
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-19doc/script/gen_state_diagram: add "output" parameter to emit_dot()Kefu Chai1-8/+8
this allows us to reuse this python script as a module. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-19doc/script/gen_state_diagram: only run if called as a scriptKefu Chai1-4/+5
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-19librbd: fix crypto prepare_copyup to use new remap_extents apiOr Ozeri2-3/+17
This commit changes the crypto prepare_copyup implementation to correctly translate object extents to image extents, via the remap_extents api. Additionally, we fix relevant unit tests that call this api to correctly expect these calls. Signed-off-by: Or Ozeri <oro@il.ibm.com>
2020-11-19doc: increase visibility of the peering state diagramJianshen Liu1-3/+29
Signed-off-by: Jianshen Liu <jliu120@ucsc.edu>
2020-11-18librbd: add encryption support for copyupOr Ozeri20-25/+248
This commit implements the prepare_copyup api by the crypto object dispatch layer. Signed-off-by: Or Ozeri <oro@il.ibm.com>
2020-11-18.github/labeler.yml: add label for tests and classify core testsNeha Ojha1-0/+10
Signed-off-by: Neha Ojha <nojha@redhat.com>
2020-11-18.github/labeler.yml: fix bluestore ruleNeha Ojha1-1/+1
Signed-off-by: Neha Ojha <nojha@redhat.com>
2020-11-18doc/dev: update list in unit test sectionZac Dover1-2/+2
This commit removes an unwanted extra nested list layer from a list. Signed-off-by: Zac Dover <zac.dover@gmail.com>
2020-11-18rpm: cephadm package is noarchKen Dreyer1-0/+1
The cephadm package contains an architecture-independent Python script, empty directories, and an empty authorized_keys file. There are no architecture-dependent files here, so we can use a single noarch RPM across all host architectures. Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
2020-11-18doc/dev: update unit test declarationZac Dover1-7/+11
This commit updates the text in the "How Unit Tests Are Declared" section of tests-unit-tests.rst. This commit breaks long sentences into shorter sentences and breaks a sentence into a bulleted list that might reduce the reader's cognitive load. Signed-off-by: Zac Dover <zac.dover@gmail.com>
2020-11-18common: add trailing newline before parsing cfgLucian Petrut1-10/+12
Ceph fails to parse config files that lack a trailing newline. This mainly affects Windows, where text editors won't add one by default. This issue has been addressed by a previous commit [1] but that code path is no longer reached [2][3], so we need to go down a level. [1] 3b590314ac49b955b2123f03f4c4417e5534ec98 [2] http://paste.openstack.org/raw/800153/ [3] https://github.com/ceph/ceph/commit/e7dcc403b20922ffeeca114899f90a385bf25f0e Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18github/labeler: disable sync-labelsErnesto Puerta1-7/+7
Yaml syntax cleaned too. Fixes: https://github.com/ceph/ceph/pull/38107#issuecomment-729300615 Signed-off-by: Ernesto Puerta <epuertat@redhat.com>
2020-11-18github: add ceph-volume autolabelJan Fajerski1-0/+4
Signed-off-by: Jan Fajerski <jfajerski@suse.com>
2020-11-18compat,msg: improve Windows socket checksLucian Petrut2-58/+94
win_socketpair can fail with EADDRINUSE under load, which will lead to an unhandled exception/crash as per this commit [1]. This change adds a retry, also ensuring that the right error code gets propagated (the one returned by WSAGetLastError() instead of the generic SOCKET_ERROR). While at it, we're fixing the "win_socketpair" indentation and addressing the SOCKET to int casts. [1] https://github.com/ceph/ceph/commit/633805060a1002c86570fe50d099e0c1e223e2d7 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18rbd: Use the right device type on WindowsLucian Petrut5-4/+233
"wnbd" will be the only supported device type on Windows, for now. We'll update the "rbd" wrapper accordingly. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18rbd: allow mounting images on WindowsLucian Petrut9-6/+2091
This change will allow mapping rbd images on Windows, leveraging the WNBD[1] Virtual Storport Miniport driver [2]. The behavior and CLI is similar to the Linux rbd-nbd, with a few notable differences: * device paths cannot be requested. The disk number and path will be picked by Windows. If a device path is provided by the user when mapping an image, it will be used as an identifier, which can also be used when unmapping the image. * the "show" command was added, which describes a specific mapping. This can be used for retrieving the disk path. * the "service" command was added, allowing rbd-wnbd to run as a Windows service. All mappings are currently perisistent, being recreated when the service stops, unless explicitly unmapped. The service disconnects the mappings when being stopped. * the "list" command also includes a "status" column. The purpose of the "service" mode is to ensure that mappings survive reboots and that the Windows service start order can be adjusted so that rbd images can be mapped before starting services that may depend on it, such as VMMS. The mapped images can either be consumed by the host directly or exposed to Hyper-V VMs. While at it, we'll skip building rbd-mirror as it's quite unlikely that this daemon is going to be used on Windows for now. [1] https://github.com/cloudbase/wnbd [2] https://docs.microsoft.com/en-us/windows-hardware/drivers/storage/overview-of-storage-virtual-miniport-drivers Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
2020-11-18rbd: add missing FileStream::get_sizeLucian Petrut1-0/+5
At the moment, a few methods will be stubbed if BOOST_ASIO_HAS_POSIX_STREAM_DESCRIPTOR is undefined. The issue is that FileStream::get_size is undefined, so we're getting link issues on Windows. In the future, we might consider using asio::windows::stream_handle on Windows. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18build: disable stack protection on WindowsLucian Petrut1-4/+6
Passing "-fstack-protector-strong" doesn't seem to work with Mingw, complaining about undefied "__stack_chk_fail". For this reason, we'll disable it for now. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18rbd: Update Windows readmeLucian Petrut1-2/+256
This change updates the Windows readme, describing rbd-wnbd configuration and usage. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18rbd: fix import image path parsing on WindowsLucian Petrut1-1/+1
When importing an image, the rbd command uses only the file name and expects "/" to be used as a separator. On Windows, it will use the entire path as image name since the path separator is not the same. This change updates it so that the "\\" path separator can be properly handled as well. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18common: move Windows files to a separate folderLucian Petrut11-13/+24
We ended up with quite a few files having the "_win32" suffix. It's probably better if we move them to a separate folder and drop the suffix. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
2020-11-18crimson/os: do not capture unused variablesKefu Chai3-6/+5
silences warnings reported by clang iike: btree_lba_manager.cc:439:50: warning: lambda capture 't' is not used [-Wunused-lambda-capture] lba_node->get_node_meta().depth).safe_then([=, &t](LBANodeRef c) { ~~~^ 1 warning generated. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18cmake: set advice.detachedHead=false when cloning liburingKefu Chai1-0/+1
silence "detached HEAD" warning like: You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by performing another checkout. If you want to create a new branch to retain commits you create, you may do so (now or later) by using -b with the checkout command again. Example: git checkout -b <new-branch-name> Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd/object_context: drop unused methodsKefu Chai1-53/+0
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd: add PG::with_clone_obc()Kefu Chai2-98/+64
this method replaces `PG::get_or_load_clone_obc()`. so we can with `seastar::with_lock()` to ensure that `lock.unlock()` is always called when accessing clone obc. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd: drop PG::get_or_load_head_obc()Kefu Chai2-39/+0
as it is not used anymore. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd: use with_head_obc() to replace get_or_load_head_obcKefu Chai4-25/+18
for better readability, and ensure that `lock.unlock()` is called when an error is returned after the lock is acquired. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd: add PG::with_head_obc()Kefu Chai3-13/+34
this method replicates `PG::get_or_load_head_obc()`. but uses a different way to ensure that the "lock" on obc is always released even if the called func throws. it always guard the called func with a `with_lock()`, so `lock.unlock()` is always called. the plan is to replace `PG::get_or_load_head_obc()` with `PG::with_head_obc()` in the following changes piecemeal. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd: pass RWState using template parameterKefu Chai1-6/+6
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd: mark PG::get_locked_obc() privateKefu Chai1-4/+5
this methods is used by PG::with_locked_obc(). so mark it private. Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/osd: move PG::with_locked_obc() into .ccKefu Chai2-15/+20
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18crimson/common: correct template parameter of seastar::future<>Kefu Chai1-1/+1
it's a leftover of 688b95798bfd88b409abce9b70bb6d2933819bef Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-11-18common: Add Windows service helpersLucian Petrut3-1/+188
We'll add a class that implements Windows service hooks. Subclasses must overide the start, stop and shutdown hooks. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
2020-11-18common: Add Windows registry key utilsLucian Petrut3-1/+194
We'll add some helpers facilitating Windows registry key operations. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
2020-11-18os/bluestore: fix lack of blob unshare if 'root' onode is not presentIgor Fedotov1-2/+2
in cache. Signed-off-by: Igor Fedotov <ifedotov@suse.com>
2020-11-18test/store_test: add unshare blob tests casesIgor Fedotov2-0/+180
Signed-off-by: Igor Fedotov <ifedotov@suse.com>
2020-11-18os/bluestore: Buffer's flag might be lost if it's partially discarded orIgor Fedotov1-10/+15
split. Haven't seen any real issues due to this though. Signed-off-by: Igor Fedotov <ifedotov@suse.com>
2020-11-18doc/dev: update unit test 1 of 7Zac Dover1-5/+11
This commit updates the language at the beginning of the Unit Test section of the developer guide. The language in this edit is more grammatical than it used to be, and should now reduce the reader's cognitive load. Signed-off-by: Zac Dover <zac.dover@gmail.com>
2020-11-18doc/dev: update unit tests 2 of 7Zac Dover1-14/+17
This commit updates the "What does 'make check' mean" section of the "Unit Tests" chapter of the Developer Guide. It makes the wording a bit less editorial and attempts to reduce the reader's cognitive load. Signed-off-by: Zac Dover <zac.dover@gmail.com>