2015-04-07 10:11:29 +00:00
:orphan:
2011-09-09 23:21:52 +00:00
==========================================================
monmaptool -- ceph monitor cluster map manipulation tool
==========================================================
.. program :: monmaptool
Synopsis
========
2020-03-28 23:42:47 +00:00
| **monmaptool** <action> [options] *mapfilename*
2011-09-09 23:21:52 +00:00
Description
===========
**monmaptool** is a utility to create, view, and modify a monitor
2013-12-07 20:52:16 +00:00
cluster map for the Ceph distributed storage system. The monitor map
2011-09-09 23:21:52 +00:00
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.
2020-03-28 23:42:47 +00:00
The default Ceph monitor port for messenger protocol v1 is 6789, and
3300 for protocol v2.
Multiple actions can be performed per invocation.
2011-09-09 23:21:52 +00:00
Options
=======
.. option :: --print
2020-03-28 23:42:47 +00:00
print a plaintext dump of the map, after any modifications are
2011-09-09 23:21:52 +00:00
made.
2020-03-28 23:42:47 +00:00
.. option :: --feature-list [plain|parseable]
2011-09-09 23:21:52 +00:00
2020-03-28 23:42:47 +00:00
list the enabled features as well as the available ones.
By default, a human readable output is produced.
2011-09-09 23:21:52 +00:00
.. option :: --create
2020-03-28 23:42:47 +00:00
create a new monitor map with a new UUID (and with it, a new,
empty Ceph cluster).
.. option :: --clobber
allow monmaptool to create a new mapfilename in place of an existing map.
Only useful when *--create* is used.
2012-05-18 17:52:04 +00:00
.. option :: --generate
generate a new monmap based on the values on the command line or specified
in the ceph configuration. This is, in order of preference,
#. `` --monmap filename `` to specify a monmap to load
#. `` --mon-host 'host1,ip2' `` to specify a list of hosts or ip addresses
2018-12-22 00:25:55 +00:00
#. `` [mon.foo] `` sections containing `` mon addr `` settings in the config. Note that this method is not recommended and support will be removed in a future release.
2012-05-18 17:52:04 +00:00
.. option :: --filter-initial-members
filter the initial monmap by applying the `` mon initial members ``
setting. Monitors not present in that list will be removed, and
initial members not present in the map will be added with dummy
addresses.
2011-09-09 23:21:52 +00:00
2020-03-28 23:42:47 +00:00
.. option :: --add name ip[:port]
add a monitor with the specified ip:port to the map.
2011-09-09 23:21:52 +00:00
2020-03-28 23:42:47 +00:00
If the *nautilus* feature is set, and the port is not, the monitor
will be added for both messenger protocols.
2011-09-09 23:21:52 +00:00
2019-06-27 13:58:06 +00:00
.. option :: --addv name [protocol:ip:port[,...]]
2020-03-28 23:42:47 +00:00
add a monitor with the specified version:ip:port to the map.
2019-06-27 13:58:06 +00:00
2011-09-09 23:21:52 +00:00
.. option :: --rm name
2020-03-28 23:42:47 +00:00
remove the monitor with the specified name from the map.
2011-09-09 23:21:52 +00:00
2011-11-12 21:16:30 +00:00
.. option :: --fsid uuid
2020-03-28 23:42:47 +00:00
set the fsid to the given uuid. If not specified with *--create* , a random fsid will be generated.
.. option :: --feature-set value [--optional|--persistent]
enable a feature.
.. option :: --feature-unset value [--optional|--persistent]
disable a feature.
.. option :: --enable-all-features
enable all supported features.
.. option :: --set-min-mon-release release
2011-11-12 21:16:30 +00:00
2020-03-28 23:42:47 +00:00
set the min_mon_release.
2011-09-09 23:21:52 +00:00
Example
=======
2020-03-28 23:42:47 +00:00
To create a new map with three monitors (for a fresh Ceph cluster)::
2011-09-09 23:21:52 +00:00
2020-03-28 23:42:47 +00:00
monmaptool --create --add nodeA 192.168.0.10 --add nodeB 192.168.0.11 \
--add nodeC 192.168.0.12 --enable-all-features --clobber monmap
2011-09-09 23:21:52 +00:00
To display the contents of the map::
2013-08-21 17:56:23 +00:00
monmaptool --print monmap
2011-09-09 23:21:52 +00:00
To replace one monitor::
2020-03-28 23:42:47 +00:00
monmaptool --rm nodeA monmap
monmaptool --add nodeA 192.168.0.9 monmap
2011-09-09 23:21:52 +00:00
Availability
============
2016-01-15 07:42:15 +00:00
**monmaptool** is part of Ceph, a massively scalable, open-source, distributed
2021-03-21 16:17:21 +00:00
storage system. Please refer to the Ceph documentation at https://docs.ceph.com
2016-01-15 07:42:15 +00:00
for more information.
2011-09-09 23:21:52 +00:00
See also
========
:doc: `ceph <ceph>` \(8),
:doc: `crushtool <crushtool>` \(8),