-
Notifications
You must be signed in to change notification settings - Fork 366
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve AntreaProxy route syncing on Windows
This PR fixes some issues: 1. AntreaAgent logs "Failed to sync route" when attempting to sync route entries every time. 2. AntreaAgent logs "Failed to install route for Service CIDR" during startup. 3. AntreaAgent may crash during the first installation of Antrea with proxyAll enabled on Windows. 4. AntreaAgent doesn't clean the previously installed calculated route. For the first issue, previously, to recover the connected route of antrea-gw0 (assuming the IP address is 10.10.0.1/24) that may have been deleted by mistake, a route with a destination 10.10.0.1/24 and gateway 10.10.0.1 was periodically synced. However, this caused an error because an existing active route with the same destination but a different gateway 0.0.0.0 should have already been automatically installed when antrea-gw0 was created. To address this issue, this PR changes the gateway of the recover route from 10.10.0.1 to 0.0.0.0, which matches the existing installed route. This ensures that the periodic sync will not cause any errors. For the second issue, when syncing the first ClusterIP, the route entry installed for the first ClusterIP is added to the stale routes and then deleted. This results in the first ClusterIP becoming unavailable until the calculated route entry for the second ClusterIP is installed. This PR resolves the issue by excluding the route entry for the first ClusterIP from the stale routes. For the third issue, if the first ClusterIP is Service `kubernetes` in the second issue, the unavailability of the ClusterIP might result in crashing of Antrea with proxyAll enabled. For the fourth issue, when syncing the first ClusterIP, list all existing routes and clean the routes whose destination CIDR that contains the ClusterIP to resolve the issue. Signed-off-by: Hongliang Liu <lhongliang@vmware.com>
- Loading branch information
1 parent
c9c9559
commit f679376
Showing
4 changed files
with
86 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters