Skip to content

Commit

Permalink
doc: Update ceph-disk manual page with new feature deactivate/destroy.
Browse files Browse the repository at this point in the history
  - Update the ceph-disk manual page

Signed-off-by: Vicente Cheng <freeze.bilsted@gmail.com>
  • Loading branch information
Vicente-Cheng committed Nov 18, 2015
1 parent 46249fe commit 8fbd877
Showing 1 changed file with 91 additions and 2 deletions.
93 changes: 91 additions & 2 deletions doc/man/8/ceph-disk.rst
@@ -1,7 +1,7 @@
:orphan:

===================================================================
ceph-disk -- Ceph disk preparation and activation utility for OSD
ceph-disk -- Ceph disk utility for OSD
===================================================================

.. program:: ceph-disk
Expand All @@ -14,12 +14,18 @@ Synopsis
| **ceph-disk** **activate** [*data-path*] [--activate-key *path*]
[--mark-init *sysvinit|upstart|systemd|auto|none*]
[--no-start-daemon]
[--no-start-daemon] [--reactivate]
| **ceph-disk** **activate-all**
| **ceph-disk** **list**
| **ceph-disk** **deactivate** [--cluster *clustername*] [*device-path*]
[--deactivate-by-id *id*] [--mark-out]
| **ceph-disk** **destroy** [--cluster *clustername*] [*device-path*]
[--destroy-by-id *id*] [--dmcrypt-key-dir *KEYDIR*] [--zap]
Description
===========

Expand All @@ -32,6 +38,10 @@ It actually automates the multiple steps involved in manual creation and start
of an OSD into two steps of preparing and activating the OSD by using the
subcommands ``prepare`` and ``activate``.

Futhermore, now :program:`ceph-disk` also automates the multiple steps invloved
in manual stop and destroy of an OSD into two steps of deactivating and destroying
the OSD by using the subcommands ``deactivate`` and ``destroy``.

Subcommands
============

Expand Down Expand Up @@ -97,6 +107,13 @@ Usage::
If the option :option:`--no-start-daemon` is given, the activation
steps are performed but the OSD daemon is not started.

The latest option :option:`--reactivate` can re-activate the osd which is on the
``deactivate`` status.

Usage::

ceph-disk activate [PATH] [--reactivate]

activate-journal
----------------

Expand Down Expand Up @@ -176,6 +193,62 @@ Usage::

Here, [PATH] is path to a block device or a directory.

deactivate
----------
Deactivate the Ceph OSD. It stops osd daemo and try to mark this osd out
(optional). To prevent OSD activate by ``udev``, remove the *ready*, *active*,
*INIT-specific* files and add the *deactive* file. Last, unmount the currect
osd location. Futhermore, if the osd is dmcrypt, remove the data dmcrypt map. Atfer
that, osd will remain the ``down`` status, you can activate with
:option:`--reactivate`. Now, It is only run directly. It can be triggered
by :program:`ceph-deploy` in later version.

Usage::

ceph-disk deactivate [PATH]

Here, [PATH] is path to a block device or a directory.

Another option :option:`--mark-out` can also be used with this subcommand.
``--mark-out`` marks the OSD out. It will trigger the object remapped. If
you are not sure you will destory OSD, you may avoid to use this option.
That may cause redundant overhead due to object remapped.

For the convince, you can also use ``osd-id``, id of osd, to deactivate
osd with subcommand :option:`--deactivate-by-id`.

Usage::

ceph-disk deactivate --deactivate-by-id [OSD-ID]

destroy
-------
Destroy the Ceph OSD. It removes the osd from cluster and crushmap and
deallocates OSD ID. It only can destroy the OSD on *down* status. Futhermore,
if the osd is dmcrypt, remove the journal dmcrypt map. Now, It is only run
directly. It could be triggered by :program:`ceph-deploy` in later version.

Usage::

ceph-disk destroy [PATH]

Here, [PATH] is path to a block device or a directory.

Another option :option:`--zap` can also be used with this subcommand.
``--zap`` will erase data and partition.

Usage::

ceph-disk destroy [PATH] [--zap]

For the convince, you can alose use ``osd-id``, id of osd, to destroy
osd with subcommand :option:`--destroy-by-id`. It costs redundant
overhead due to dmcrypt map rebuilding and osd-id checking.

Usage::

ceph-disk destroy --destroy-by-id [OSD-ID]

zap
---

Expand Down Expand Up @@ -264,6 +337,22 @@ Options

Provide init system to manage the OSD directory.

.. option:: --mark-out

Mark the OSD out.

.. option:: --deactivate-by-id

Use osd-id to deactivate OSD.

.. option:: --zap

Erase data and partition after OSD destroy

.. option:: --destroy-by-id

Use osd-id to destroy OSD.

Availability
============

Expand Down

0 comments on commit 8fbd877

Please sign in to comment.