Bryan Boreham
34dc4dabce
Clean up some lint warnings
...
I ran golangci-lint and it pointed out a few things to clean up.
2020-07-31 10:28:55 +00:00
Bryan Boreham
27f8f9092f
router: tell goroutine to exit when forwarder is stopped
...
Otherwise a goroutine is leaked each time a connection is closed.
2020-06-04 17:46:18 +00:00
Bryan Boreham
e7a24eaf0a
Merge pull request #3783 from weaveworks/issue-3781
...
send FastDatapathCryptoInitSARemote control message only if encryption is enabled
2020-03-12 10:09:26 +00:00
Murali Reddy
6bc0e5e71c
send FastDatapathCryptoInitSARemote control message only if encryption is enabled
...
Fixes #3781
2020-03-11 21:26:09 +05:30
Bryan Boreham
0ca831f50b
Reduce pcap timeout to avoid overflow
...
The value is passed by google/gopacket into a signed 32-bit int, so we
must pick a timeout which is less than 2^31 microseconds.
See https://github.com/google/gopacket/issues/708
2020-03-11 12:21:07 +00:00
Bryan Boreham
ca0498b860
Fix warning log to use formatted variant
2020-01-28 15:15:28 +00:00
Bryan Boreham
bbfa682083
Move send of ipsec message outside lock
...
The send may block, so do all changes to the forwarder object and
release the lock before attempting to send.
2020-01-28 15:13:33 +00:00
Hendrik van Wyk
96291d1de4
Do not do ipsec.InitSARemote on a stopped fastDatapathForwarder.
...
Fixes 3675
It is possible for ipsec.InitSARemote to be called after ipsec.Destroy.
If an xfrm policy for that source/destination pair exists it will be
updated to the SPI from the Destroyed connection causing IPSEC to stop
working.
2019-07-31 11:17:37 +02:00
Bryan Boreham
20d55fe47a
Moved 'expecting PMTU' message to debug level
2019-05-03 15:28:44 +00:00
Bryan Boreham
698e1b6d87
Improve 'expecting PMTU update' message with address
...
Also remove "EMGSIZE" because it looks like an error in the log file.
2019-02-27 08:49:42 +00:00
Murali Reddy
6b2631e378
addressing review comment. keep forwarder running forever even on heart beat timeouts
2018-10-05 09:47:23 +05:30
Murali Reddy
b3cb38eda4
addressing review comments
2018-09-24 17:53:28 +05:30
Murali Reddy
62758ca337
log the heartbeat send/recieve/miss
2018-09-21 16:45:47 +05:30
Murali Reddy
3c67c3c5f1
changes differentiate beteween fatal errors (for e.g. ipsec init)
...
from transient errors (heartbeast misses). In case of transient
errors OverlayForwarder is marked to be unhealty. When overlay forwarder
is unhealty its hept on hold so chooseBest() will skip selecting the forwrder
Once OverlayForwarder is considered healthy run chooseBest() again so the
forwarder can be selected if its the best forwarder
Fixes #1737
2018-09-21 16:45:47 +05:30
Aaron Hurt
c9f1d30f49
updates to address comments by @bboreham
2018-08-31 14:26:00 -05:00
Aaron Hurt
4b9c533b94
add the ability to skip creation of MASQUERADE rules via iptables when executing weave expose command
2018-08-31 11:46:31 -05:00
Bryan Boreham
b2ae5f4f4b
Demote messages about MAC discovery and expiry to DEBUG level
2017-12-18 11:36:24 +00:00
Bryan Boreham
21086a0b2a
Merge branch '2.0'
2017-11-13 12:51:29 +00:00
Bryan Boreham
d7119169df
Add length to log message for too-big DF broadcast frame
2017-11-13 11:06:34 +00:00
Martynas Pumputis
ade6738789
Handle "weave expose" in weaver
...
The change makes "weave expose" to call the "/expose" HTTP
endpoint implemented in router which exposes the bridge.
Such architectural change required as we need to know whether NPC is
enabled when exposing the bridge and weaver knows this fact the best.
Unfortunately, this change makes impossible to "weave expose"
when weaver is not running.
2017-10-17 12:08:43 +01:00
Marc CARRE
507e734d1a
Merge remote-tracking branch 'origin/1.9'
...
- PR #2926 - Branch issues/2808-improve-hairpin-messages - Fixes #2808 .
- PR #2907 - Branch issues/2771-checkpoint-net-modes - Fixes #2771 .
2017-05-03 20:28:31 +01:00
Marc Carré
d128488339
Merge pull request #2926 from weaveworks/issues/2808-improve-hairpin-messages
...
Fixes #2808 . Improve hairpin log messages.
2017-05-03 20:21:20 +01:00
Bryan Boreham
b19f2df6f8
Improve hairpin log messages
2017-05-03 14:35:20 +00:00
Bryan Boreham
b3ac56e3d2
Update mesh library and check for errors newly returned
2017-05-03 11:08:28 +00:00
Bryan Boreham
334974472d
Rename router.Bridge to router.InjectorConsumer
...
since what it does it injects and consumes packets, and something else
entirely does bridging.
2017-04-25 11:03:32 +01:00
Bryan Boreham
681109ba71
use net.IP.Equal to compare, not bytes.Equal
2017-03-21 11:38:35 +00:00
Bryan Boreham
99c691745a
Check error return on udp dial()
2017-03-21 11:38:35 +00:00
Martynas Pumputis
7c84e24f48
fastdp: Do not reset heartbeat timer for non-confirmed connections
...
It is possible to receive FastDatapathCryptoInitSARemote control plane
message before Confirm'ing a connection. In such case, resetting
heartbeatTimer leads to null pointer dereference, as the timer is
initialized during Confirm'ation.
In this situation, skipping the reset is non-harmful, because
Confirm'ing will reset it.
NB: the reset to 0 should only happen after establishing the connection
on both ends.
2017-03-02 16:59:48 +00:00
Martynas Pumputis
60323d0960
Add fastdp crypto
2017-01-31 17:21:01 +00:00
Martynas Pumputis
52f375ac1e
Merge pull request #2663 from weaveworks/issues/2389-report-mtu
...
Add MTU to connection status
Fixes #2389
2016-12-13 11:53:39 +00:00
Bryan Boreham
9c2bc0b825
Add MTU to connection status
2016-12-09 13:59:49 +00:00
Martynas Pumputis
aa9c032176
Add sanity check to detect when receiving own packets
2016-12-08 11:38:37 +00:00
Martynas Pumputis
0ae13a2650
Detect hairpin flows
...
The introduced "isHairpinFlow" detects whether a flow has been
created due to enabled hairpin mode.
2016-12-05 12:42:24 +00:00
Bryan Boreham
4d8a40c0b5
Reduce metrics mechanism to just support fastdp
2016-10-21 14:44:12 +01:00
Bryan Boreham
00c86fed42
Expose overlay metrics from fastdp
...
and allow them to pass through OverlaySwitch
2016-10-20 16:25:16 +01:00
Martynas Pumputis
cdeae04238
Create restart.sentinel after storing peer list
...
Otherwise, we risk to lose peer list when any failure happens after
the creation but before storing the list and as a consequence,
the weave container gets restarted.
2016-09-20 17:07:48 +01:00
Martynas Pumputis
d9bde790c6
Check if a vxlan vport netdev is up after its creation
...
This bypasses a kernel bug when the creation of vxlan vport
completes successfully regardless whether an vxlan UDP port has been
bind (http://marc.info/?l=linux-netdev&m=147075637009483&w=2 ).
2016-08-10 13:34:44 +01:00
Matthias Radestock
e642f366f5
cosmetic
2016-07-09 05:41:37 +01:00
Martynas Pumputis
93c60395f6
Merge pull request #2417 from weaveworks/issues/1852-less-logging
...
Move 'ODP miss' log from every miss to specific places
Fixes #1852
2016-07-05 17:34:57 +01:00
Bryan Boreham
7d0aaea6e8
Move 'ODP miss' log from every miss to specific places
...
Added log lines for packets that we will broadcast;
Added log lines for flows we don't know how to handle;
Moved the line for when we expect to insert a flow down to the miss-handler;
Packets handled by the bridge already have their own logging via --pktdebug
2016-07-01 10:12:53 +01:00
Bryan Boreham
45a66ac517
Extend 'mac associated with other peer' error info
2016-06-30 18:02:39 +01:00
Martynas Pumputis
9fc7be83c8
Create a Tracker when starting the router
...
The tracker's HandleUpdate method is called by the ring update routines.
In addition, we add a dummy overlay for AWSVPC to make `weave (status|
report)` to produce reasonable reports which includes AWS hosts
connection state.
2016-06-08 16:44:54 +01:00
Adam Harrison
4b758dd130
Implement weave launch --resume
2016-06-03 13:53:07 +01:00
Adam Harrison
166d4afad8
Use persisted peer list on Docker restart
2016-06-03 13:53:07 +01:00
Bryan Boreham
4669da6074
Disable persistence of peer lists
2016-04-15 14:49:50 +01:00
Bryan Boreham
c38dcb1d73
Adapt to logging changes in weaveworks/mesh
2016-04-04 16:01:58 +01:00
Matthias Radestock
ec167554c5
refactor: consistent order
2016-03-30 14:13:41 +01:00
Matthias Radestock
f24f38be9c
refactor: get rid of a superfluous fastdp member
2016-03-30 14:10:03 +01:00
Matthias Radestock
0f89f8562f
refactor(ish): parameterise dp creation by iface, not name
2016-03-30 14:07:33 +01:00
Matthias Radestock
8b6c5bdae4
unbreak things
2016-03-23 17:05:19 +00:00