Commit Graph

93239 Commits

Author SHA1 Message Date
Sage Weil
a58fcf9e0f qa/suites/rados/basic/msgr: do not use msgr2 with simplemessenger
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
9a5aa423e0 qa/suites/rados/basic/msgr: async is not experimental
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
a56a7fb695 messages/MOSDBoot: fix compat with pre-nautilus
We can't make an addr -> addrvec transition without a compat encoding,
unfortunately (I screwed this one up back when then ADDR2 feature was
introduced).

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
d16f6e4654 mon/MonMap: allow v1 or v2 to be explicitly specified along with part
If there is a v1: or v2: prefix, that's the protocol/addr type.  Otherwise,
we assume msgr2.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
bdfbd857e2 msg/msg_types: allow parsing of IPs without assuming v1 vs v2
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
12416b77bd msg/msg_types: default parse to v2 addrs
If we parse "1.2.3.4", parse to v2:1.2.3.4:0/0, not a v1 legacy addr.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
f174bbead4 msg: standarize on v1: and v2: prefixes for *all* entity_addr_t's
This is more consistent than 1.2.3.4:0/0 being v1 and msgr2:1.2.3.4:0/0
being v2.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
15684843f0 vstart.sh: use msgr2 by default
This is useful because we tend to bind to random ports

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
399aba37fe mon/MonMap: remove get_addr() methods
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
a6e2cbde8f ceph-mon: adjust startup/bind/join sequence to use addrs
- Use the addrvecs in the monmap, and bind accordingly
- If we are joining the cluster, generate sane addrvec for ourselves
- Adjsut warning about mismatched ceph.conf.  Note that this may become
noisy for old clusters, mostly because the conf-based mon addr options
are ancient and crufty and should not be used.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
8e251c5827 mon: use MonMap::get_addrs() (instead of get_addr())
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
2f0b050fa2 mon/MonClient: change pending_cons to addrvec-based map
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
f926f13793 mon/MonMap: fix set_addr() caller, kill wrapper
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
ba21824296 mon/MonMap: remove addr-based add()
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
446ce2b0dc monmaptool: fix --add to do either legacy or msgr2+legacy
Base the decision on the monmap's required_features vs FEATURE_NAUTILIUS.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
a8cd2f7104 monmaptool: clean up iterator use a bit
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
ab896ec793 mon/MonMap: handle ambiguous mon addrs by trying both legacy and msgr
If we are given a mon addr (a raw IP or hostname) we don't know whether
it is a legacy or msgr2 entity_addr_t.  Either infer from the port number
or probe both protocol types.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
491b3e45c4 mon/MonMap: take addrvec for set_initial_members
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
3045133dda mon/MonMap: use addrvecs for test instances
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
611c1c126d mon: pass addrvec via MMonJoin
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
144cf68917 mon/MonmapMonitor: fix 'mon add' to populate addrvec
If a port is not specified (or the legacy port is specified), add both
the new IANA and legacy addrs to the map.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
b6a7079439 mon/MonMap: addr -> addrvec
Modify MonMap to store an addrvec instead of just an addr.

Add temporary helper/wrapper methods to avoid changing all of the callers
(yet).

No big semantic changes yet!

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:31:32 -06:00
Sage Weil
16a0bbb0aa msg/async/ProtocolV2: only update socket_addr if we learned our addr
Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:30:18 -06:00
Sage Weil
5709fb9122 osd: go active even if mon only accepted our v1 addr
We may bind to v1 and v2 addrs, but we need to behave if the mon only
recognized our v1 addr and still go active.  That's because whether they
see our v2 addr depends on whether we connected to the mon via the v1 or
v2 port, and the mon may not be binding to v2 (yet, or ever).

Add a legacy_equals to entity_addrvec_t, and use that instead of
probably_equals for the OSD boot checks.  The probably_equals returns true
if the IP address portion of the address is empty.. which should never
happen in the OSD boot case since we have learned our real IP long before
we try to send osd_boot.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:30:18 -06:00
Ricardo Dias
dd05584021 test/msgr: add test for msgr2 protocol
Signed-off-by: Ricardo Dias <rdias@suse.com>
2018-12-21 15:30:18 -06:00
Sage Weil
a1401bd3f7 msg/async/ProtocolV2: share socket_addr and all addrs during handshake
Also, drop the sloppy addr checks.. I'm not sure we need them?

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:30:18 -06:00
Sage Weil
3031a65cbb msg/async: print socket_addr for the connection
When we bind to multiple addrs, print the one the current connection is
using for the given connection.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:30:18 -06:00
Ricardo Dias
08d9f8aa08 msg/async: msgr2 protocol placeholder
This commit adds messenger V2 protocol. This V2 protocol is a clone of
the V1 protocol with the additional support for address vectors.
After the banner exchange the peers exchange their address vectors.

Signed-off-by: Ricardo Dias <rdias@suse.com>
2018-12-21 15:30:18 -06:00
Ricardo Dias
8ab05504f0 msg/async: move ProtocolV1 class to its own source file
Signed-off-by: Ricardo Dias <rdias@suse.com>
2018-12-21 15:30:18 -06:00
Sage Weil
3a52d3cf03 msg/async: keep listen addr in ServerSocket, pass to new connections
When we accept a connection, we want to know what listening addr we
accepted on.  Because the addr can change after we create teh listening socket
(when we learn the addr and fill in the IP portion), instead store the position
in our myaddrs addrvec.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:30:18 -06:00
Sage Weil
7ae4affef5 msg/async/AsyncMessenger: fix set_addr_unknowns
Fill in IP address from a v1 or v2 address into any v1 or v2 addresses.

Signed-off-by: Sage Weil <sage@redhat.com>
2018-12-21 15:30:18 -06:00
Sage Weil
6e6159c899 Merge PR #25620 into master
* refs/pull/25620/head:
	os/bluestore: more robust handling for lack of per-pool stats cases.

Reviewed-by: Sage Weil <sage@redhat.com>
2018-12-21 10:12:42 -06:00
Sage Weil
42de7e43a4 Merge PR #25632 into master
* refs/pull/25632/head:
	test: add a json tester
	ceph_json: parser sets data on all types when parsing

Reviewed-by: Sage Weil <sage@redhat.com>
2018-12-21 09:49:37 -06:00
Kefu Chai
e57649dd9c
Merge pull request #22800 from wjwithagen/wjw-ctest-timeout
cmake: allow setting of the CTest timeout during building.

Reviewed-by: Kefu Chai <kchai@redhat.com>
2018-12-21 23:40:27 +08:00
Kefu Chai
28b91c5305
Merge pull request #25661 from joscollin/wip-doc-changing-monitors
doc: fix typo in add-or-rm-mons

Reviewed-by: Kefu Chai <kchai@redhat.com>
2018-12-21 14:46:48 +08:00
Kefu Chai
3dcb9fdfe6
Merge pull request #25639 from oliveiradan/wip-krb_pr25566_cleanup_oliveiradan
auth/krb: Fix Kerberos build warnings

Reviewed-by: Sage Weil <sage@redhat.com>
2018-12-21 14:36:51 +08:00
Kefu Chai
bfd5aabcf7
Merge pull request #25537 from jecluis/dev/wip-mgr-module-error
mgr: make module error message more descriptive

Reviewed-by: Ricardo Dias <rdias@suse.com>
Reviewed-by: Lenz Grimmer <lgrimmer@suse.com>
Reviewed-by: Sebastian Wagner <sebastian.wagner@suse.com>
2018-12-21 14:09:40 +08:00
Kefu Chai
b5cb2115ba
Merge pull request #25595 from rzarzynski/wip-ec-drop_bl_crosstalk_dependency
ec: lrc doesn't depend on crosstalks between bufferlists anymore.

Reviewed-by: Sage Weil <sage@redhat.com>
2018-12-21 14:06:08 +08:00
Kefu Chai
5d9440b203
Merge pull request #25503 from ceph/rbd-mirror-ceph-base
spec: requires ceph base instead of common

Reviewed-by: Nathan Cutler <ncutler@suse.com>
Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2018-12-21 14:04:34 +08:00
Jos Collin
6dba3865c9
doc: fix typo in add-or-rm-mons
Signed-off-by: Jos Collin <jcollin@redhat.com>
2018-12-21 10:47:04 +05:30
Jason Dillaman
c84cc4a542
Merge pull request #25655 from gregsfortytwo/wip-rbd-snap-doc
doc: Clean up the snapshot consistency note

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2018-12-20 18:07:36 -05:00
Sage Weil
fc4adfd27a Merge PR #25577 into master
* refs/pull/25577/head:
	test: allow ceph_kvstorebench to be build on FreeBSD

Reviewed-by: Kefu Chai <kchai@redhat.com>
2018-12-20 17:02:15 -06:00
Sage Weil
4d61afd33a Merge PR #25508 into master
* refs/pull/25508/head:
	kv/rocksdb_cache: Remove C style struct hack undefined behavior

Reviewed-by: Neha Ojha <nojha@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
2018-12-20 17:01:54 -06:00
Sage Weil
bb804eb895 Merge PR #25236 into master
* refs/pull/25236/head:
	ceph-volume: Add venv to vstart cmake target
	mgr/orchestrator: Add test orchestrator

Reviewed-by: Jeff Layton <jlayton@redhat.com>
2018-12-20 17:01:04 -06:00
Greg Farnum
505025c641 doc: Clean up the snapshot consistency note
The old note made it sound like we weren't crash-consistent, and had a
confusing section about needing to clone before mounting.
You *do* need to clone the snapshot before mounting it, but that has
nothing to do fs freezing or consistency.

Signed-off-by: Greg Farnum <gfarnum@redhat.com>
2018-12-20 10:33:38 -08:00
Daniel Oliveira
1f32b2b37c auth/krb: Fix Kerberos build warnings
Signed-off-by: Daniel Oliveira <doliveira@suse.com>
2018-12-20 11:16:00 -07:00
Kefu Chai
539a16f376
Merge pull request #25207 from cyx1231st/wip-crimson-msgr-dispatch-events
crimson/net: encapsulate protocol implementations with states (remaining part)

Reviewed-by: Kefu Chai <kchai@redhat.com>
2018-12-20 23:51:20 +08:00
Yingxin
1e6a0a9a42 crimson/net: let conn directly verify the authorizer with dispatcher
Signed-off-by: Yingxin <yingxin.cheng@intel.com>
2018-12-21 03:42:42 +08:00
Yingxin
03d435f79d crimson/net: remove the messenger gate
There is no need to use messenger gate if SocketConnection themselves
are properly gated.

Signed-off-by: Yingxin <yingxin.cheng@intel.com>
2018-12-21 03:10:17 +08:00
Yingxin
f56fcd095a crimson/net: encapsulate protocol implementations with accept/connect
Signed-off-by: Yingxin <yingxin.cheng@intel.com>
2018-12-21 03:10:09 +08:00