summaryrefslogtreecommitdiff
path: root/doc/man/8/monmaptool.rst
blob: 52ec475cc047436d3b5409404f55140536243545 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
==========================================================
 monmaptool -- ceph monitor cluster map manipulation tool
==========================================================

.. program:: monmaptool

Synopsis
========

| **monmaptool** *mapfilename* [ --clobber ] [ --print ] [ --create ]
  [ --add *ip*:*port* *...* ] [ --rm *ip*:*port* *...* ]


Description
===========

**monmaptool** is a utility to create, view, and modify a monitor
cluster map for the Ceph distributed file system. The monitor map
specifies the only fixed addresses in the Ceph distributed system.
All other daemons bind to arbitrary addresses and register themselves
with the monitors.

When creating a map with --create, a new monitor map with a new,
random UUID will be created. It should be followed by one or more
monitor addresses.

The default Ceph monitor port is 6789.


Options
=======

.. option:: --print

   will print a plaintext dump of the map, after any modifications are
   made.

.. option:: --clobber

   will allow monmaptool to overwrite mapfilename if changes are made.

.. option:: --create

   will create a new monitor map with a new UUID (and with it, a new,
   empty Ceph file system).

.. option:: --add name ip:port

   will add a monitor with the specified ip:port to the map.

.. option:: --rm name

    will remove the monitor with the specified ip:port from the map.

.. option:: --fsid uuid

    will set the fsid to the given uuid.  If not specified with --create, a random fsid will be generated.


Example
=======

To create a new map with three monitors (for a fresh Ceph file system)::

        monmaptool  --create  --add  mon.a 192.168.0.10:6789 --add mon.b 192.168.0.11:6789 \
          --add mon.c 192.168.0.12:6789 --clobber monmap

To display the contents of the map::

        monmaptool --print onmap

To replace one monitor::

        monmaptool --rm mon.a --add mon.a 192.168.0.9:6789 --clobber monmap


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

**monmaptool** is part of the Ceph distributed file system.  Please
refer to the Ceph wiki at http://ceph.newdream.net/wiki for more
information.


See also
========

:doc:`ceph <ceph>`\(8),
:doc:`crushtool <crushtool>`\(8),
:doc:`mkcephfs <mkcephfs>`\(8)