Skip to content
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

feat(CSI-249): optimize NFS mounter to use multiple targets #318

Merged
merged 1 commit into from
Sep 12, 2024

Conversation

sergeyberezansky
Copy link
Collaborator

@sergeyberezansky sergeyberezansky commented Sep 5, 2024

TL;DR

Added a new function to determine the node's IP address based on routing to a target host.

What changed?

  • Introduced a new function GetNodeIpAddressByRouting in utils.go that determines the node's IP address by creating a UDP connection to a target host.
  • Updated the doMount function in nfsmount.go to use the new GetNodeIpAddressByRouting function, falling back to GetNodeIpAddress if it fails.
  • Added unit tests for the new GetNodeIpAddressByRouting function in utils_test.go.

How to test?

  1. Run the new unit tests in utils_test.go to verify the functionality of GetNodeIpAddressByRouting.
  2. Test the NFS mount process with different network configurations to ensure it correctly determines the node's IP address.
  3. Verify that the mount process falls back to the original GetNodeIpAddress function if GetNodeIpAddressByRouting fails.

Why make this change?

This change improves the accuracy of determining the node's IP address for NFS mounts, especially in complex network environments. By using routing information to determine the IP address, we can ensure that the correct network interface is used for NFS communications, potentially resolving issues related to multi-homed systems or specific network configurations.


feat(deps): implement InterfaceGroup.GetRandomIpAddress()

feat(deps): implement InterfaceGroup.GetRandomIpAddress()

refactor(deps): allow multimount for NFS

refactor(deps): unmount underlying FS straight after publishing volume

@graphite-app graphite-app bot requested a review from tigrawap September 5, 2024 06:57
Copy link

graphite-app bot commented Sep 5, 2024

Graphite Automations

"Request reviewers once CI passes" took an action on this PR • (09/05/24)

1 reviewer was added to this PR based on Sergey Berezansky's automation.

@sergeyberezansky sergeyberezansky force-pushed the sergey/simplify-nfs-mounter branch 2 times, most recently from 2e3f570 to 8ec4141 Compare September 5, 2024 09:37
@sergeyberezansky sergeyberezansky changed the title feat(CSI-247): optimize NFS mounter to use multiple targets feat(CSI-247,CSI-249): optimize NFS mounter to use multiple targets Sep 8, 2024
@sergeyberezansky sergeyberezansky added the enhancement New feature or request label Sep 10, 2024
@sergeyberezansky sergeyberezansky changed the title feat(CSI-247,CSI-249): optimize NFS mounter to use multiple targets feat(CSI-249): optimize NFS mounter to use multiple targets Sep 12, 2024
Copy link
Collaborator Author

sergeyberezansky commented Sep 12, 2024

Merge activity

@sergeyberezansky sergeyberezansky changed the base branch from sergey/csi-241-nfs-sync-map-fix to graphite-base/318 September 12, 2024 12:47
@sergeyberezansky sergeyberezansky changed the base branch from graphite-base/318 to dev September 12, 2024 12:48
@sergeyberezansky sergeyberezansky merged commit 2bb177e into dev Sep 12, 2024
14 of 21 checks passed
@sergeyberezansky sergeyberezansky deleted the sergey/simplify-nfs-mounter branch September 12, 2024 15:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant