-
Notifications
You must be signed in to change notification settings - Fork 388
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add an iptable rule to allow icmp for antrea-gw0 for NodeLatencyMonitor feature #6952
Comments
I was thinking there would be two workflows that we need to account for: one where the ICMP rule exists before the NodeLatencyMonitor is deployed, and the other for when the ICMP rule is applied after the NLM is already created. For the first case, I believe it would make the most sense to add the changes in the |
Hi @Dhruv-J Since we will only allow the ICMP for antrea specific interface antrea-gw0, I feel it should be OK to add it as long as the NodeLatencyMonitor feature is enabled. @antoninbas @tnqn what's your suggestion? |
In policyOnlyMode, we use the Node's transport IP for the ICMP probes: antrea/pkg/agent/monitortool/latency_store.go Line 149 in 1ee108b
So based on the mode, we could either use antrea-gw0 or the transport interface - assuming we want to filter based on the interface which sounds reasonable to me? BTW, should we add an output filter rule as well for the sake of completeness? I synced up with @Dhruv-J today - I think most of the changes should be in |
This PR provides the solution to an edge case with NodeLatencyMonitor, where the feature does not work if ICMP queries are blocked by default. To fix this, an iptable rule will be added if NodeLatencyMonitor is enabled, such that ICMP requests via the Antrea gateway will be allowed. Fixes issue antrea-io#6952 Signed-off-by: Dhruv-J <dhruvj@vmware.com>
This PR provides the solution to an edge case with NodeLatencyMonitor, where the feature does not work if ICMP queries are blocked by default. To fix this, an iptable rule will be added if NodeLatencyMonitor is enabled, such that ICMP requests via the Antrea gateway will be allowed. Fixes issue antrea-io#6952 Signed-off-by: Dhruv-J <dhruvj@vmware.com>
Describe the problem/challenge you have
When I tried the NodeLatencyMonitor feature in a local testbed where the ICMP query is blocked by default, the feature will not work as expected because it relys on ICMP request to get the latency between Nodes.
Describe the solution you'd like
When I added an iptable rule 'iptables -A INPUT -p icmp --icmp-type echo-request -j ACCEPT' on the Node, the feature is back to normal.
We can add a new rule to limit it to
antrea-gw0
only withiptables -A INPUT -i antrea-gw0 -p icmp --icmp-type echo-request -j ACCEPT
from Antrea side to make the feature work when the Node ICMP is blocked by default.The text was updated successfully, but these errors were encountered: